Subject: [GROW] A new bgpdump tool

From: Yasuhiro Ohara <[email-masked]>
Date: Thu, 05 Mar 2015 10:17:34 +0900 (JST)

Hi,

I'm developing a new tool that can read routeviews
RIB files (MRT v2 RIB format). I call it "bgpdump2". It is similar, but
with a few additional features, to the libbgpdump.
It is going to be open source (the process is on-going).

This e-mail is to consult if there is some interest in such a tool.
I'm considering to provide a presentation in Dallas.

The motivations of creating a brand new tool are below.
1. libbgpdump seemed to have some rooms to speed up, since
   it seems to issue many small-sized read operations, rather than
   making a small number of large-sized read operations.
2. I wanted to add a few additional features (explained below)
   to such tools.
3. it didn't seem easy to modify the libbgpdump for me.

The additional features include longest prefix matching using a
PATRICIA table inside the command, diff'ing the prefixes
between peers (Note, the BGP prefixes are stored per peer
in the RIB file), and to display of some statistics of RIBs per peer.

I am from a R&D division of a tier-1 ISP (i.e., NTT Communications),
and was trying to compare BGP full route routing table instances,
possibly between ISPs.  I expect that such a tool can contribute to
get a detailed view on how/why BGP full route routing tables are
different.  For example, we're going to need the longest matching
lookup function to see if the differentiating prefix is covered by a
shorter prefix.

However I'm not greatly succeeding so far, since the reason for
a prefix that is differentiating depends on case by case
(and there are various reasons including "the business relationship"),
and I could not get a summarized view after the comparison of
(say) two BGP full route routing tables.

I would like to get some feedback from the community on these things.
I can provide in Dallas some more details of my tool,
some performance benchmark of it,
and some statistics of RouteView's RIB files.

Would you kindly share your opinions on this ?

Thanks.

Best regards,
Yasu

---

From: John Kemp <[email-masked]>
Date: Thu, 05 Mar 2015 11:22:34 -0800

For the parser part, you might consider looking at the UCLA
bgpparser to see how they dealt with certain issues.

http://irl.cs.ucla.edu/software/bgpparser.html

For path questions, I'm guessing you might want to be looking
at route leaks.  If that is the case,

https://ripe69.ripe.net/presentations/157-RIPE-69-Routing-WG.pdf
https://ripe69.ripe.net/archives/video/10076/

The related definitions in GROW:
http://tools.ietf.org/pdf/draft-ietf-grow-route-leak-problem-definition-00.pdf

/jgk

On 3/4/15 5:17 PM, Yasuhiro Ohara wrote:
> _______________________________________________
> GROW mailing list
> [email-masked]
> https://www.ietf.org/mailman/listinfo/grow
>

---

From: Yasuhiro Ohara <[email-masked]>
Date: Fri, 06 Mar 2015 14:27:05 +0900 (JST)

Mr. Kemp,

Thank you for the information.

I have been kindly informed, also by others, of other BGP dump parsing
tools. I'm going to summarize it and send the list to the mailing-list.

Yes, I'm interested in route leaks. Now I'm wondering what kind of
functions are beneficial in a BGP dump tool to help people check or
find the route leaks. Please let me know if you have some idea.

Best regards,
Yasu

From: John Kemp <[email-masked]>
Subject: Re: [GROW] A new bgpdump tool
Date: Thu, 05 Mar 2015 11:22:34 -0800
Message-ID: <[email-masked]>

---

From: "Sriram, Kotikalapudi" <[email-masked]>
Date: Fri, 6 Mar 2015 15:19:02 +0000

>find the route leaks. Please let me know if you have some idea.

Some additional references related to determining AS relations, routing policies, 
and route leak detection/mitigation:

"Valley-free violation in Internet routing - Analysis based on BGP Community data"
http://ieeexplore.ieee.org/xpl/login.jsp?tp=&arnumber=6363987&url=http%3A%2F%2Fieeexplore.ieee.org%2Fxpls%2Fabs_all.jsp%3Farnumber%3D6363987 

"AS Relationships, Customer Cones, and Validation"
http://www.caida.org/~amogh/papers/asrank-IMC13.pdf 

"A Survey of Interdomain Routing Policies"
https://www.cs.bu.edu/~goldbe/papers/survey.pdf

"Methods for Detection and Mitigation of BGP Route Leaks"
https://tools.ietf.org/html/draft-sriram-route-leak-detection-mitigation-00
(to be presented in the IDR WG meeting in Dallas)

Sriram

---

From: John Kemp <[email-masked]>
Date: Fri, 06 Mar 2015 10:29:12 -0800

Yasuhiro,

We are sort of at two ends of the spectrum here.
If we are just talking about a simple tool, I guess the
point I was making was that somehow you probably want to
consider that there is a time domain.

