34
Tutorial: Using RIPEstat MENOG 14 Christian Teuschel

Using RIPEstat

Embed Size (px)

DESCRIPTION

Presentation given by Christian Teuschel at MENOG 14 in Dubai on 1 April 2014

Citation preview

Page 1: Using RIPEstat

Tutorial Using RIPEstatMENOG 14Christian Teuschel

RIPE RIPEstat MENOG 14

Recap From the RIPEstat Presentation

bull Information system for Internet number resources

bull Data _ Routing data

- Collected by RIS httprisripenet _ Registration data (whois)

_ RIPE Database amp other RIR databases _ MaxMindrsquos geolocation data _ Blacklist data _ And many more httpsstatripenetdata-sources

2

RIPE RIPEstat MENOG 14

Three Interfaces of RIPEstat

3

httpsstatripenetdatarouting-statusdatajsonresource=AS3333

RIPEstat Web Interface

RIPEstat Widget API

RIPEstat Data API RIPEstat Text

RIPE RIPEstat MENOG 14

RIPEstat Web Interfacebull Finding Information on RIPEstat

4

Search input

Links to most used features

RIPEstat related articles on

RIPE Labs

Recent new features

RIPE RIPEstat MENOG 14

RIPEstat Web Interfacebull Information structure on RIPEstat

5

bull FAQ bull Data Sources bull Widget List bull Top Queries bull Feedback

bull Interfaces amp APIs bull Demos bull Roadmap bull Changelog

bull Notable Network Events bull Compare Results bull Looking For Abuse Information bull Global Internet Statistics

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface)

6

Search box

Your ASN amp network prefix Sample resources

Example Enter ldquoAS3333rdquo in the search box

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface)

Result page

7

Search box

Widgets grouped into thematic tabs Widgets display

different types of information

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface) Tasks

_ What network announces 140785090 _ Is 192342 routed _ In which country is 9122942023 used _ What is its corresponding INETNUM object _ What widget provides real-time routing status _ By what percent did the number of prefixes announced by Kuwait increase over the last two years

_ How would you share interesting network events with a colleague

8

RIPE RIPEstat MENOG 14

2 MyViewsCreate custom views

9

bull Click theldquoMyViewrdquo Button

bull Drag and drop a widget onto the ldquoMyViewrdquo button

RIPE RIPEstat MENOG 14

2 MyViews

10

Newly created MyView

MyViews are only visible to you An option to share your views will be available soon

RIPE RIPEstat MENOG 14

2 MyViewsCustomise MyViews

11

bull Rename bull Re-order bull Control visibility bull Remove

Re-order widgets as you like

RIPE RIPEstat MENOG 14

2 MyViews Tasks

_ Create a RIPE Access account (if you donrsquot already have one) _ Create a MyView for a prefix containing the following widgets

_ Routing Status _ Looking Glass _ Routing History

_ Create another MyView with at least two widgets and give it a meaningful name

12

RIPE RIPEstat MENOG 14

Create SSO AccountTasks

_ Go to the ldquoLoginrdquo page _ ldquoclick here to create onerdquo

13

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

14

Go to ldquoUse Casesrdquo gt ldquoCompare Resultsrdquo

Select a widget

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 2: Using RIPEstat

RIPE RIPEstat MENOG 14

Recap From the RIPEstat Presentation

bull Information system for Internet number resources

bull Data _ Routing data

- Collected by RIS httprisripenet _ Registration data (whois)

_ RIPE Database amp other RIR databases _ MaxMindrsquos geolocation data _ Blacklist data _ And many more httpsstatripenetdata-sources

2

RIPE RIPEstat MENOG 14

Three Interfaces of RIPEstat

3

httpsstatripenetdatarouting-statusdatajsonresource=AS3333

RIPEstat Web Interface

RIPEstat Widget API

RIPEstat Data API RIPEstat Text

RIPE RIPEstat MENOG 14

