Setting up BGP on the MetaNET

BGP peering on the MetaNET will eventually involve two route-servers. For now, you can peer with deuterium on its own. If you really want to, you can peer with other MetaNET nodes, thats up to you and them to negotiate.

For BGP peering to work, both neighbors need to have entries for each other, describing their remote-as, and including things such as prefix-lists for route filtering.

Deuterium has the AS 64900. Its neighbor IP is

We'll setup a test network with the AS 64899. Its internal IP range is, and its routers IP address is NOTE AS 64899 and the IP range are EXAMPLEs only. DO NOT attempt to use these. Please get your own IP range and AS allocated. Read the section later on the registry to see how to obtain your AS number

In our /etc/zebra/bgpd.conf we have the usual garbage at the top: hostname, password, enable passwd etc.

NOTE Make sure you EDIT this bgp config before trying to run it. There is a cleaner formatted version at the bottom of this page. You will need to change your AS number (router bgp ...), your router-id, and the networks you wish to advertise - both in the network line, and in the prefix-list line.

Then we set up a bgp router process:

 ! the following sets up a bgp router process with the local AS of 64899
 router bgp 64899
 ! this assigns the bgp router-id of to this router
  bgp router-id
 ! we want to advertise this network to our bgp peers

 ! this sets up deuterium (as 64900) as a neighbor on
  neighbor remote-as 64900
  neighbor ebgp-multihop
 ! these commands apply the prefix-lists below
  neighbor prefix-list as-64899 out
  neighbor prefix-list as-64900 in
 ! these prefix lists limit which ip ranges we will send out
 ip prefix-list as-64899 seq 5 permit
 ! and allow in.
 ip prefix-list as-64900 seq 5 permit le 32

A word on prefix lists. The prefix-list for as-64899 will only permit - it wont allow any other networks. If you had two networks you wished to advertise, you could that with

 ip prefix-list as-64899 seq 5 permit
 ip prefix-list as-64899 seq 10 permit

Also, note that the prefix-list for as-64900 has 'le 32' at the end. This allows a range of prefixes to match - it will match prefixes from down to /32. This effectively matches all metanet routes, including the host route for deuterium (

Once you've set your end up, and you've updated your details in the metanet registry, deuterium (and eventually hoiho) will update their config, and very shortly you should be peering with the route servers.

MetaNET Registry:

Go to http://www.tla/maint if you are on the MetaNET already. If you aren't, go to You will need a password for this, which you will need to get off one of the MetaNET admins.

Fill in all your informtion in the Personal Information field. You'll get an IP block allocated to you - you can allocate blocks under this to other people if you want. EG, if you own, you can allocated /24's under that to other people. Fill in the domains/ nameservers etc pages too.

AS Allocations. This will automatically allocate you the next available AS. Don't ask for a specific one - you wont get it. Make sure you add in the MetaNET IP of your bgp speaker. This is your 192.168 address.

IP to AS Allocation. In here, you specify which netblocks you will be advertising. You should only be able to advertise netblocks which are under your control. This step is important as it gives the route servers information about which routes to accept from you.

BGP Diagnostics

If you telnet to localhost port bgpd, and enter enable mode, you can inspect some parts of the bgp router process

 show ip bgp
 BGP table version is 0, local router ID is
 Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
 Origin codes: i - IGP, e - EGP, ? - incomplete

   Network          Next Hop            Metric !LocPrf? Weight Path
   *>                           0 64900 64914 i
   *>                           0 64900 64902 ?
   *>                          0 64900 64911 i
   *>                          0 64900 64911 i
   *>                           0 64900 64905 i
   *>                            32768 i
   *>            20             0 64900 ?
   *>                          0 64900 i
   *>                          0 64900 64901 i
   *>                          0 64900 64906 i
   *>                          0 64900 64907 i
   *>                          0 64900 64915 i

   Total number of prefixes 12

So this shows all the routes I have received, the next hop ip (gateway ip), any metrics that have been applied, weights, and the path - which shows which AS I received the routes through. Note that there is one entry which has a metric of 20. This is being received via OSPF, which sets the default metric to 20, by deuterium's OSPF routing process, and is being redistributed via BGP to my node.

 # show ip bgp
 BGP routing table entry for
 Paths: (1 available, best #1, table Default-IP-Routing-Table)
  Not advertised to any peer
  64900 from (
      Origin IGP, localpref 100, valid, external, best
      Last update: Thu Mar  6 14:11:26 2003

This shows the bgp entry for the route to It shows the remote AS, and the path it takes, as well as some information about it

We have one metanet node that is connected via a tunnel to one of the other nodes. It is participating the BGP peering, and you will receive routes to it.

 # show ip bgp
 BGP routing table entry for
 Paths: (1 available, best #1, table Default-IP-Routing-Table)
   Not advertised to any peer
   64900 64911 from (
       Origin IGP, localpref 100, valid, external, best
       Last update: Thu Mar  6 14:11:26 2003

As you can see, there are two AS's in the AS list. This is because all traffic to is routed via (deuterium), as connets to the metanet via a tunnel to deuterium.

To check your route is being seen by other machines on the wand network you might want to check sample config:

 hostname bgpd
 password metanet
 enable password metanet
 log file /var/log/zebra/bgpd.log
 router bgp <YOUR AS NUMBER>
  bgp router-id <IP ADDRESS OF YOUR ROUTER>
  network <YOUR 10.* NETWORK>/24
  neighbor remote-as 64900
  neighbor ebgp-multihop
  neighbor prefix-list as-<YOUR AS> out
  neighbor prefix-list as-64900 in
 ip prefix-list as-<YOUR AS> seq 5 permit <YOUR 10.* NETWORK>/24
 ip prefix-list as-64900 seq 5 permit le 32

See BGPNotes for other general notes

lib/main.php:944: Notice: PageInfo: Cannot find action page

lib/main.php:839: Notice: PageInfo: Unknown action