Discussion:
[rancid] Help to add new command in rancid script
Max Vaillant
2013-12-17 00:51:13 UTC
Permalink
Hi, thanks for the helpful cdp routine. My perl skills are non-existent but it seems that the posted code has too many line breaks.

Could I bother you for the code in text form?

I found your post here: http://www.shrubbery.net/pipermail/rancid-discuss/2012-February/006228.html


Max Vaillant
SENIOR NETWORK ENGINEER

415.590.8775 OFFICE
415.789.6298 MOBILE

deem.com
Alan McKinnon
2013-12-17 08:20:48 UTC
Permalink
Post by Max Vaillant
Hi, thanks for the helpful cdp routine. My perl skills are non-existent
but it seems that the posted code has too many line breaks.
Could I bother you for the code in text form?
http://www.shrubbery.net/pipermail/rancid-discuss/2012-February/006228.html
This part near the end of the routine:

"!CDP: Device: $deviceID Platform: $platform
Interface: $1\n") && next;


should be on one line. It got wrapped at column 80.

You will also need to add a line like this to @commandtable (near the
end of the rancid script)

{'show cdp neighbor detail' => 'ShowCDPDetail'},

otherwise your new code will never be called. Just after "show shun" is
a good place.
--
Alan McKinnon
***@gmail.com
Loading...