BGP info
Stafford A. Rau
srau at rauhaus.org
Tue Feb 7 17:32:34 UTC 2006
* Kanagaraj Krishna <kanagaraj at aims.com.my> [060206 23:28]:
> Hi,
> I'm currently using RANCID to do configuration backups. As anyone
> used it to capture BGP related info on Cisco and Juniper?
> Basically "sh ip bgp summary" on Cisco and "sh bgp summary" on
> Juniper. The purpose is to monitor BGP session changes with peers.
> It would be helpful if any examples are available. Thanks.
I use the clogin (jlogin for $J devices) program from RANCID in a lot of
quick little perl scripts. I find it a better solution than using
Net::Telnet::Cisco, as that library doesn't support ssh while clogin
does.
Something like so:
foreach my $router (@bgp_speakers) {
open CLOGIN,
"/usr/local/rancid2/bin/clogin -c \"show ip bgp sum\" $router|"
or die "Can't open CLOGIN: $!";
while (<CLOGIN>) {
...etc...
--Stafford
More information about the Rancid-discuss
mailing list