From: Marko Milivojevic (markom@vodafone.is)
Date: Thu Sep 20 2007 - 10:18:11 ART
> how to find out remote router AS ,without accessing that router.
> i am able to ping that router and use sort of debug command but still not able
> to identify remote router as.
> is it away to find out ?
There was a discussion about this the other day on this very forum.
Say that you have two routers R1 and R2:
R1---(192.168.12.0/24)---R2
R1: 192.168.12.1; AS100
R2: 192.168.12.2; AS200
You configure peering like this:
R1:
router bgp 100
bgp log-neighbor-changes
neighbor 192.168.12.2 remote-as 500
!
R2:
router bgp 200
bgp log-neighbor-changes
neighbor 192.168.12.1 remote-as 100
!
After short period of time, error messages like these will start popping up
(unless you guess ASN by some chance):
> *Sep 20 13:05:30.307: %BGP-3-NOTIFICATION: sent to neighbor
> 192.168.12.2 2/2 (peer in wrong AS) 2 bytes 00C8
The hex number 00C8 at the end of the message indicates what ASN is
configured on the remote router. 0x00C8 = 200. Based on that, you
can change your configuration.
This is sometimes confusing issue, so here's a bit more clarification.
Notice that other end will also get log messages:
> *Sep 20 13:12:44.343: %BGP-3-NOTIFICATION: received from neighbor
> 192.168.12.1 2/2 (peer in wrong AS) 2 bytes 00C8
The difference is in "received from neighbor", as opposed to "sent to
neighbor". Notification will be sent from the peer that has neighbor
statement configured to something othar than remote BGP process is
configured to.
In a lab scenario, if you are connecting to BB router and you get message
with "notification received", that will indicate that you may need to use
"local-as" in order to establish peering. In the case of "notification
sent", neighbor statement needs to be fixed accordingly.
Kind regards,
Marko (#18427)
This archive was generated by hypermail 2.1.4 : Sat Oct 06 2007 - 12:01:14 ART