nanog mailing list archives
Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension
From: Jason Hellenthal <jhellenthal () dataix net>
Date: Wed, 12 Oct 2016 08:28:44 -0500
Give these a shot. https://github.com/jlmcgraw/networkUtilities I know J could use a little feedback on those as well but all in all they are pretty solid.
On Oct 11, 2016, at 08:48, Lee <ler762 () gmail com> wrote: On 10/10/16, Jay Hennigan <jay () west net> wrote:On 10/6/16 1:26 PM, Jesse McGraw wrote:Nanog, (This is me scratching an itch of my own and hoping that sharing it might be useful to others on this list. Apologies if it isn't) When I'm trying to comprehend a new or complicated Cisco router, switch or firewall configuration an old pet-peeve of mine is how needlessly difficult it is to follow deeply nested logic in route-maps, ACLs, QoS policy-maps etc etc To make this a bit simpler I’ve been working on a perl script to convert these text-based configuration files into HTML with links between the different elements (e.g. To an access-list from the interface where it’s applied, from policy-maps to class-maps etc), hopefully making it easier to to follow the chain of logic via clicking links and using the forward and back buttons in your browser to go back and forth between command and referenced list.Way cool. Now to hook it into RANCID....It looks like what I did in 2.3.8 should still work - control_rancid puts the diff output into $TMP.diff so add this bit: grep "^Index: " $TMP.diff | awk '/^Index: configs/{ if ( ! got1 ) { printf("/usr/local/bin/myscript.sh "); got1=1; } printf("%s ", $2) } END{ printf("\n") } ' >$TMP.doit /bin/sh $TMP.doit >$TMP.out if [ -s $TMP.out ] ; then .. send mail / whatever rm $TMP.doit $TMP.out fi Regards, Lee
-- Jason Hellenthal JJH48-ARIN
Current thread:
- A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Jesse McGraw (Oct 06)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Lee (Oct 06)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Hank Nussbacher (Oct 06)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Lee (Oct 07)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Hank Nussbacher (Oct 08)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Lee (Oct 11)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Hank Nussbacher (Oct 06)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Lee (Oct 06)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Lee (Oct 11)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Jason Hellenthal (Oct 12)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Lee (Oct 12)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension shawn wilson (Oct 12)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Jesse McGraw (Oct 13)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Jason Hellenthal (Oct 13)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Lee (Oct 13)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Hank Nussbacher (Oct 13)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Jesse McGraw (Oct 13)
- <Possible follow-ups>
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Larry Sheldon (Oct 06)
- Re: A perl script to convert Cisco IOS/Nexus/ASA configurations to HTML for easier comprehension Ken Chase (Oct 20)