[rancid] Re: spanning tree/portcost changes causing diffs

Lance rancid at gheek.net
Sun Aug 5 18:17:26 UTC 2007


Dave,

Robert has purposed a very simple fix just like mine. I have an option
to turn on/off the filtering of these config lines except I use the
syntax /^set spantree port.*/ because it will catch both of those
possible output lines and leaves the valid stuff.

In regard to the changes of spanning-tree stuff on IOS it will not show
up in your config thus never showing up in the CVS diff. The
differencing normally for something to show up IOS based is due to info
changes in the storage areas (flash/bootflash/etc). I personally have
ignored those commands as they serve no purpose for me. I would suggest
doing the same unless you have a very particular reason to capture the
images tha are stored on your devices.


-Lance

> -------- Original Message --------
> Subject: [rancid] Re: spanning tree/portcost changes causing diffs
> From: "Quast, Robert (InfoTechServ)" <QuastR at mail.ccsu.edu>
> Date: Sun, August 05, 2007 9:53 am
> To: <dbstewart at dswrite.com>,  <rancid-discuss at shrubbery.net>
>
> I just saw this thread and actually have something to contribute. I had
> this same problem several months ago.  After digging through the
> archives, I ended up adding some lines to just ignore "set spantree
> portfast" and "set spantree portinstancecost" in cat5rancid.  We have
> about 20 CatOS 4006's and have been running with these changes for about
> 4 months.  I added the below 2 statements to line 861 in
> rancid/bin/cat5rancid (you could search for "Dog gone Cool" in the
> file).  I basically found the section where they ignore certain commands
> and just copied the ones already there.
>
>         # Dog gone Cool matches to process the rest of the config
>         /^set spantree portcost / && next;
>         /^set spantree portinstancecost / && next;
>
>         /^#time: /              && next; # kill time:
>         /^tftp-server flash /   && next; # kill any tftp remains
>         /^ntp clock-period /    && next; # kill ntp clock-period
>         /^ length /             && next; # kill length on serial lines
>         /^ width /              && next; # kill width on serial lines
>
> Oh and the only times I see where the memory bytes change are when
> switches either reboot or someone performs a write in IOS without making
> any changes, doesn't happen that often.
>
>
> Rob Quast
> Tech Systems
> Central Connecticut State University
> (860) 832-2057
> quastr at ccsu.edu
>
>
>
>
>
> -----Original Message-----
> From: rancid-discuss-bounces at shrubbery.net
> [mailto:rancid-discuss-bounces at shrubbery.net] On Behalf Of David B.
> Stewart
> Sent: Saturday, August 04, 2007 2:22 PM
> To: rancid-discuss at shrubbery.net
> Subject: [rancid] Re: spanning tree/portcost changes causing diffs
>
> Ah, but the problem isn't limited to CatOS.  Though the format and
> content is different, I see regular VLAN port state
> changes acknowledged by all switches - IOS and CatOS.  CVS may not be
> affected for IOS, but the diff is run and reported
> regardless.
>
> Similar nag reports are noted for Flash changes.  They are usually 1 to
> 3 byte changes in the amount of memory reported
> by IOS.  No significance found (and no understanding of why the sizes
> would fluctuate), but it is a diff and gets
> reported nonetheless.
>
> Looking forward to the changes.
> Dave
>
> -----Original Message-----
> From: Lance [mailto:rancid at gheek.net]
> Sent: Saturday, August 04, 2007 12:57 PM
> To: dbstewart at dswrite.com
> Cc: rancid-discuss at shrubbery.net
> Subject: RE: [rancid] Re: spanning tree/portcost changes causing diffs
>
>
> All,
>
> To kill this one once and for all I will answer some questions.
>
> 1.) Yes CVS will fill up because the Catalyst OS based switches save
> changes like these in the configuration. You don't
> see this in the IOS versions because they don't save this i the
> configuration.
> 2.) I completely agree. Which is why I have written changes to
> cat5rancid so it will no longer see these changes. I will
> share these changes .... well the simple ugly fix for these. I can not
> say they will work on all OSes but I know for
> sure it runs just fine on Redhat 9 (yes old, but it was an old server I
> had) and Suse 9.3 (yes old once again, but it is
> my tools server. :( ). I will post this complete change on Monday/maybe
> this weekend if I get time as I need to still
> add the configuration option to turn it on/off. That is extremely simple
> but would like to test it first, before telling
> people to use it.
>
>
> Hopefully my simple but ugly fix will work you Dave an many more that
> tend to do just like most everyone ignore the
> changes due to the sheer number of "set spantree port" messages. Well at
> least to me these are the noisy ones.
>
> -lance
>
> > -------- Original Message --------
> > Subject: [rancid] Re: spanning tree/portcost changes causing diffs
> > From: "David B. Stewart" <dbstewart at dswrite.com>
> > Date: Sat, August 04, 2007 5:26 am
> > To: <rancid-discuss at shrubbery.net>
> >
> > What I don't understand is why anyone would want "normal" network
> > activity 1) filling up CVS and 2) causing nuisance email
> > notifications.  Anyone know why the feature was added in the first
> > place?  Maybe it was intended as a poor-man's network monitoring tool,
>
> > but it's a real pain on a larger enterprise.  The sheer bulk of
> > nuisance notifications by email has caused my organization to ignore
> > rancid notifications altogether. -Dave
> >
> > -----Original Message-----
> > From: rancid-discuss-bounces at shrubbery.net
> > [mailto:rancid-discuss-bounces at shrubbery.net] On Behalf Of Lance
> > Sent: Friday, August 03, 2007 11:16 AM
> > To: Laker Netman
> > Cc: rancid-discuss at shrubbery.net
> > Subject: [rancid] Re: spanning tree/portcost changes causing diffs
> >
> >
> > Laker,
> >
> > So in other words you don't want to see them even in the CVS repo
> > correct? Filtering them out of the email is cake. 1 change to
> > control_rancid and you are good to go.
> >
> > -Lance
> >
> > > -------- Original Message --------
> > > Subject: Re: [rancid]  spanning tree/portcost changes causing diffs
> > > From: Laker Netman <laker_netman at yahoo.com>
> > > Date: Fri, August 03, 2007 6:51 am
> > > To: Lance <rancid at gheek.net>
> > > Cc: rancid-discuss at shrubbery.net
> > >
> > > I understand that, but I'd prefer not to have them appear as
> > > configuration changes if possible, i.e., have the script ignore
> > > changes to those lines.  It wouldn't affect restoring a config,
> > > because the switch would set the ports to their correct state
> > > anyway.
> > >
> > > Laker
> > >
> > > ----- Original Message ----
> > > From: Lance <rancid at gheek.net>
> > > To: Laker Netman <laker_netman at yahoo.com>
> > > Cc: rancid-discuss at shrubbery.net
> > > Sent: Thursday, August 2, 2007 7:12:29 PM
> > > Subject: RE: [rancid]  spanning tree/portcost changes causing diffs
> > >
> > > Laker,
> > >
> > > This is directly related to ports changing state (aka someone
> > > turning on/off their pc).
> > >
> > > -Lance
> > >
> > >
> > > > -------- Original Message --------
> > > > Subject: Re: [rancid]  spanning tree/portcost changes causing
> > > > diffs
> > > > From: Laker Netman <laker_netman at yahoo.com>
> > > > Date: Thu, August 02, 2007 1:13 pm
> > > > To: Lance <rancid at gheek.net>
> > > > Cc: rancid-discuss at shrubbery.net
> > > >
> > > > Here's and example of what I get in email and CVS:
> > > >
> > > > Index: configs/192.168.20.206
> > > > ==================================================================
> > > > =
> > > > retrieving revision 1.38
> > > > diff -U4 -r1.38 192.168.20.206
> > > > @@ -1072,10 +1072,10 @@
> > > >   set trunk 4/46 auto negotiate 1-1005,1025-4094
> > > >   set trunk 4/47 auto negotiate 1-1005,1025-4094
> > > >   set trunk 4/48 auto negotiate 1-1005,1025-4094
> > > >   set spantree portfast    4/1-48 disable
> > > > - set spantree portcost
> 4/1,4/5-10,4/12-13,4/21-22,4/25-26,4/31-32,4/38,4/45,4/47  19
> > > > - set spantree portcost
> 4/2-4,4/11,4/14-20,4/23-24,4/27-30,4/33-37,4/39-44,4/46,4/48  100
> > > > + set spantree portcost
> 4/1,4/5-10,4/12-13,4/21-22,4/25-26,4/28,4/31-32,4/38,4/45,4/47  19
> > > > + set spantree portcost
> 4/2-4,4/11,4/14-20,4/23-24,4/27,4/29-30,4/33-37,4/39-44,4/46,4/48  100
> > > >   set spantree portpri     4/1-48  32
> > > >   set spantree portvlanpri 4/1  0
> > > >   set spantree portvlanpri 4/2  0
> > > >   set spantree portvlanpri 4/3  0
> > > > @@ -1150,9 +1150,9 @@
> > > >   set spantree portvlancost 4/24 cost 99
> > > >   set spantree portvlancost 4/25 cost 18
> > > >   set spantree portvlancost 4/26 cost 18
> > > >   set spantree portvlancost 4/27 cost 99
> > > > - set spantree portvlancost 4/28 cost 99
> > > > + set spantree portvlancost 4/28 cost 18
> > > >   set spantree portvlancost 4/29 cost 99
> > > >   set spantree portvlancost 4/30 cost 99
> > > >   set spantree portvlancost 4/31 cost 18
> > > >   set spantree portvlancost 4/32 cost 18
> > > > @@ -1270,10 +1270,10 @@
> > > >   set trunk 5/47 auto negotiate 1-1005,1025-4094
> > > >   set trunk 5/48 auto negotiate 1-1005,1025-4094
> > > >   set spantree portfast    5/26 enable
> > > >   set spantree portfast    5/1-25,5/27-48 disable
> > > > - set spantree portcost
> 5/4,5/6,5/9-12,5/14-15,5/19,5/22-24,5/28,5/33,5/35,5/38,5/41,5/44-45,5/4
> 8  19
> > > > - set spantree portcost
> 5/1-3,5/5,5/7-8,5/13,5/16-18,5/20-21,5/25-27,5/29-32,5/34,5/36-37,5/39-4
> 0,5/42-43,5/46-47
> > 100
> > > > + set spantree portcost
> 5/4,5/6,5/9-12,5/14-15,5/19,5/22-24,5/28,5/33,5/35,5/38,5/44-45,5/48  19
> > > > + set spantree portcost
> 5/1-3,5/5,5/7-8,5/13,5/16-18,5/20-21,5/25-27,5/29-32,5/34,5/36-37,5/39-4
> 3,5/46-47  100
> > > >   set spantree portpri     5/1-48  32
> > > >   set spantree portvlanpri 5/1  0
> > > >   set spantree portvlanpri 5/2  0
> > > >   set spantree portvlanpri 5/3  0
> > > > @@ -1361,9 +1361,9 @@
> > > >   set spantree portvlancost 5/37 cost 99
> > > >   set spantree portvlancost 5/38 cost 18
> > > >   set spantree portvlancost 5/39 cost 99
> > > >   set spantree portvlancost 5/40 cost 99
> > > > - set spantree portvlancost 5/41 cost 18
> > > > + set spantree portvlancost 5/41 cost 99
> > > >   set spantree portvlancost 5/42 cost 99
> > > >   set spantree portvlancost 5/43 cost 99
> > > >   set spantree portvlancost 5/44 cost 18
> > > >   set spantree portvlancost 5/45 cost 18
> > > > @@ -1466,10 +1466,10 @@
> > > >   set trunk 6/47 auto negotiate 1-1005,1025-4094
> > > >   set trunk 6/48 auto negotiate 1-1005,1025-4094
> > > >   set spantree portfast    6/2,6/37 enable
> > > >   set spantree portfast    6/1,6/3-36,6/38-48 disable
> > > > - set spantree portcost
> 6/1,6/3-5,6/9,6/15-18,6/23,6/37-38,6/40-43,6/46,6/48  19
> > > > - set spantree portcost
> 6/2,6/6-8,6/10-14,6/19-22,6/24-36,6/39,6/44-45,6/47  100
> > > > + set spantree portcost
> 6/1,6/3-5,6/9,6/13,6/15-18,6/23,6/37-38,6/40-43,6/46,6/48  19
> > > > + set spantree portcost
> 6/2,6/6-8,6/10-12,6/14,6/19-22,6/24-36,6/39,6/44-45,6/47  100
> > > >   set spantree portpri     6/1-48  32
> > > >   set spantree portvlanpri 6/1  0
> > > >   set spantree portvlanpri 6/2  0
> > > >   set spantree portvlanpri 6/3  0
> > > > @@ -1529,9 +1529,9 @@
> > > >   set spantree portvlancost 6/9  cost 18
> > > >   set spantree portvlancost 6/10 cost 99
> > > >   set spantree portvlancost 6/11 cost 99
> > > >   set spantree portvlancost 6/12 cost 99
> > > > - set spantree portvlancost 6/13 cost 99
> > > > + set spantree portvlancost 6/13 cost 18
> > > >   set spantree portvlancost 6/14 cost 99
> > > >   set spantree portvlancost 6/15 cost 18
> > > >   set spantree portvlancost 6/16 cost 18
> > > >   set spantree portvlancost 6/17 cost 18
> > > > Index: configs/192.168.20.219
> > > > ==================================================================
> > > > =
> > > > retrieving revision 1.28
> > > > diff -U4 -r1.28 192.168.20.219
> > > > @@ -668,10 +668,10 @@
> > > >   set trunk 3/46 auto dot1q 1-1005
> > > >   set trunk 3/47 auto dot1q 1-1005
> > > >   set trunk 3/48 auto dot1q 1-1005
> > > >   set spantree portfast    3/1-48 disable
> > > > - set spantree portcost
> 3/1-2,3/11-12,3/19,3/25,3/27-29,3/35,3/37-39,3/41,3/43,3/46-48  19
> > > > - set spantree portcost
> 3/3-10,3/13-18,3/20-24,3/26,3/30-34,3/36,3/40,3/42,3/44-45  100
> > > > + set spantree portcost
> 3/1,3/11-12,3/19,3/25,3/27-29,3/35,3/37-38,3/41,3/43,3/46-48  19
> > > > + set spantree portcost
> 3/2-10,3/13-18,3/20-24,3/26,3/30-34,3/36,3/39-40,3/42,3/44-45  100
> > > >   set spantree portpri     3/1-48  32
> > > >   set spantree portvlanpri 3/1  0
> > > >   set spantree portvlanpri 3/2  0
> > > >   set spantree portvlanpri 3/3  0
> > > > @@ -720,9 +720,9 @@
> > > >   set spantree portvlanpri 3/46 0
> > > >   set spantree portvlanpri 3/47 0
> > > >   set spantree portvlanpri 3/48 0
> > > >   set spantree portvlancost 3/1  cost 18
> > > > - set spantree portvlancost 3/2  cost 18
> > > > + set spantree portvlancost 3/2  cost 99
> > > >   set spantree portvlancost 3/3  cost 99
> > > >   set spantree portvlancost 3/4  cost 99
> > > >   set spantree portvlancost 3/5  cost 99
> > > >   set spantree portvlancost 3/6  cost 99
> > > > @@ -757,9 +757,9 @@
> > > >   set spantree portvlancost 3/35 cost 18
> > > >   set spantree portvlancost 3/36 cost 99
> > > >   set spantree portvlancost 3/37 cost 18
> > > >   set spantree portvlancost 3/38 cost 18
> > > > - set spantree portvlancost 3/39 cost 18
> > > > + set spantree portvlancost 3/39 cost 99
> > > >   set spantree portvlancost 3/40 cost 99
> > > >   set spantree portvlancost 3/41 cost 18
> > > >   set spantree portvlancost 3/42 cost 99
> > > >   set spantree portvlancost 3/43 cost 18
> > > > Index: configs/192.168.20.223
> > > > ==================================================================
> > > > =
> > > > retrieving revision 1.37
> > > > diff -U4 -r1.37 192.168.20.223
> > > > @@ -713,10 +713,10 @@
> > > >   set trunk 4/47 auto dot1q 1-1005
> > > >   set trunk 4/48 auto dot1q 1-1005
> > > >   set spantree portfast    4/14 enable
> > > >   set spantree portfast    4/1-13,4/15-48 disable
> > > > - set spantree portcost
> 4/1,4/10-11,4/17-18,4/21,4/23,4/25,4/27,4/29,4/32,4/34,4/38-39,4/42,4/44
> -45  19
> > > > - set spantree portcost
> 4/2-9,4/12-16,4/19-20,4/22,4/24,4/26,4/28,4/30-31,4/33,4/35-37,4/40-41,4
> /43,4/46-48
> 100
> > > > + set spantree portcost
> 4/1,4/10,4/17-18,4/21,4/23,4/25,4/27,4/29,4/32,4/34,4/38-39,4/42,4/44-45
> 19
> > > > + set spantree portcost
> 4/2-9,4/11-16,4/19-20,4/22,4/24,4/26,4/28,4/30-31,4/33,4/35-37,4/40-41,4
> /43,4/46-48
> 100
> > > >   set spantree portpri     4/1-48  32
> > > >   set spantree portvlanpri 4/1  0
> > > >   set spantree portvlanpri 4/2  0
> > > >   set spantree portvlanpri 4/3  0
> > > > @@ -774,9 +774,9 @@
> > > >   set spantree portvlancost 4/7  cost 99
> > > >   set spantree portvlancost 4/8  cost 99
> > > >   set spantree portvlancost 4/9  cost 99
> > > >   set spantree portvlancost 4/10 cost 18
> > > > - set spantree portvlancost 4/11 cost 18
> > > > + set spantree portvlancost 4/11 cost 99
> > > >   set spantree portvlancost 4/12 cost 99
> > > >   set spantree portvlancost 4/13 cost 99
> > > >   set spantree portvlancost 4/14 cost 99
> > > >   set spantree portvlancost 4/15 cost 99
> > > > @@ -889,10 +889,10 @@
> > > >   set trunk 5/47 auto dot1q 1-1005
> > > >   set trunk 5/48 auto dot1q 1-1005
> > > >   set spantree portfast    5/10 enable
> > > >   set spantree portfast    5/1-9,5/11-48 disable
> > > > - set spantree portcost
> 5/4,5/7,5/11-12,5/15,5/18,5/20,5/26-27,5/33,5/35-36,5/43  19
> > > > - set spantree portcost
> 5/1-3,5/5-6,5/8-10,5/13-14,5/16-17,5/19,5/21-25,5/28-32,5/34,5/37-42,5/4
> 4-48  100
> > > > + set spantree portcost
> 5/7,5/11-12,5/15,5/18,5/20,5/26-27,5/33,5/35-36,5/43  19
> > > > + set spantree portcost
> 5/1-6,5/8-10,5/13-14,5/16-17,5/19,5/21-25,5/28-32,5/34,5/37-42,5/44-48
> 100
> > > >   set spantree portpri     5/1-48  32
> > > >   set spantree portvlanpri 5/1  0
> > > >   set spantree portvlanpri 5/2  0
> > > >   set spantree portvlanpri 5/3  0
> > > > @@ -943,9 +943,9 @@
> > > >   set spantree portvlanpri 5/48 0
> > > >   set spantree portvlancost 5/1  cost 99
> > > >   set spantree portvlancost 5/2  cost 99
> > > >   set spantree portvlancost 5/3  cost 99
> > > > - set spantree portvlancost 5/4  cost 18
> > > > + set spantree portvlancost 5/4  cost 99
> > > >   set spantree portvlancost 5/5  cost 99
> > > >   set spantree portvlancost 5/6  cost 99
> > > >   set spantree portvlancost 5/7  cost 18
> > > >   set spantree portvlancost 5/8  cost 99
> > > > @@ -1063,10 +1063,10 @@
> > > >   set trunk 6/47 auto dot1q 1-1005
> > > >   set trunk 6/48 auto dot1q 1-1005
> > > >   set spantree portfast    6/29,6/32 enable
> > > >   set spantree portfast    6/1-28,6/30-31,6/33-48 disable
> > > > - set spantree portcost    6/9,6/17,6/26-27,6/30,6/33,6/36  19
> > > > - set spantree portcost
> 6/1-8,6/10-16,6/18-25,6/28-29,6/31-32,6/34-35,6/37-48  100
> > > > + set spantree portcost    6/9,6/17,6/24,6/26-27,6/30,6/33,6/36
> 19
> > > > + set spantree portcost
> 6/1-8,6/10-16,6/18-23,6/25,6/28-29,6/31-32,6/34-35,6/37-48  100
> > > >   set spantree portpri     6/1-48  32
> > > >   set spantree portvlanpri 6/1  0
> > > >   set spantree portvlanpri 6/2  0
> > > >   set spantree portvlanpri 6/3  0
> > > > @@ -1137,9 +1137,9 @@
> > > >   set spantree portvlancost 6/20 cost 99
> > > >   set spantree portvlancost 6/21 cost 99
> > > >   set spantree portvlancost 6/22 cost 99
> > > >   set spantree portvlancost 6/23 cost 99
> > > > - set spantree portvlancost 6/24 cost 99
> > > > + set spantree portvlancost 6/24 cost 18
> > > >   set spantree portvlancost 6/25 cost 99
> > > >   set spantree portvlancost 6/26 cost 18
> > > >   set spantree portvlancost 6/27 cost 18
> > > >   set spantree portvlancost 6/28 cost 99
> > > >
> > > > ----- Original Message ----
> > > > From: Lance <rancid at gheek.net>
> > > > To: Laker Netman <laker_netman at yahoo.com>
> > > > Cc: rancid-discuss at shrubbery.net
> > > > Sent: Wednesday, August 1, 2007 2:39:20 PM
> > > > Subject: RE: [rancid]  spanning tree/portcost changes causing
> > > > diffs
> > > >
> > > > Maybe I am a little crazy but I don't think it would be that hard
> > > > to do. Of course if depends where you want the changes to be
> > > > ignored. If you want them to be tracked in CVS but not in the
> > > > emails then I think that is easy to do, but I would like to see
> > > > the emails reflect the CVS repo. So saying that I would say you
> > > > either keep them or get rid of them with an option in rancid.conf.
> > > >
> > > > Opinions?
> > > >
> > > > -Lance
> > > >
> > > > > -------- Original Message --------
> > > > > Subject: [rancid]  spanning tree/portcost changes causing diffs
> > > > > From: Laker Netman <laker_netman at yahoo.com>
> > > > > Date: Wed, August 01, 2007 12:11 pm
> > > > > To: rancid-discuss at shrubbery.net
> > > > >
> > > > > I have read several threads on the subject of portcost changes
> > > > > creating bogus diffs, but I haven't found one that presents a
> > > > > solution.  Is there one?
> > > > >
> > > > > I am running RANCID 2.3.2a6
> > > > >
> > > > >
> > > > > Thanks,
> > > > > Laker
> > > > >
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > ________________________________________________________________
> > > > > ____________________
> > > > > Fussy? Opinionated? Impossible to please? Perfect.  Join
> Yahoo!'s user panel and lay it on us.
> > http://surveylink.yahoo.com/gmrs/yahoo_panel_invite.asp?a=7
> > > > >
> > > > > _______________________________________________
> > > > > Rancid-discuss mailing list Rancid-discuss at shrubbery.net
> > > > > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > __________________________________________________________________
> > > > __
> > > > ________________
> > > > Choose the right car based on your needs.  Check out Yahoo! Autos
> new Car Finder tool.
> > > > http://autos.yahoo.com/carfinder/
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > > ____________________________________________________________________
> > > __
> > > ______________Ready for the edge of your seat?
> > > Check out tonight's top picks on Yahoo! TV.
> > > http://tv.yahoo.com/
> >
> > _______________________________________________
> > Rancid-discuss mailing list
> > Rancid-discuss at shrubbery.net
> > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss
> >
> > _______________________________________________
> > Rancid-discuss mailing list
> > Rancid-discuss at shrubbery.net
> > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss
>
>
> _______________________________________________
> Rancid-discuss mailing list
> Rancid-discuss at shrubbery.net
> http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss
> _______________________________________________
> Rancid-discuss mailing list
> Rancid-discuss at shrubbery.net
> http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss



More information about the Rancid-discuss mailing list