RIPEstat Web Interfacebull Finding Information on RIPEstat

4

Search input

Links to most used features

RIPEstat related articles on

RIPE Labs

Recent new features

RIPE RIPEstat MENOG 14

RIPEstat Web Interfacebull Information structure on RIPEstat

5

bull FAQ bull Data Sources bull Widget List bull Top Queries bull Feedback

bull Interfaces amp APIs bull Demos bull Roadmap bull Changelog

bull Notable Network Events bull Compare Results bull Looking For Abuse Information bull Global Internet Statistics

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface)

6

Search box

Your ASN amp network prefix Sample resources

Example Enter ldquoAS3333rdquo in the search box

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface)

Result page

7

Search box

Widgets grouped into thematic tabs Widgets display

different types of information

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface) Tasks

_ What network announces 140785090 _ Is 192342 routed _ In which country is 9122942023 used _ What is its corresponding INETNUM object _ What widget provides real-time routing status _ By what percent did the number of prefixes announced by Kuwait increase over the last two years

_ How would you share interesting network events with a colleague

8

RIPE RIPEstat MENOG 14

2 MyViewsCreate custom views

9

bull Click theldquoMyViewrdquo Button

bull Drag and drop a widget onto the ldquoMyViewrdquo button

RIPE RIPEstat MENOG 14

2 MyViews

10

Newly created MyView

MyViews are only visible to you An option to share your views will be available soon

RIPE RIPEstat MENOG 14

2 MyViewsCustomise MyViews

11

bull Rename bull Re-order bull Control visibility bull Remove

Re-order widgets as you like

RIPE RIPEstat MENOG 14

2 MyViews Tasks

_ Create a RIPE Access account (if you donrsquot already have one) _ Create a MyView for a prefix containing the following widgets

_ Routing Status _ Looking Glass _ Routing History

_ Create another MyView with at least two widgets and give it a meaningful name

12

RIPE RIPEstat MENOG 14

Create SSO AccountTasks

_ Go to the ldquoLoginrdquo page _ ldquoclick here to create onerdquo

13

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

14

Go to ldquoUse Casesrdquo gt ldquoCompare Resultsrdquo

Select a widget

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 3: Using RIPEstat

RIPE RIPEstat MENOG 14

Three Interfaces of RIPEstat

3

httpsstatripenetdatarouting-statusdatajsonresource=AS3333

RIPEstat Web Interface

RIPEstat Widget API

RIPEstat Data API RIPEstat Text

RIPE RIPEstat MENOG 14

RIPEstat Web Interfacebull Finding Information on RIPEstat

4

Search input

Links to most used features

RIPEstat related articles on

RIPE Labs

Recent new features

RIPE RIPEstat MENOG 14

RIPEstat Web Interfacebull Information structure on RIPEstat

5

bull FAQ bull Data Sources bull Widget List bull Top Queries bull Feedback

bull Interfaces amp APIs bull Demos bull Roadmap bull Changelog

bull Notable Network Events bull Compare Results bull Looking For Abuse Information bull Global Internet Statistics

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface)

6

Search box

Your ASN amp network prefix Sample resources

Example Enter ldquoAS3333rdquo in the search box

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface)

Result page

7

Search box

Widgets grouped into thematic tabs Widgets display

different types of information

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface) Tasks

_ What network announces 140785090 _ Is 192342 routed _ In which country is 9122942023 used _ What is its corresponding INETNUM object _ What widget provides real-time routing status _ By what percent did the number of prefixes announced by Kuwait increase over the last two years

_ How would you share interesting network events with a colleague

8

RIPE RIPEstat MENOG 14

2 MyViewsCreate custom views

9

bull Click theldquoMyViewrdquo Button

bull Drag and drop a widget onto the ldquoMyViewrdquo button

RIPE RIPEstat MENOG 14

2 MyViews

10

Newly created MyView

MyViews are only visible to you An option to share your views will be available soon

