Newbie question

Andrew Fort afort at choqolat.org
Thu Apr 1 21:53:31 UTC 2004


Jeff Aitken wrote:

>On Mon, Mar 29, 2004 at 06:37:14PM +0200, Otto, Axel wrote:
>  
>
>>Thanks a lot for your quick response, but this is exactly what I'm looking
>>for. I know that only the last "changer" will be saved that way but, based
>>on the fact that this would be stored at CVS, it would work for me.
>>    
>>
>
>I think this might do what you want:
>
>% diff -c rancid rancid.new
>*** rancid      Mon Mar 29 08:38:19 2004
>--- rancid.new  Mon Mar 29 08:40:59 2004
>***************
>*** 1130,1139 ****
>            }
>            tr/\015//d;
>        }
>-       # some versions have other crap mixed in with the bits in the
>-       # block above
>-       /^! (Last configuration|NVRAM config last)/ && next;
>- 
>        # skip consecutive comment lines to avoid oscillating extra comment
>        # line on some access servers.  grrr.
>        if (/^!/) {
>--- 1130,1135 ----
>
>
>
>--Jeff
>
>  
>

Yep, that'll do what he Axel wants.  Axel - you should look for 
'unexpected' diffs from the routers if you do apply the diff suggested 
above.  I suspect in newer IOSes the problem allured to there may have 
been cleared up, but you never know ;-).

If you run log-analysis software (such as the very powerful and 
recommended SEC (simple event correlator)), you can setup a rule to 
trigger RANCID (just for that device) when the log line coming from your 
router indicating that a particular device has had its configuration 
modified is seen.  SEC can auto-dampen the triggering of these events to 
avoid over-eager spawning of rancid collections.  I'd recommend this if 
you have the time - it's a good thing(tm).  It tends to encourage 
engineers not to idly jump in and out of config mode, too, if they know 
rancid is being triggered. :-)

-afort



More information about the Rancid-discuss mailing list