Monday, August 11, 2008

BGP - Neighbor discovery protocol

Ok. The title is misleading, there is no such thing!

But I was doing IPexpert's volume 1 section 11 lab on BGP and I thought this would be a cool topic since I always see some posts about this on groupstudy.

R9 is connected to the same LAN as BB3. We need to peer with BB3 but we don't know the IP or the AS number of BB3.

First, we can ping the broadcast address on the ethernet segment between R9 and BB3. This works best with only 1 other host. Otherwise we would have to resort to trial and error or some other means, maybe debug ip packet.

R9#ping 100.100.250.255

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 100.100.250.255, timeout is 2 seconds:

Reply to request 0 from 100.100.250.250, 4 ms
Reply to request 1 from 100.100.250.250, 1 ms
Reply to request 2 from 100.100.250.250, 1 ms

R9#


Now we know our peer ip, but we need to know the AS number. If you peer to the wrong AS, you can see the BB AS in message debug:

R9(config)#router bgp 19999
R9(config-router)#neighbor 100.100.250.250 remote-as 1

*Aug 12 02:57:05.411: %BGP-3-NOTIFICATION: sent to neighbor 100.100.250.250 2/2 (peer in wrong AS) 2 bytes 0DE9
FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF 002D 0104 0DE9 00B4 6E0F 90C8 1002 0601 0400 0100 0102 0280 0002 0202 00


Here the neighbor is in AS 0DE9 (3561)

R9(config)#router bgp 19999
R9(config-router)#neighbor 100.100.250.250 remote-as

*Aug 12 02:59:12.359: %BGP-5-ADJCHANGE: neighbor 100.100.250.250 Up


Cool, eh?

1 comment:

Note: Only a member of this blog may post a comment.