RIPE RIPEstat MENOG 14

2 MyViewsCustomise MyViews

11

bull Rename bull Re-order bull Control visibility bull Remove

Re-order widgets as you like

RIPE RIPEstat MENOG 14

2 MyViews Tasks

_ Create a RIPE Access account (if you donrsquot already have one) _ Create a MyView for a prefix containing the following widgets

_ Routing Status _ Looking Glass _ Routing History

_ Create another MyView with at least two widgets and give it a meaningful name

12

RIPE RIPEstat MENOG 14

Create SSO AccountTasks

_ Go to the ldquoLoginrdquo page _ ldquoclick here to create onerdquo

13

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

14

Go to ldquoUse Casesrdquo gt ldquoCompare Resultsrdquo

Select a widget

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 4: Using RIPEstat

RIPE RIPEstat MENOG 14

RIPEstat Web Interfacebull Finding Information on RIPEstat

4

Search input

Links to most used features

RIPEstat related articles on

RIPE Labs

Recent new features

RIPE RIPEstat MENOG 14

RIPEstat Web Interfacebull Information structure on RIPEstat

5

bull FAQ bull Data Sources bull Widget List bull Top Queries bull Feedback

bull Interfaces amp APIs bull Demos bull Roadmap bull Changelog

bull Notable Network Events bull Compare Results bull Looking For Abuse Information bull Global Internet Statistics

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface)

6

Search box

Your ASN amp network prefix Sample resources

Example Enter ldquoAS3333rdquo in the search box

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface)

Result page

7

Search box

Widgets grouped into thematic tabs Widgets display

different types of information

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface) Tasks

_ What network announces 140785090 _ Is 192342 routed _ In which country is 9122942023 used _ What is its corresponding INETNUM object _ What widget provides real-time routing status _ By what percent did the number of prefixes announced by Kuwait increase over the last two years

_ How would you share interesting network events with a colleague

8

RIPE RIPEstat MENOG 14

2 MyViewsCreate custom views

9

bull Click theldquoMyViewrdquo Button

bull Drag and drop a widget onto the ldquoMyViewrdquo button

RIPE RIPEstat MENOG 14

2 MyViews

10

Newly created MyView

MyViews are only visible to you An option to share your views will be available soon

RIPE RIPEstat MENOG 14

2 MyViewsCustomise MyViews

11

bull Rename bull Re-order bull Control visibility bull Remove

Re-order widgets as you like

RIPE RIPEstat MENOG 14

2 MyViews Tasks

_ Create a RIPE Access account (if you donrsquot already have one) _ Create a MyView for a prefix containing the following widgets

_ Routing Status _ Looking Glass _ Routing History

_ Create another MyView with at least two widgets and give it a meaningful name

12

RIPE RIPEstat MENOG 14

Create SSO AccountTasks

_ Go to the ldquoLoginrdquo page _ ldquoclick here to create onerdquo

13

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

14

Go to ldquoUse Casesrdquo gt ldquoCompare Resultsrdquo

Select a widget

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 5: Using RIPEstat

RIPE RIPEstat MENOG 14

RIPEstat Web Interfacebull Information structure on RIPEstat

5

bull FAQ bull Data Sources bull Widget List bull Top Queries bull Feedback

bull Interfaces amp APIs bull Demos bull Roadmap bull Changelog

bull Notable Network Events bull Compare Results bull Looking For Abuse Information bull Global Internet Statistics

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface)

6

Search box

Your ASN amp network prefix Sample resources

Example Enter ldquoAS3333rdquo in the search box

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface)

Result page

7

Search box

Widgets grouped into thematic tabs Widgets display

different types of information

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface) Tasks

_ What network announces 140785090 _ Is 192342 routed _ In which country is 9122942023 used _ What is its corresponding INETNUM object _ What widget provides real-time routing status _ By what percent did the number of prefixes announced by Kuwait increase over the last two years