For example, if your tool is parsing out ribs.  If it
could also read those back in, and then do "comm" kinds
of comparisons, then you could compare two ribs from different
times.  IE what is common, what is in both, what is only in
1 vs. 2, or 2 vs. 1.

Or a kind of regexp feature might be nice.  You probably
want ASPATH regexp to add to the prefix matching, as well
as next-longest/next-shortest matching....

/jgk

---

From: Yasuhiro Ohara <[email-masked]>
Date: Mon, 09 Mar 2015 13:51:07 +0900 (JST)

Hi John,

... I'm not sure yet if I'm following here.

I agree there are two perspectives, at least.
One is to compare the growth (time difference) of a
certain ISP's full-route routing table. Another is to
compare routing tables from different ISPs at a
certain time. However, I'm not sure what's the benefit
of comparing routing tables from two ISPs of different times.

The regexp is a great idea (I wonder why I couldn't think of it
myself from the first place). Even though I'm not sure if I can
implement all of them until the next IETF, I will work on it.

Thanks.

Best regards,
Yasu

From: John Kemp <[email-masked]>
Subject: Re: [GROW] A new bgpdump tool
Date: Fri, 06 Mar 2015 10:29:12 -0800
Message-ID: <[email-masked]>

---

From: Yasuhiro Ohara <[email-masked]>
Date: Fri, 20 Mar 2015 10:15:40 +0900 (JST)

Hi,

> tools. I'm going to summarize it and send the list to the mailing-list.

Below is the list of tools and some papers.

* Tools.

- libbgpdump
  written in C.
  <https://bitbucket.org/ripencc/bgpdump/wiki/Home>

- zebra-dump-parser
  written in Perl.
  <https://github.com/rfc1036/zebra-dump-parser>

- java-mrt library
  written in Java.
  <https://github.com/paaguti/java-mrt>

- UCLA bgpparser
  written in C++.
  <http://irl.cs.ucla.edu/software/bgpparser.html>

- mrtparse
  written in Python.
  <https://github.com/YoshiyukiYamauchi/mrtparse>

- bgpdump2
  written in C.
  <https://github.com/yasuhiro-ohara-ntt/bgpdump2>

* route leaks
  - <https://ripe69.ripe.net/presentations/157-RIPE-69-Routing-WG.pdf>
    <https://ripe69.ripe.net/archives/video/10076/>
  - <http://tools.ietf.org/pdf/draft-ietf-grow-route-leak-problem-definition-00.pdf>
  - <https://tools.ietf.org/html/draft-sriram-route-leak-detection-mitigation-00>
    (to be presented in the IDR WG meeting in Dallas)

* AS relations

  - Linxin Gao, "On inferring autonomous system relationships in the internet",
    IEEE/ACM Transactions on Networking (TON), Volume 9 Issue 6, December 2001,
    Pages 733-745.
    <https://dl.acm.org/citation.cfm?id=504611.504616>

  - Giotsas, V., "Valley-free violation in Internet routing -
    Analysis based on BGP Community data",
    <http://ieeexplore.ieee.org/xpl/login.jsp?tp=&arnumber=6363987>

  - "AS Relationships, Customer Cones, and Validation"
    <http://www.caida.org/~amogh/papers/asrank-IMC13.pdf>

  - "A Survey of Interdomain Routing Policies"
    <https://www.cs.bu.edu/~goldbe/papers/survey.pdf>

Best regards,
Yasu

From: Yasuhiro Ohara <[email-masked]>
Subject: Re: [GROW] A new bgpdump tool
Date: Fri, 06 Mar 2015 14:27:05 +0900 (JST)
Message-ID: <[email-masked]>

---

From: Claudio Jeker <[email-masked]>
Date: Fri, 20 Mar 2015 07:48:21 +0100

>     (to be presented in the IDR WG meeting in Dallas)

OpenBGPD's bgpctl is able to read mrt dump files as well. Currently only
table dumps are supported though.

- openbgpd bgpctl
  written in C.
  http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.sbin/bgpctl/

Cheers
-- 
Claudio

---

From: Nick Hilliard <[email-masked]>
Date: Fri, 20 Mar 2015 09:15:50 +0000

>   http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.sbin/bgpctl/

Hi Claudio,

Are there any plans to support this on operating systems other than openbsd?

Nick

---

From: Claudio Jeker <[email-masked]>
Date: Fri, 20 Mar 2015 14:02:13 +0100

> Are there any plans to support this on operating systems other than openbsd?

Some people ported it to FreeBSD and NetBSD. I also heard of a Linux
version (without FIB support). I personally do not plan to port OpenBGPD
to other platforms (there is more important things I like to implement in
OpenBGPD) but I'm happy to adjust our code to make porting easier.

-- 
:wq Claudio