[rancid] Reasoning behind not running a "show vlan" if specific VTP options are set?

Lee ler762 at gmail.com
Fri Jan 13 15:24:43 UTC 2017


On 1/13/17, Mischa Diehm <mischa.diehm at unibas.ch> wrote:
> Hi
>
> I was wondering why we didn’t get any
> !VLAN…
> lines for our nexus 7700 rancid runs and found out that on the nexus a „show
> vtp“ gives:
>
> XXX-cc# show vtp status
> Service not enabled
>
> looking at the code I found that in /usr/share/perl5/rancid/nxos.pm:
>
> In sub ShowVTP
>         # Nexus 5k and 1000v do note support vtp
>         if (!/^VTP Operating Mode\s+:\s+(Transparent|Server)/) {
>             $DO_SHOW_VLAN = 0;
>         }
> and later in sub ShowVLAN:
>
>     ($_ = <$INPUT>, return(1)) if (!$DO_SHOW_VLAN);
>
> Similar for ios.. I wonder why it would be bad to have the output of „show
> vlan“ in the config even if we were running the VTP-Modes exclude like
> „Server“. Okay the vlan configs might be inside the config (not always like
> in the „Server“ case) but the „show vlan“ shows more information like which
> interfaces are configured etc. So wouldn’t it be good to just remove this
> restriction?

Yes.  Which is yet another reason why it's so nice having the source -
it's easy to make trivial changes like that.  Or adding commands like
'show vlan all-ports'

Regards,
Lee



More information about the Rancid-discuss mailing list