_ How would you share interesting network events with a colleague

8

RIPE RIPEstat MENOG 14

2 MyViewsCreate custom views

9

bull Click theldquoMyViewrdquo Button

bull Drag and drop a widget onto the ldquoMyViewrdquo button

RIPE RIPEstat MENOG 14

2 MyViews

10

Newly created MyView

MyViews are only visible to you An option to share your views will be available soon

RIPE RIPEstat MENOG 14

2 MyViewsCustomise MyViews

11

bull Rename bull Re-order bull Control visibility bull Remove

Re-order widgets as you like

RIPE RIPEstat MENOG 14

2 MyViews Tasks

_ Create a RIPE Access account (if you donrsquot already have one) _ Create a MyView for a prefix containing the following widgets

_ Routing Status _ Looking Glass _ Routing History

_ Create another MyView with at least two widgets and give it a meaningful name

12

RIPE RIPEstat MENOG 14

Create SSO AccountTasks

_ Go to the ldquoLoginrdquo page _ ldquoclick here to create onerdquo

13

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

14

Go to ldquoUse Casesrdquo gt ldquoCompare Resultsrdquo

Select a widget

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 6: Using RIPEstat

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface)

6

Search box

Your ASN amp network prefix Sample resources

Example Enter ldquoAS3333rdquo in the search box

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface)

Result page

7

Search box

Widgets grouped into thematic tabs Widgets display

different types of information

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface) Tasks

_ What network announces 140785090 _ Is 192342 routed _ In which country is 9122942023 used _ What is its corresponding INETNUM object _ What widget provides real-time routing status _ By what percent did the number of prefixes announced by Kuwait increase over the last two years

_ How would you share interesting network events with a colleague

8

RIPE RIPEstat MENOG 14

2 MyViewsCreate custom views

9

bull Click theldquoMyViewrdquo Button

bull Drag and drop a widget onto the ldquoMyViewrdquo button

RIPE RIPEstat MENOG 14

2 MyViews

10

Newly created MyView

MyViews are only visible to you An option to share your views will be available soon

RIPE RIPEstat MENOG 14

2 MyViewsCustomise MyViews

11

bull Rename bull Re-order bull Control visibility bull Remove

Re-order widgets as you like

RIPE RIPEstat MENOG 14

2 MyViews Tasks

_ Create a RIPE Access account (if you donrsquot already have one) _ Create a MyView for a prefix containing the following widgets

_ Routing Status _ Looking Glass _ Routing History

_ Create another MyView with at least two widgets and give it a meaningful name

12

RIPE RIPEstat MENOG 14

Create SSO AccountTasks

_ Go to the ldquoLoginrdquo page _ ldquoclick here to create onerdquo

13

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

14

Go to ldquoUse Casesrdquo gt ldquoCompare Resultsrdquo

Select a widget

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 7: Using RIPEstat

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface)

Result page

7

Search box

Widgets grouped into thematic tabs Widgets display

different types of information

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface) Tasks

_ What network announces 140785090 _ Is 192342 routed _ In which country is 9122942023 used _ What is its corresponding INETNUM object _ What widget provides real-time routing status _ By what percent did the number of prefixes announced by Kuwait increase over the last two years

_ How would you share interesting network events with a colleague

8

RIPE RIPEstat MENOG 14

2 MyViewsCreate custom views

9

bull Click theldquoMyViewrdquo Button

bull Drag and drop a widget onto the ldquoMyViewrdquo button

RIPE RIPEstat MENOG 14

2 MyViews

10

Newly created MyView

MyViews are only visible to you An option to share your views will be available soon

RIPE RIPEstat MENOG 14

2 MyViewsCustomise MyViews

11

bull Rename bull Re-order bull Control visibility bull Remove

Re-order widgets as you like

RIPE RIPEstat MENOG 14

2 MyViews Tasks

