I'd like to use the BGP component of XORP to forward routes along with some additional per route data across an existing network. The machine has a wireless card that connects to a mesh network. The wireless card runs its own layer 2 routing protocol internally. From the wireless card, I'm collecting reachable hosts and forwarding them via BGP to the local XORP daemon. I use BGP so that I can also forward additional required information about the devices as BGP options to remote systems that are running the same collect/forward daemon. The entire wireless network appears as a flat class A network to devices on the network.<br>
<div class="gmail_quote">
<br>Ok, so each machine that connects to the wireless network and runs an XORP daemon to bridge that network across a backhaul would have an XORP boot file that looks like the following:<br><br>interfaces {<br> interface mea0 {<br>
default-system-config<br> }<br> interface eth0 {<br> default-system-config<br> }<br>}<br><br>fea {<br> unicast-forwarding4 {<br> disable: false<br> }<br>}<br><br>protocols {<br> bgp {<br> bgp-id: <a href="http://192.168.1.136" target="_blank">192.168.1.136</a> /* backhaul IP */<br>
local-as: 65002 /* local AS */<br><br> peer <a href="http://127.0.0.1" target="_blank">127.0.0.1</a> {<br> local-ip: <a href="http://10.54.12.1" target="_blank">10.54.12.1</a> /* wireless IP */<br>
as: 65002 /* local AS */<br>
next-hop: <a href="http://10.54.12.1" target="_blank">10.54.12.1</a> /* wireless IP */<br> holdtime: 0<br> }<br> peer <a href="http://192.168.1.126" target="_blank">192.168.1.126</a> { /* backhaul router */<br>
local-ip: <a href="http://192.168.1.136" target="_blank">192.168.1.136</a> /* backhaul IP */<br>
as: 65000 /* AS of backhaul network */<br> next-hop: <a href="http://192.168.1.136" target="_blank">192.168.1.136</a> /* wireless IP */<br> }<br> }<br>}<br><br>So the XORP daemon comes up, and has the following connected routes:<br>
<br>root@russ-laptop> show route table ipv4 unicast connected <br><a href="http://10.0.0.0/8" target="_blank">10.0.0.0/8</a> [connected(0)/0]<br> > via mea0/mea0<br><a href="http://192.168.1.0/24" target="_blank">192.168.1.0/24</a> [connected(0)/0]<br>
> via eth0/eth0<br><br>And connects with the following BGP peers:<br>root@russ-laptop> show bgp peers detail<br>Peer 1: local <a href="http://10.0.0.1/179" target="_blank">10.0.0.1/179</a> remote <a href="http://127.0.0.1/179" target="_blank">127.0.0.1/179</a><br>
Peer ID: <a href="http://10.0.0.1" target="_blank">10.0.0.1</a><br> Peer State: ESTABLISHED<br> Admin State: START<br> Negotiated BGP Version: 4<br> Peer AS Number: 65002<br> Updates Received: 1, Updates Sent: 0<br>
Messages Received: 3, Messages Sent: 2<br>
Time since last received update: 51 seconds<br> Number of transitions to ESTABLISHED: 1<br> Time since last entering ESTABLISHED state: 51 seconds<br> Retry Interval: 120 seconds<br> Hold Time: 0 seconds, Keep Alive Time: 0 seconds<br>
Configured Hold Time: 0 seconds, Configured Keep Alive Time: 0 seconds<br> Minimum AS Origination Interval: 0 seconds<br> Minimum Route Advertisement Interval: 0 seconds<br><br>Peer 2: local <a href="http://192.168.1.136/179" target="_blank">192.168.1.136/179</a> remote <a href="http://192.168.1.126/179" target="_blank">192.168.1.126/179</a><br>
Peer ID: <a href="http://192.168.1.126" target="_blank">192.168.1.126</a><br> Peer State: ESTABLISHED<br> Admin State: START<br> Negotiated BGP Version: 4<br> Peer AS Number: 65000<br> Updates Received: 0, Updates Sent: 0<br>
Messages Received: 3, Messages Sent: 3<br>
Time since last received update: n/a<br> Number of transitions to ESTABLISHED: 1<br> Time since last entering ESTABLISHED state: 51 seconds<br> Retry Interval: 120 seconds<br> Hold Time: 90 seconds, Keep Alive Time: 30 seconds<br>
Configured Hold Time: 90 seconds, Configured Keep Alive Time: 30 seconds<br> Minimum AS Origination Interval: 0 seconds<br> Minimum Route Advertisement Interval: 0 seconds<br><br>The local collect/forward daemon talks to XORP and the following shows up in XORP:<br>
<br>root@russ-laptop> show bgp routes<br>Status Codes: * valid route, > best route<br>Origin Codes: i IGP, e EGP, ? incomplete<br><br> Prefix Nexthop Peer AS Path<br> ------ ------- ---- -------<br>
* <a href="http://10.170.232.0/24" target="_blank">10.170.232.0/24</a> <a href="http://10.170.232.1" target="_blank">10.170.232.1</a> <a href="http://10.0.0.1" target="_blank">10.0.0.1</a> 65002 i<br>
* <a href="http://10.172.51.0/24" target="_blank">10.172.51.0/24</a> <a href="http://10.172.51.1" target="_blank">10.172.51.1</a> <a href="http://10.0.0.1" target="_blank">10.0.0.1</a> 65002 i<br>
<br>root@russ-laptop> show bgp routes detail<br><a href="http://10.170.232.0/24" target="_blank">10.170.232.0/24</a><br> From peer: <a href="http://10.0.0.1" target="_blank">10.0.0.1</a><br> Route: Not Used<br> Origin: IGP<br>
AS Path: 65002<br>
Nexthop: <a href="http://10.170.232.1" target="_blank">10.170.232.1</a><br><a href="http://10.172.51.0/24" target="_blank">10.172.51.0/24</a><br> From peer: <a href="http://10.0.0.1" target="_blank">10.0.0.1</a><br>
Route: Not Used<br> Origin: IGP<br> AS Path: 65002<br>
Nexthop: <a href="http://10.172.51.1" target="_blank">10.172.51.1</a><br><br>However, no local routes are added:<br><br>ip route<br><a href="http://192.168.1.0/24" target="_blank">192.168.1.0/24</a> dev eth0 proto kernel scope link src <a href="http://192.168.1.136" target="_blank">192.168.1.136</a> metric 2 <br>
<a href="http://169.254.0.0/16" target="_blank">169.254.0.0/16</a> dev eth0 scope link metric 1000 <br><a href="http://10.0.0.0/8" target="_blank">10.0.0.0/8</a> dev mea0 scope link <br>default via <a href="http://192.168.1.1" target="_blank">192.168.1.1</a> dev eth0 <br>
<br>And no updates are sent to the backhaul peer.<br>
</div><br>Both peers are running XORP 1.5-6 from debian.<br>