_ Create a RIPE Access account (if you donrsquot already have one) _ Create a MyView for a prefix containing the following widgets

_ Routing Status _ Looking Glass _ Routing History

_ Create another MyView with at least two widgets and give it a meaningful name

12

RIPE RIPEstat MENOG 14

Create SSO AccountTasks

_ Go to the ldquoLoginrdquo page _ ldquoclick here to create onerdquo

13

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

14

Go to ldquoUse Casesrdquo gt ldquoCompare Resultsrdquo

Select a widget

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 8: Using RIPEstat

RIPE RIPEstat MENOG 14

1 Querying for a Resource (Web Interface) Tasks

_ What network announces 140785090 _ Is 192342 routed _ In which country is 9122942023 used _ What is its corresponding INETNUM object _ What widget provides real-time routing status _ By what percent did the number of prefixes announced by Kuwait increase over the last two years

_ How would you share interesting network events with a colleague

8

RIPE RIPEstat MENOG 14

2 MyViewsCreate custom views

9

bull Click theldquoMyViewrdquo Button

bull Drag and drop a widget onto the ldquoMyViewrdquo button

RIPE RIPEstat MENOG 14

2 MyViews

10

Newly created MyView

MyViews are only visible to you An option to share your views will be available soon

RIPE RIPEstat MENOG 14

2 MyViewsCustomise MyViews

11

bull Rename bull Re-order bull Control visibility bull Remove

Re-order widgets as you like

RIPE RIPEstat MENOG 14

2 MyViews Tasks

_ Create a RIPE Access account (if you donrsquot already have one) _ Create a MyView for a prefix containing the following widgets

_ Routing Status _ Looking Glass _ Routing History

_ Create another MyView with at least two widgets and give it a meaningful name

12

RIPE RIPEstat MENOG 14

Create SSO AccountTasks

_ Go to the ldquoLoginrdquo page _ ldquoclick here to create onerdquo

13

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

14

Go to ldquoUse Casesrdquo gt ldquoCompare Resultsrdquo

Select a widget

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 9: Using RIPEstat

RIPE RIPEstat MENOG 14

2 MyViewsCreate custom views

9

bull Click theldquoMyViewrdquo Button

bull Drag and drop a widget onto the ldquoMyViewrdquo button

RIPE RIPEstat MENOG 14

2 MyViews

10

Newly created MyView

MyViews are only visible to you An option to share your views will be available soon

RIPE RIPEstat MENOG 14

2 MyViewsCustomise MyViews

11

bull Rename bull Re-order bull Control visibility bull Remove

Re-order widgets as you like

RIPE RIPEstat MENOG 14

2 MyViews Tasks

_ Create a RIPE Access account (if you donrsquot already have one) _ Create a MyView for a prefix containing the following widgets

_ Routing Status _ Looking Glass _ Routing History

_ Create another MyView with at least two widgets and give it a meaningful name

12

RIPE RIPEstat MENOG 14

Create SSO AccountTasks

_ Go to the ldquoLoginrdquo page _ ldquoclick here to create onerdquo

13

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

14

Go to ldquoUse Casesrdquo gt ldquoCompare Resultsrdquo

Select a widget

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 10: Using RIPEstat

RIPE RIPEstat MENOG 14

2 MyViews

10

Newly created MyView

MyViews are only visible to you An option to share your views will be available soon

RIPE RIPEstat MENOG 14

2 MyViewsCustomise MyViews

11

bull Rename bull Re-order bull Control visibility bull Remove

Re-order widgets as you like

RIPE RIPEstat MENOG 14

2 MyViews Tasks

_ Create a RIPE Access account (if you donrsquot already have one) _ Create a MyView for a prefix containing the following widgets

_ Routing Status _ Looking Glass _ Routing History

_ Create another MyView with at least two widgets and give it a meaningful name

12

RIPE RIPEstat MENOG 14

Create SSO AccountTasks

_ Go to the ldquoLoginrdquo page _ ldquoclick here to create onerdquo

13

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

14

Go to ldquoUse Casesrdquo gt ldquoCompare Resultsrdquo

Select a widget

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 11: Using RIPEstat

RIPE RIPEstat MENOG 14

2 MyViewsCustomise MyViews

11

bull Rename bull Re-order bull Control visibility bull Remove

Re-order widgets as you like

RIPE RIPEstat MENOG 14

2 MyViews Tasks

_ Create a RIPE Access account (if you donrsquot already have one) _ Create a MyView for a prefix containing the following widgets

_ Routing Status _ Looking Glass _ Routing History

_ Create another MyView with at least two widgets and give it a meaningful name

12

RIPE RIPEstat MENOG 14

Create SSO AccountTasks

_ Go to the ldquoLoginrdquo page _ ldquoclick here to create onerdquo

13

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

14

Go to ldquoUse Casesrdquo gt ldquoCompare Resultsrdquo

Select a widget

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 12: Using RIPEstat

RIPE RIPEstat MENOG 14

2 MyViews Tasks

_ Create a RIPE Access account (if you donrsquot already have one) _ Create a MyView for a prefix containing the following widgets

_ Routing Status _ Looking Glass _ Routing History

_ Create another MyView with at least two widgets and give it a meaningful name

12

RIPE RIPEstat MENOG 14

Create SSO AccountTasks

_ Go to the ldquoLoginrdquo page _ ldquoclick here to create onerdquo

13

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

14

Go to ldquoUse Casesrdquo gt ldquoCompare Resultsrdquo

Select a widget

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 13: Using RIPEstat

RIPE RIPEstat MENOG 14

Create SSO AccountTasks

_ Go to the ldquoLoginrdquo page _ ldquoclick here to create onerdquo

13

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

14

Go to ldquoUse Casesrdquo gt ldquoCompare Resultsrdquo

Select a widget

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 14: Using RIPEstat

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

14

Go to ldquoUse Casesrdquo gt ldquoCompare Resultsrdquo

Select a widget

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 15: Using RIPEstat

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)bull Compare results in different widgets

15

Enter a resourcebull Select the ldquoPrefix Size Distributionrdquo widget bull Enter ldquoAS1205rdquo

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 16: Using RIPEstat

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)In-widget comparison

16

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 17: Using RIPEstat

RIPE RIPEstat MENOG 14

3 Comparing Resources (Web Interface)Tasks

_ Compare the number of announced prefixes for two networks over the past two years using the widget comparison page

_ How does the Internet in the UAE compare to the UK Use in-widget comparison

17

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 18: Using RIPEstat

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTake action in an abuse case with the Abuse Contact Finder

18

Go to ldquoUse Casesrdquo gt ldquoLooking For Abuse Informationrdquo

In-depth information about abuse

Enter the IP address

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 19: Using RIPEstat

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

19

Email contact to report abuse to

Rating of the contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 20: Using RIPEstat

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting Abuse

20

Details about the resource and abuse contact

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 21: Using RIPEstat

RIPE RIPEstat MENOG 14

4 Finding Abuse Contacts amp Reporting AbuseTasks

_ What is the abuse contact for 19302022 or the hotel network _ Check an IP address from your home network _ Discussion

What can you do in these cases _ No abuse contact found _ No response on an abuse report

21

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 22: Using RIPEstat

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

bull Use BGPlay to see how your network is routed - BGPlay is a tool that show routing history in an animated

and highly-interactive manner

bull Go to httpsstatripenetwidgetbgplay

22

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 23: Using RIPEstat

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

23

Interactive graph visualisation

Control timeline

BGP event ASN or ASN path details

Selection timeline

Control panel - Covered time period - RRC selection

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 24: Using RIPEstat

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlay

24

Examples

- Prefix with announcements amp withdrawals 8420564024 - Check IPv6 connectivity 200167c2e848 - Multi-homed prefix 199780024

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 25: Using RIPEstat

RIPE RIPEstat MENOG 14

5 Letrsquos BGPlayTasks

_ Find the up-stream provider for AS1205 _ Is AS3333 multi-homed _ Check the IPv6 connectivity of your own network

25

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 26: Using RIPEstat

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site Embedding widgets

_ What is the conceptWidgets are based purely on web standards and were developed with embeddability in mind Every widget available via the RIPEstat web interface can be embedded on your own site

_ RIPEstat Widget API documentation httpsstatripenetdocswidget_api

26

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 27: Using RIPEstat

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site

27

Prefix Count widget

AS Path Length widget

This ISP embedded widgets on its page

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 28: Using RIPEstat

RIPE RIPEstat MENOG 14

6 Embedding Widgets On Your Own Site (Task)Tasks

_ Create a simple dashboard page to monitor your network _ Create a simple HTML page

_ download the sample page httpsstatripenetwidgetsmenogwidget_homehtml

_ Embed three widgets of your choice _ Make the widget smaller and remove the RIPEstat logo

28

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 29: Using RIPEstat

RIPE RIPEstat MENOG 14

7 RIPEstat Data API Using raw data output

_ What is the conceptThe RIPEstat Data API provides the lowest level of access to data This data can be fed into custom applications or just used for scripting

_ RIPEstat Widget API documentation httpsstatripenetdocsdata_api

29

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 30: Using RIPEstat

RIPE RIPEstat MENOG 14

7 RIPEstat Data API (Task)Tasks

_ Use your browser to retrieve all announced prefixes for the AS6412 _ A simple check on your resource if it is seen on the Internet

_ Create a simple script using resource-overview or routing-status

30

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 31: Using RIPEstat

RIPE RIPEstat MENOG 14

8 RIPE AtlasCreating a user-defined measurement

_ httpsatlasripenet

31

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 32: Using RIPEstat

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)_ Create a Nagios check using the RIPEstat Data API

_ Nagios is a monitoring tool that supports the development of custom checks (like other similar tools)

_ Result codes for a check show the state

32

State Result Code

Ok 0

Warning 1

Error 2

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 33: Using RIPEstat

RIPE RIPEstat MENOG 14

9 Create a Nagios check (optional)Example of a Python based check

33

if argstransit transit = argstransitsplit()origin = argsoriginsplit()nagios_status = 0origin_errors = 0transit_errors = 0nagios_message = url = httpssdatalooking-glassdatajsonresource=s (argsstatserver urllib2quote(argsprefix ))lookingglass_raw = urllib2urlopen(url)lookingglass_json = jsonload(lookingglass_raw)if lookingglass_json[data_call_status] = supported print WARN s is under maintance (argsstatserver) sysexit(1)for rrc in lookingglass_json[data][rrcs] for peer in lookingglass_json[data][rrcs][rrc][entries] aspath = peer[as_path]split() details = peer[details][0]split() peer_addr = details[0] nexthop = details[2] router_id = details[3] if len(aspath) gt argsminpath if aspath[-1] not in origin origin_errors += 1 nagios_message = nagios_message + ( Origin missmatch s (s) s (rrc peer_addr aspath[-1])) if argstransit if aspath[-2] not in transit transit_errors += 1 nagios_message = nagios_message + ( Transit missmatch s (s) s (rrc peer_addr aspath[-2]))if origin_errors == 0 and transit_errors == 0 nagios_message = OK s Origin is s (argsprefix argsorigin) if argstransit nagios_message = s and all transits match s (nagios_message argstransit) elif origin_errors gt= argscrit or transit_errors gt= argscrit nagios_status = 2 nagios_message = ERROR + nagios_messageelif origin_errors gt= argswarn or transit_errors gt= argswarn nagios_status = 1 nagios_message = WARN + nagios_message

Page 34: Using RIPEstat