From peterjackson1610 at gmail.com Fri Mar 2 22:04:48 2012 From: peterjackson1610 at gmail.com (Peter Jackson) Date: Fri, 2 Mar 2012 17:04:48 -0500 Subject: [rancid] Palo Alto Networks Firewalls Support Message-ID: I saw one post from 2008 about Palo Alto Networks firewalls. Has anyone gotten RANCID to work with them? I've spent two days now and I'm not getting very far. I got palogin to work (re-worked clogin) and commands are sent to the firewall, but parancid (re-worked rancid) doesn't seem to like the prompt. The default prompt is username at hostname. RANCID doesn't appear to care about the @ but I'm not 100% on that. I'll try again next week. Have a nice weekend! -------------- next part -------------- An HTML attachment was scrubbed... URL: From gfong at cafepress.com Mon Mar 5 11:07:14 2012 From: gfong at cafepress.com (Gilbert Fong) Date: Mon, 5 Mar 2012 11:07:14 +0000 Subject: [rancid] getting flooded with false config change notice Message-ID: <64A81C8A3C3889498D8BE653E28F513B32B78B@ca1-2k8-mail01.corp.cafepress.com> Help!! I made some config changes to my switches (one week ago) and I have been getting the same message every hour about the same change that was made a week back. What happened? Thanks Gilbert --------------------------------------------------------------------------------------------------------------------- OUTPUT BELOW OUTPUT BELOW OUTPUT BELOW --------------------------------------------------------------------------------------------------------------------- Index: configs/swi-acs01 =================================================================== retrieving revision 1.41 diff -U 4 -r1.41 swi-acs01 @@ -38,20 +38,19 @@ !Variable: Config Download !Variable: via DHCP: disabled (next boot: disabled) ! !Flash: Directory of flash:/ - !Flash: 2 -rwx 5 Aug 24 2011 15:51:53 -04:00 private-config.text !Flash: 3 -rwx 9771282 Mar 17 2011 20:22:09 -04:00 c2960-lanbasek9-mz.122-55.SE1.bin - !Flash: 7 drwx 192 Feb 28 1993 19:07:24 -05:00 c2960-lanbase-mz.122-35.SE5 - !Flash: 626 -rwx 7521 Aug 24 2011 15:51:53 -04:00 config.text - !Flash: 32514048 bytes total (14395904 bytes free) + !Flash: 626 -rwx 1921 Mar 5 2012 05:19:32 -05:00 private-config.text + !Flash: 627 -rwx 7573 Mar 5 2012 05:19:32 -05:00 config.text + !Flash: 32514048 bytes total (22727680 bytes free) ! !Flash: nvram: Directory of nvram:/ - !Flash: nvram: 55 -rw- 7521 startup-config - !Flash: nvram: 56 ---- 5 private-config + !Flash: nvram: 55 -rw- 7573 startup-config + !Flash: nvram: 56 ---- 1921 private-config !Flash: nvram: 1 ---- 35 persistent-data !Flash: nvram: 2 -rw- 0 ifIndex-table - !Flash: nvram: 65536 bytes total (55910 bytes free) + !Flash: nvram: 65536 bytes total (53942 bytes free) ! !NAME: "1", DESCR: "WS-C2960G-48TC-L" !PID: WS-C2960G-48TC-L !VID: V03 @@ -154,18 +153,19 @@ ! aaa new-model ! aaa authentication login default group radius local - aaa authentication login CONSOLE none aaa authorization exec default group radius if-authenticated - aaa authorization exec CONSOLE none aaa accounting exec default start-stop group radius ! aaa session-id common clock timezone EST -5 clock summer-time EST recurring system mtu routing 1500 ! + no ip domain-lookup + ip domain-name xxxx.zzzz.com + ! archive log config logging enable logging size 250 @@ -438,9 +438,13 @@ radius-server vsa send authentication ! line con 0 line vty 0 4 + exec-timeout 60 0 ! password + transport input ssh line vty 5 15 + exec-timeout 60 0 + transport input ssh ! ntp server 204.74.68.55 prefer end The contents of this message, together with any attachments, are intended only for the use of the individual or entity to which they are addressed and may contain information that is confidential and exempt from disclosure. If you are not the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this message, or any attachment, is strictly prohibited. If you have received this message in error, please notify the original sender immediately by telephone or by return E-mail and delete this message, along with any attachments, from your computer. Thank you. -------------- next part -------------- An HTML attachment was scrubbed... URL: From shouldbeq931 at gmail.com Tue Mar 6 08:56:33 2012 From: shouldbeq931 at gmail.com (shouldbe q931) Date: Tue, 6 Mar 2012 00:56:33 -0800 Subject: [rancid] getting flooded with false config change notice In-Reply-To: <64A81C8A3C3889498D8BE653E28F513B32B78B@ca1-2k8-mail01.corp.cafepress.com> References: <64A81C8A3C3889498D8BE653E28F513B32B78B@ca1-2k8-mail01.corp.cafepress.com> Message-ID: On Mon, Mar 5, 2012 at 3:07 AM, Gilbert Fong wrote: > Help!! > > I made some config changes to my switches (one week ago) and > > I have been getting the same message every hour about the same change that > was made a week back. > > What happened? > > > > Thanks > > Gilbert > Can you please conform what change you made Cheers From michael at maymann.org Tue Mar 6 10:14:25 2012 From: michael at maymann.org (Michael Maymann) Date: Tue, 6 Mar 2012 11:14:25 +0100 Subject: [rancid] Full scheduled automated backup of Cisco ASA55XX Message-ID: Hi List, I would like to do _FULL_ scheduled automated backups of my ASA55XX: Unfortunately it seems that Cisco doesn't provide a CLI command that does this, so I have to gather all the info from different places myself (with the risk of forgetting something/missing something if the box gets updated): https://supportforums.cisco.com/message/3578075#3578075 - Does any of you have a working script that does this already ? - Does it distribute the information to the right files and zip it, so you get easy restorable file as ASDM:Tools->Backup Configurations ? Or do I really have to purchase CiscoWorks to get this functionality (thought I had already paid more than enough - and must admid, I really didn't think scheduled backup/easy restore would be an issue for the worlds nr1 network-company...!) Thanks in advance :) ! ~maymann -------------- next part -------------- An HTML attachment was scrubbed... URL: From adam.korab at gmail.com Tue Mar 6 17:22:41 2012 From: adam.korab at gmail.com (Adam Korab) Date: Tue, 6 Mar 2012 11:22:41 -0600 Subject: [rancid] Full scheduled automated backup of Cisco ASA55XX In-Reply-To: References: Message-ID: <-2820305914742700663@unknownmsgid> What about using cron to fire off clogin to execute 'copy run tftp' ? That would preserve your VPN per shared keys and combined with the config repo within rancid, you should have everything, from full configs to serial numbers etc. --Adam On Mar 6, 2012, at 4:15 AM, Michael Maymann wrote: Hi List, I would like to do _FULL_ scheduled automated backups of my ASA55XX: Unfortunately it seems that Cisco doesn't provide a CLI command that does this, so I have to gather all the info from different places myself (with the risk of forgetting something/missing something if the box gets updated): https://supportforums.cisco.com/message/3578075#3578075 - Does any of you have a working script that does this already ? - Does it distribute the information to the right files and zip it, so you get easy restorable file as ASDM:Tools->Backup Configurations ? Or do I really have to purchase CiscoWorks to get this functionality (thought I had already paid more than enough - and must admid, I really didn't think scheduled backup/easy restore would be an issue for the worlds nr1 network-company...!) Thanks in advance :) ! ~maymann _______________________________________________ Rancid-discuss mailing list Rancid-discuss at shrubbery.net http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss -------------- next part -------------- An HTML attachment was scrubbed... URL: From me at andytownsend.co.uk Tue Mar 6 17:45:48 2012 From: me at andytownsend.co.uk (Andy Townsend) Date: Tue, 6 Mar 2012 17:45:48 +0000 Subject: [rancid] Rancid CVS Issue Message-ID: Hi, I've just installed rancid on one of my boxes following the guide here. http://www.linuxhomenetworking.com/wiki/index.php/Quick_HOWTO_:_Ch1_:_Network_Backups_With_Rancid However, when I run the rancid-cvs command, I get no output. [rancid at router ~]$ /usr/local/rancid/bin/rancid-cvs [rancid at router ~]$ When as per the docs I should be getting this. [rancid at bigboy ~]$ /usr/local/rancid/bin/rancid-cvs No conflicts created by this import cvs checkout: Updating networking cvs checkout: Updating networking/configs cvs add: scheduling file `router.db' for addition cvs add: use 'cvs commit' to add this file permanently RCS file: /usr/local/rancid//var/CVS/networking/router.db,v done Checking in router.db; /usr/local/rancid//var/CVS/networking/router.db,v <-- router.db initial revision: 1.1 done CVS is already installed so no issues there, [rancid at router ~]$ rpm -qa | grep cvs cvs-1.11.22-7.el5 Just wondering if anyone had come across this or know what the next steps were? Cheers, Andy -------------- next part -------------- An HTML attachment was scrubbed... URL: From michael at maymann.org Tue Mar 6 18:05:43 2012 From: michael at maymann.org (Michael Maymann) Date: Tue, 6 Mar 2012 19:05:43 +0100 Subject: [rancid] Full scheduled automated backup of Cisco ASA55XX In-Reply-To: <-2820305914742700663@unknownmsgid> References: <-2820305914742700663@unknownmsgid> Message-ID: Hi, Adam: thanks for your quick reply :) 1. What is "config repo within rancid" and how do I configure this...? 2. Does ASA support SCP instead of TFTP - to make the transfer secure and so I don't have to configure a otherwise unneeded TFTP-server ? 3. Will this be easy restore'able like the zip-file created from ASDM, or do I have to manually put all information into the box by hand ? Thanks in advance :) ! ~maymann 2012/3/6 Adam Korab > What about using cron to fire off clogin to execute 'copy run tftp' ? > That would preserve your VPN per shared keys and combined with the config > repo within rancid, you should have everything, from full configs to serial > numbers etc. > > --Adam > > > > > On Mar 6, 2012, at 4:15 AM, Michael Maymann wrote: > > Hi List, > > I would like to do _FULL_ scheduled automated backups of my ASA55XX: > Unfortunately it seems that Cisco doesn't provide a CLI command that does > this, so I have to gather all the info from different places myself (with > the risk of forgetting something/missing something if the box gets updated): > https://supportforums.cisco.com/message/3578075#3578075 > > - Does any of you have a working script that does this already ? > - Does it distribute the information to the right files and zip it, so you > get easy restorable file as ASDM:Tools->Backup Configurations ? > > Or do I really have to purchase CiscoWorks to get this functionality > (thought I had already paid more than enough - and must admid, I really > didn't think scheduled backup/easy restore would be an issue for the worlds > nr1 network-company...!) > > > Thanks in advance :) ! > ~maymann > > _______________________________________________ > Rancid-discuss mailing list > Rancid-discuss at shrubbery.net > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Nicolai.Langfeldt at ventelo.no Tue Mar 6 19:44:35 2012 From: Nicolai.Langfeldt at ventelo.no (Nicolai Langfeldt) Date: Tue, 6 Mar 2012 20:44:35 +0100 Subject: [rancid] Rancid CVS Issue In-Reply-To: References: Message-ID: <9083709BCF00E0468332648EF6EC3BD8010471C7B8FF@P0OSLVEXMBX01.no.ventelo.local> I expect you either forgot to update rancid.conf so that it reads: LIST_OF_GROUPS="networking" Or you already did rancid-cvs? Nicolai ________________________________________ Fra: rancid-discuss-bounces at shrubbery.net [rancid-discuss-bounces at shrubbery.net] på vegne av Andy Townsend [me at andytownsend.co.uk] Sendt: 6. mars 2012 18:45 Til: rancid-discuss at shrubbery.net Emne: [rancid] Rancid CVS Issue Hi, I've just installed rancid on one of my boxes following the guide here. http://www.linuxhomenetworking.com/wiki/index.php/Quick_HOWTO_:_Ch1_:_Network_Backups_With_Rancid However, when I run the rancid-cvs command, I get no output. [rancid at router ~]$ /usr/local/rancid/bin/rancid-cvs [rancid at router ~]$ When as per the docs I should be getting this. [rancid at bigboy ~]$ /usr/local/rancid/bin/rancid-cvs No conflicts created by this import cvs checkout: Updating networking cvs checkout: Updating networking/configs cvs add: scheduling file `router.db' for addition cvs add: use 'cvs commit' to add this file permanently RCS file: /usr/local/rancid//var/CVS/networking/router.db,v done Checking in router.db; /usr/local/rancid//var/CVS/networking/router.db,v <-- router.db initial revision: 1.1 done CVS is already installed so no issues there, [rancid at router ~]$ rpm -qa | grep cvs cvs-1.11.22-7.el5 Just wondering if anyone had come across this or know what the next steps were? Cheers, Andy From me at andytownsend.co.uk Wed Mar 7 09:07:03 2012 From: me at andytownsend.co.uk (Andy Townsend) Date: Wed, 7 Mar 2012 09:07:03 +0000 Subject: [rancid] Rancid CVS Issue In-Reply-To: <9083709BCF00E0468332648EF6EC3BD8010471C7B8FF@P0OSLVEXMBX01.no.ventelo.local> References: <9083709BCF00E0468332648EF6EC3BD8010471C7B8FF@P0OSLVEXMBX01.no.ventelo.local> Message-ID: I've already got this in rancid.conf # list of rancid groups LIST_OF_GROUPS="networking" And when I run /usr/local/rancid/bin/rancid-cvs I get no output. [rancid at router ~]$ /usr/local/rancid/bin/rancid-cvs [rancid at router ~]$ [rancid at router ~]$ echo $BASEDIR [rancid at router ~]$ pwd /usr/local/rancid [rancid at router ~]$ ls -l total 60 drwxr-xr-x 2 rancid netadm 4096 Mar 6 17:26 bin drwxr-xr-x 2 rancid netadm 4096 Mar 7 09:04 etc -rw-r--r-- 1 rancid netadm 12738 Mar 6 17:22 README drwxr-xr-x 4 rancid netadm 4096 Mar 6 17:13 share drwxr-xr-x 3 rancid netadm 4096 Oct 26 21:51 tar drwxr-xr-x 5 rancid netadm 4096 Mar 6 17:21 var I believe there should be a CVS directory in there. I did install CVS after rancid so I guess that may have caused the issue. Any ideas? Thanks, Andy On 6 March 2012 19:44, Nicolai Langfeldt wrote: > I expect you either forgot to update rancid.conf so that it reads: > > LIST_OF_GROUPS="networking" > > Or you already did rancid-cvs? > > Nicolai > ________________________________________ > Fra: rancid-discuss-bounces at shrubbery.net [ > rancid-discuss-bounces at shrubbery.net] på vegne av Andy Townsend [ > me at andytownsend.co.uk] > Sendt: 6. mars 2012 18:45 > Til: rancid-discuss at shrubbery.net > Emne: [rancid] Rancid CVS Issue > > Hi, > > I've just installed rancid on one of my boxes following the guide here. > > > http://www.linuxhomenetworking.com/wiki/index.php/Quick_HOWTO_:_Ch1_:_Network_Backups_With_Rancid > > However, when I run the rancid-cvs command, I get no output. > > [rancid at router ~]$ /usr/local/rancid/bin/rancid-cvs > [rancid at router ~]$ > > When as per the docs I should be getting this. > > > > > [rancid at bigboy ~]$ /usr/local/rancid/bin/rancid-cvs > No conflicts created by this import > cvs checkout: Updating networking > cvs checkout: Updating networking/configs > cvs add: scheduling file `router.db' for addition > cvs add: use 'cvs commit' to add this file permanently > RCS file: /usr/local/rancid//var/CVS/networking/router.db,v > done > Checking in router.db; > /usr/local/rancid//var/CVS/networking/router.db,v <-- router.db > initial revision: 1.1 > done > > > CVS is already installed so no issues there, > > [rancid at router ~]$ rpm -qa | grep cvs > cvs-1.11.22-7.el5 > > > Just wondering if anyone had come across this or know what the next steps > were? > > Cheers, > Andy > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Nicolai.Langfeldt at ventelo.no Wed Mar 7 09:16:35 2012 From: Nicolai.Langfeldt at ventelo.no (Nicolai Langfeldt) Date: Wed, 7 Mar 2012 10:16:35 +0100 Subject: [rancid] Rancid CVS Issue In-Reply-To: References: <9083709BCF00E0468332648EF6EC3BD8010471C7B8FF@P0OSLVEXMBX01.no.ventelo.local>, Message-ID: <9083709BCF00E0468332648EF6EC3BD8010471C7B906@P0OSLVEXMBX01.no.ventelo.local> Hei, I note that "echo $BASEDIR" is rather useless, but it's not meant to be useful in the rancid users shell. Also $BASEDIR should _not_ be quite identical to your rancid install prefix, IMHO at least it's rather messy. If you want it to be within your install prefix at least put it in a subdir such as /usr/local/rancid/backups or somesuch. Try this: - cd to the $BASEDIR as defined in rancid.conf (not quite sure if this is required, I just always do it) - rancid-cvs networking Nicolai ________________________________________ Fra: Andy Townsend [me at andytownsend.co.uk] Sendt: 7. mars 2012 10:07 Til: Nicolai Langfeldt Kopi: rancid-discuss at shrubbery.net Emne: Re: [rancid] Rancid CVS Issue I've already got this in rancid.conf # list of rancid groups LIST_OF_GROUPS="networking" And when I run /usr/local/rancid/bin/rancid-cvs I get no output. [rancid at router ~]$ /usr/local/rancid/bin/rancid-cvs [rancid at router ~]$ [rancid at router ~]$ echo $BASEDIR [rancid at router ~]$ pwd /usr/local/rancid [rancid at router ~]$ ls -l total 60 drwxr-xr-x 2 rancid netadm 4096 Mar 6 17:26 bin drwxr-xr-x 2 rancid netadm 4096 Mar 7 09:04 etc -rw-r--r-- 1 rancid netadm 12738 Mar 6 17:22 README drwxr-xr-x 4 rancid netadm 4096 Mar 6 17:13 share drwxr-xr-x 3 rancid netadm 4096 Oct 26 21:51 tar drwxr-xr-x 5 rancid netadm 4096 Mar 6 17:21 var I believe there should be a CVS directory in there. I did install CVS after rancid so I guess that may have caused the issue. Any ideas? Thanks, Andy On 6 March 2012 19:44, Nicolai Langfeldt > wrote: I expect you either forgot to update rancid.conf so that it reads: LIST_OF_GROUPS="networking" Or you already did rancid-cvs? Nicolai ________________________________________ Fra: rancid-discuss-bounces at shrubbery.net [rancid-discuss-bounces at shrubbery.net] på vegne av Andy Townsend [me at andytownsend.co.uk] Sendt: 6. mars 2012 18:45 Til: rancid-discuss at shrubbery.net Emne: [rancid] Rancid CVS Issue Hi, I've just installed rancid on one of my boxes following the guide here. http://www.linuxhomenetworking.com/wiki/index.php/Quick_HOWTO_:_Ch1_:_Network_Backups_With_Rancid However, when I run the rancid-cvs command, I get no output. [rancid at router ~]$ /usr/local/rancid/bin/rancid-cvs [rancid at router ~]$ When as per the docs I should be getting this. [rancid at bigboy ~]$ /usr/local/rancid/bin/rancid-cvs No conflicts created by this import cvs checkout: Updating networking cvs checkout: Updating networking/configs cvs add: scheduling file `router.db' for addition cvs add: use 'cvs commit' to add this file permanently RCS file: /usr/local/rancid//var/CVS/networking/router.db,v done Checking in router.db; /usr/local/rancid//var/CVS/networking/router.db,v <-- router.db initial revision: 1.1 done CVS is already installed so no issues there, [rancid at router ~]$ rpm -qa | grep cvs cvs-1.11.22-7.el5 Just wondering if anyone had come across this or know what the next steps were? Cheers, Andy From egirard at focustsi.com Wed Mar 7 18:48:25 2012 From: egirard at focustsi.com (Eric Girard) Date: Wed, 7 Mar 2012 13:48:25 -0500 Subject: [rancid] Rancid CVS Issue In-Reply-To: References: <9083709BCF00E0468332648EF6EC3BD8010471C7B8FF@P0OSLVEXMBX01.no.ventelo.local> Message-ID: Andy, not sure how many changes you've made to rancid.conf, but the CVS directory in my pretty stock install is in /usr/local/rancid/var/ along with all of my group directories, not in /usr/local/rancid/ From: rancid-discuss-bounces at shrubbery.net [mailto:rancid-discuss-bounces at shrubbery.net] On Behalf Of Andy Townsend Sent: Wednesday, March 07, 2012 4:07 AM To: Nicolai Langfeldt Cc: rancid-discuss at shrubbery.net Subject: Re: [rancid] Rancid CVS Issue I've already got this in rancid.conf # list of rancid groups LIST_OF_GROUPS="networking" And when I run /usr/local/rancid/bin/rancid-cvs I get no output. [rancid at router ~]$ /usr/local/rancid/bin/rancid-cvs [rancid at router ~]$ [rancid at router ~]$ echo $BASEDIR [rancid at router ~]$ pwd /usr/local/rancid [rancid at router ~]$ ls -l total 60 drwxr-xr-x 2 rancid netadm 4096 Mar 6 17:26 bin drwxr-xr-x 2 rancid netadm 4096 Mar 7 09:04 etc -rw-r--r-- 1 rancid netadm 12738 Mar 6 17:22 README drwxr-xr-x 4 rancid netadm 4096 Mar 6 17:13 share drwxr-xr-x 3 rancid netadm 4096 Oct 26 21:51 tar drwxr-xr-x 5 rancid netadm 4096 Mar 6 17:21 var I believe there should be a CVS directory in there. I did install CVS after rancid so I guess that may have caused the issue. Any ideas? Thanks, Andy On 6 March 2012 19:44, Nicolai Langfeldt > wrote: I expect you either forgot to update rancid.conf so that it reads: LIST_OF_GROUPS="networking" Or you already did rancid-cvs? Nicolai ________________________________________ Fra: rancid-discuss-bounces at shrubbery.net [rancid-discuss-bounces at shrubbery.net] på vegne av Andy Townsend [me at andytownsend.co.uk] Sendt: 6. mars 2012 18:45 Til: rancid-discuss at shrubbery.net Emne: [rancid] Rancid CVS Issue Hi, I've just installed rancid on one of my boxes following the guide here. http://www.linuxhomenetworking.com/wiki/index.php/Quick_HOWTO_:_Ch1_:_Network_Backups_With_Rancid However, when I run the rancid-cvs command, I get no output. [rancid at router ~]$ /usr/local/rancid/bin/rancid-cvs [rancid at router ~]$ When as per the docs I should be getting this. [rancid at bigboy ~]$ /usr/local/rancid/bin/rancid-cvs No conflicts created by this import cvs checkout: Updating networking cvs checkout: Updating networking/configs cvs add: scheduling file `router.db' for addition cvs add: use 'cvs commit' to add this file permanently RCS file: /usr/local/rancid//var/CVS/networking/router.db,v done Checking in router.db; /usr/local/rancid//var/CVS/networking/router.db,v <-- router.db initial revision: 1.1 done CVS is already installed so no issues there, [rancid at router ~]$ rpm -qa | grep cvs cvs-1.11.22-7.el5 Just wondering if anyone had come across this or know what the next steps were? Cheers, Andy -------------- next part -------------- An HTML attachment was scrubbed... URL: From me at andytownsend.co.uk Wed Mar 7 18:56:51 2012 From: me at andytownsend.co.uk (Andy Townsend) Date: Wed, 7 Mar 2012 18:56:51 +0000 Subject: [rancid] Rancid CVS Issue In-Reply-To: References: <9083709BCF00E0468332648EF6EC3BD8010471C7B8FF@P0OSLVEXMBX01.no.ventelo.local> Message-ID: I've made very few changes apart from those mentioned in the initial install guide. Was asked for the following from someone else but it could be handy to someone else as well. I've not changed the CVS directory but its set to the following as well. ++ CVSROOT=/usr/local/rancid/var/CVS ++ export CVSROOT [rancid at router ~]$ sh -x `which rancid-cvs` + ENVFILE=/usr/local/rancid/etc/rancid.conf + '[' 0 -ge 1 ']' + . /usr/local/rancid/etc/rancid.conf ++ TERM=network ++ export TERM ++ LC_COLLATE=POSIX ++ export LC_COLLATE ++ umask 027 ++ TMPDIR=/tmp ++ export TMPDIR ++ BASEDIR=/usr/local/rancid/var ++ export BASEDIR ++ PATH=/usr/local/rancid/bin:/usr/bin:.:/bin:/usr/local/bin:/usr/bin ++ export PATH ++ CVSROOT=/usr/local/rancid/var/CVS ++ export CVSROOT ++ LOGDIR=/usr/local/rancid/var/logs ++ export LOGDIR ++ RCSSYS=cvs ++ export RCSSYS ++ FILTER_PWDS=NO ++ export FILTER_PWDS ++ NOCOMMSTR=NO ++ export NOCOMMSTR ++ LIST_OF_GROUPS=networking ++ MAILDOMAIN=@testdomain.com ++ export MAILDOMAIN + '[' '!' -d /usr/local/rancid/var ']' + cd /usr/local/rancid/var + RCSSYS=cvs + '[' cvs '!=' cvs -a cvs '!=' svn ']' + '[' cvs = cvs ']' + '[' '!' -d /usr/local/rancid/var/CVS ']' + '[' '!' -d logs ']' + '[' 0 -ge 1 ']' + '[' networking = '' ']' ++ echo networking + for GROUP in '`echo $LIST_OF_GROUPS`' + DIR=/usr/local/rancid/var/networking + '[' '!' -d /usr/local/rancid/var/networking ']' + cd /usr/local/rancid/var/networking + '[' '!' -d configs ']' + '[' '!' -f routers.all ']' + '[' '!' -f routers.down ']' + '[' '!' -f routers.up ']' + '[' '!' -f router.db ']' On 7 March 2012 18:48, Eric Girard wrote: > Andy, not sure how many changes you?ve made to rancid.conf, but the CVS > directory in my pretty stock install is in /usr/local/rancid/var/ along > with all of my group directories, not in /usr/local/rancid/**** > > ** ** > > *From:* rancid-discuss-bounces at shrubbery.net [mailto: > rancid-discuss-bounces at shrubbery.net] *On Behalf Of *Andy Townsend > *Sent:* Wednesday, March 07, 2012 4:07 AM > *To:* Nicolai Langfeldt > *Cc:* rancid-discuss at shrubbery.net > *Subject:* Re: [rancid] Rancid CVS Issue**** > > ** ** > > I've already got this in rancid.conf**** > > ** ** > > # list of rancid groups**** > > LIST_OF_GROUPS="networking"**** > > ** ** > > And when I run /usr/local/rancid/bin/rancid-cvs I get no output. **** > > ** ** > > [rancid at router ~]$ /usr/local/rancid/bin/rancid-cvs**** > > [rancid at router ~]$**** > > ** ** > > [rancid at router ~]$ echo $BASEDIR**** > > ** ** > > [rancid at router ~]$ pwd**** > > /usr/local/rancid**** > > [rancid at router ~]$ ls -l**** > > total 60**** > > drwxr-xr-x 2 rancid netadm 4096 Mar 6 17:26 bin**** > > drwxr-xr-x 2 rancid netadm 4096 Mar 7 09:04 etc**** > > -rw-r--r-- 1 rancid netadm 12738 Mar 6 17:22 README**** > > drwxr-xr-x 4 rancid netadm 4096 Mar 6 17:13 share**** > > drwxr-xr-x 3 rancid netadm 4096 Oct 26 21:51 tar**** > > drwxr-xr-x 5 rancid netadm 4096 Mar 6 17:21 var**** > > ** ** > > I believe there should be a CVS directory in there. I did install CVS > after rancid so I guess that may have caused the issue. Any ideas?**** > > ** ** > > Thanks,**** > > Andy**** > > ** ** > > ** ** > > On 6 March 2012 19:44, Nicolai Langfeldt > wrote:**** > > I expect you either forgot to update rancid.conf so that it reads: > > LIST_OF_GROUPS="networking" > > Or you already did rancid-cvs? > > Nicolai > ________________________________________ > Fra: rancid-discuss-bounces at shrubbery.net [ > rancid-discuss-bounces at shrubbery.net] på vegne av Andy Townsend [ > me at andytownsend.co.uk] > Sendt: 6. mars 2012 18:45 > Til: rancid-discuss at shrubbery.net > Emne: [rancid] Rancid CVS Issue**** > > > Hi, > > I've just installed rancid on one of my boxes following the guide here. > > > http://www.linuxhomenetworking.com/wiki/index.php/Quick_HOWTO_:_Ch1_:_Network_Backups_With_Rancid > > However, when I run the rancid-cvs command, I get no output. > > [rancid at router ~]$ /usr/local/rancid/bin/rancid-cvs > [rancid at router ~]$ > > When as per the docs I should be getting this. > > > > > [rancid at bigboy ~]$ /usr/local/rancid/bin/rancid-cvs > No conflicts created by this import > cvs checkout: Updating networking > cvs checkout: Updating networking/configs > cvs add: scheduling file `router.db' for addition > cvs add: use 'cvs commit' to add this file permanently > RCS file: /usr/local/rancid//var/CVS/networking/router.db,v > done > Checking in router.db; > /usr/local/rancid//var/CVS/networking/router.db,v <-- router.db > initial revision: 1.1 > done > > > CVS is already installed so no issues there, > > [rancid at router ~]$ rpm -qa | grep cvs > cvs-1.11.22-7.el5 > > > Just wondering if anyone had come across this or know what the next steps > were? > > Cheers, > Andy**** > > ** ** > -------------- next part -------------- An HTML attachment was scrubbed... URL: From me at andytownsend.co.uk Thu Mar 8 15:30:47 2012 From: me at andytownsend.co.uk (Andy Townsend) Date: Thu, 8 Mar 2012 15:30:47 +0000 Subject: [rancid] Rancid - SSH and AD auth Message-ID: Firstly thanks to the guys who helped me previously. I've now got a copy of Rancid up and running. Currently we just use telnet and local pwd's for accessing the switches but I'm looking at changing this to SSH and AD/Radius authentication. Now from what I can see, SSH should be fine and I'm presuming the AD auth will be ok as well. As long as rancid has a domain account it can use, the username/pwd are specified in .cloginrc then it should be all ok? Just wondering if anyone has set it up like this in the past? I think it should be all ok, just wanted to double check and see if there were any major gotchas. Cheers, Andy -------------- next part -------------- An HTML attachment was scrubbed... URL: From me_gogorza at hotmail.com Thu Mar 8 16:08:06 2012 From: me_gogorza at hotmail.com (Marito ...) Date: Thu, 8 Mar 2012 13:08:06 -0300 Subject: [rancid] Rancid - SSH and AD auth In-Reply-To: References: Message-ID: Hi Andy, We have several devices, and most of them are authenticating using TACACS (with AD integration). As you said in your post, you have to put the user/pass of the account created in AD. You have to take into account (in case of using TACACS) the privilege given to the user, as it could be needed to enable, and also configured at .cloginrc. Regards. Mario From: me at andytownsend.co.uk Date: Thu, 8 Mar 2012 15:30:47 +0000 To: rancid-discuss at shrubbery.net Subject: [rancid] Rancid - SSH and AD auth Firstly thanks to the guys who helped me previously. I've now got a copy of Rancid up and running. Currently we just use telnet and local pwd's for accessing the switches but I'm looking at changing this to SSH and AD/Radius authentication. Now from what I can see, SSH should be fine and I'm presuming the AD auth will be ok as well. As long as rancid has a domain account it can use, the username/pwd are specified in .cloginrc then it should be all ok? Just wondering if anyone has set it up like this in the past? I think it should be all ok, just wanted to double check and see if there were any major gotchas. Cheers, Andy _______________________________________________ Rancid-discuss mailing list Rancid-discuss at shrubbery.net http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss -------------- next part -------------- An HTML attachment was scrubbed... URL: From michael at maymann.org Thu Mar 8 21:17:09 2012 From: michael at maymann.org (Michael Maymann) Date: Thu, 8 Mar 2012 22:17:09 +0100 Subject: [rancid] Cisco ASA+WLC script Message-ID: Hi List, I am trying to configure scheduled backups of my Cisco ASAs and WLCs. I am currently trying to use clogin. Login is successful, but it never enters enable/configure mode - and therefore is not able to run the desired commands/retrieve all the necessary information (it tries to though !). Can't paste my .clogin, as I'm at home currently. But everything (password/enable_password) is ok there ! (I am running this already on my HP Switches) just after login and before it should enter enable/configure mode, it tries to execute the command (from within clogin - not something I told it to...): "*terminal* length *0*" but the right command for this on a ASA/WLC's is: "no pager" or "terminal pager 0" 1. Is there a better Xlogin that I should use ? 2. If clogin is the best script, where in the clogin can I fix this ? 3. Furthermore clogin doesn't logout of my WLC's when it finishes - I guess I could just add a "; exit" or "; logout" at the end of my command, but where can I fix this as-well ? Thanks in advance :) ! ~maymann -------------- next part -------------- An HTML attachment was scrubbed... URL: From daniel.schmidt at wyo.gov Thu Mar 8 23:23:15 2012 From: daniel.schmidt at wyo.gov (Daniel Schmidt) Date: Thu, 8 Mar 2012 16:23:15 -0700 Subject: [rancid] Cisco ASA+WLC script In-Reply-To: References: Message-ID: Clogin is not for the wlc, that would be wlogin. Out of sheer curiosity, now, why again are you trying to find a way to do what rancid already does for you? *From:* rancid-discuss-bounces at shrubbery.net [mailto: rancid-discuss-bounces at shrubbery.net] *On Behalf Of *Michael Maymann *Sent:* Thursday, March 08, 2012 2:17 PM *To:* rancid-discuss at shrubbery.net *Subject:* [rancid] Cisco ASA+WLC script Hi List, I am trying to configure scheduled backups of my Cisco ASAs and WLCs. I am currently trying to use clogin. Login is successful, but it never enters enable/configure mode - and therefore is not able to run the desired commands/retrieve all the necessary information (it tries to though !). Can't paste my .clogin, as I'm at home currently. But everything (password/enable_password) is ok there ! (I am running this already on my HP Switches) just after login and before it should enter enable/configure mode, it tries to execute the command (from within clogin - not something I told it to...): "*terminal* length *0*" but the right command for this on a ASA/WLC's is: "no pager" or "terminal pager 0" 1. Is there a better Xlogin that I should use ? 2. If clogin is the best script, where in the clogin can I fix this ? 3. Furthermore clogin doesn't logout of my WLC's when it finishes - I guess I could just add a "; exit" or "; logout" at the end of my command, but where can I fix this as-well ? Thanks in advance :) ! ~maymann E-Mail to and from me, in connection with the transaction of public business, is subject to the Wyoming Public Records Act and may be disclosed to third parties. -------------- next part -------------- An HTML attachment was scrubbed... URL: From michael at maymann.org Fri Mar 9 11:23:24 2012 From: michael at maymann.org (Michael Maymann) Date: Fri, 9 Mar 2012 12:23:24 +0100 Subject: [rancid] Cisco ASA+WLC script In-Reply-To: References: Message-ID: Hi, Daniel+DenyIPAnyAny: Thanks for your quick reply :) ! 1. I'm running rancid 2.3.6... don't have any wlogin anywhere... can't see any in 2.3.8 either - how do I get wlogin ? I'm doing this because I have some equipment that rancid doesn't support, that I also need backed-up (and don't know expect that well). So just created a little wrapper around Rancid to perfect things for me. 2. How do you backup your ASA's ? nothing is wrong with my .clogin: --- add method * ssh #add method * telnet add user * USR add password * {PWD} {enable_PWD} add autoenable * {1} --- works fine, logging in and trying to run command(s) and exits - but doesn't enter enable mode and therefore can't run commands like "more system:running-config" that is working fine manually logging in to enable mode: -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "more system:running-config" HOST HOST spawn ssh -c 3des -x -l admin HOST USR at HOST's password: Type help or '?' for a list of available commands. HOST> HOST> terminal length 0 ^ ERROR: % Invalid input detected at '^' marker. HOST> more system:running-config ^ ERROR: % Invalid input detected at '^' marker. HOST>exit Logoff Connection to HOST closed. Thanks in advance :-) ! ~maymann 2012/3/9 Deny IP Any Any > I backup several Cisco ASAs without issue; with your symptoms, usually > the problem is with your .clogin file (specifically either the > autologin option) > > 2012/3/8 Michael Maymann : > > Hi List, > > > > I am trying to configure scheduled backups of my Cisco ASAs and WLCs. > > I am currently trying to use clogin. Login is successful, but it never > > enters enable/configure mode - and therefore is not able to run the > desired > > commands/retrieve all the necessary information (it tries to though !). > > Can't paste my .clogin, as I'm at home currently. But everything > > (password/enable_password) is ok there ! (I am running this already on > my HP > > Switches) > > > > just after login and before it should enter enable/configure mode, it > tries > > to execute the command (from within clogin - not something I told it > to...): > > "terminal length 0" > > but the right command for this on a ASA/WLC's is: > > "no pager" or "terminal pager 0" > > > > 1. Is there a better Xlogin that I should use ? > > 2. If clogin is the best script, where in the clogin can I fix this ? > > 3. Furthermore clogin doesn't logout of my WLC's when it finishes - I > guess > > I could just add a "; exit" or "; logout" at the end of my command, but > > where can I fix this as-well ? > > > > > > Thanks in advance :) ! > > ~maymann > > > > _______________________________________________ > > Rancid-discuss mailing list > > Rancid-discuss at shrubbery.net > > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss > > > > -- > deny ip any any (4393649193 matches) > -------------- next part -------------- An HTML attachment was scrubbed... URL: From paolo at paolodemichele.it Fri Mar 9 11:18:56 2012 From: paolo at paolodemichele.it (Paolo De Michele) Date: Fri, 09 Mar 2012 12:18:56 +0100 Subject: [rancid] - problem sending mail and matching configuration Message-ID: <4F59E720.4020404@paolodemichele.it> Hi all, using rancid 2.3.8 with os ubuntu 11.04 server. I did the various configurations and are quite happy with it. My problem is that when software rancid makes a matching configuration creates a new file. What I would do is this: - create a file when the new configuration is detected ( OK ) - send me an email with the changes detected in the new configuration I failed in any way using /etc/aliases and sendmail to send a mail to an address of a royal domain. can you help me somehow? thanks in advance -------------- next part -------------- An HTML attachment was scrubbed... URL: From me_gogorza at hotmail.com Fri Mar 9 11:50:43 2012 From: me_gogorza at hotmail.com (Marito ...) Date: Fri, 9 Mar 2012 08:50:43 -0300 Subject: [rancid] Cisco ASA+WLC script In-Reply-To: References: , , Message-ID: Hi Michael, You should set up autoenable to 0. As per Rancid .clogin help: ".B add autoenable {[01]} When using locally defined usernames or AAA, it is possible to have a login which is automatically enabled. This is, that user has enable privileges without the need to execute the enable command. The router's prompt is different for enabled mode, ending with a # rather than a >. Example: add autoenable * {1} Default: 0 zero, meaning that the user is not automatically enabled and should execute the enable command to gain enable privileges, unless negated by the noenable directive or \-noenable command\-line option. " Regards. From: michael at maymann.org Date: Fri, 9 Mar 2012 12:23:24 +0100 To: rancid-discuss at shrubbery.net Subject: Re: [rancid] Cisco ASA+WLC script Hi, Daniel+DenyIPAnyAny: Thanks for your quick reply :) ! 1. I'm running rancid 2.3.6... don't have any wlogin anywhere... can't see any in 2.3.8 either - how do I get wlogin ? I'm doing this because I have some equipment that rancid doesn't support, that I also need backed-up (and don't know expect that well). So just created a little wrapper around Rancid to perfect things for me. 2. How do you backup your ASA's ? nothing is wrong with my .clogin: --- add method * ssh #add method * telnet add user * USR add password * {PWD} {enable_PWD} add autoenable * {1} --- works fine, logging in and trying to run command(s) and exits - but doesn't enter enable mode and therefore can't run commands like "more system:running-config" that is working fine manually logging in to enable mode: -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "more system:running-config" HOST HOST spawn ssh -c 3des -x -l admin HOST USR at HOST's password: Type help or '?' for a list of available commands. HOST> HOST> terminal length 0 ^ ERROR: % Invalid input detected at '^' marker. HOST> more system:running-config ^ ERROR: % Invalid input detected at '^' marker. HOST>exit Logoff Connection to HOST closed. Thanks in advance :-) ! ~maymann 2012/3/9 Deny IP Any Any I backup several Cisco ASAs without issue; with your symptoms, usually the problem is with your .clogin file (specifically either the autologin option) 2012/3/8 Michael Maymann : > Hi List, > > I am trying to configure scheduled backups of my Cisco ASAs and WLCs. > I am currently trying to use clogin. Login is successful, but it never > enters enable/configure mode - and therefore is not able to run the desired > commands/retrieve all the necessary information (it tries to though !). > Can't paste my .clogin, as I'm at home currently. But everything > (password/enable_password) is ok there ! (I am running this already on my HP > Switches) > > just after login and before it should enter enable/configure mode, it tries > to execute the command (from within clogin - not something I told it to...): > "terminal length 0" > but the right command for this on a ASA/WLC's is: > "no pager" or "terminal pager 0" > > 1. Is there a better Xlogin that I should use ? > 2. If clogin is the best script, where in the clogin can I fix this ? > 3. Furthermore clogin doesn't logout of my WLC's when it finishes - I guess > I could just add a "; exit" or "; logout" at the end of my command, but > where can I fix this as-well ? > > > Thanks in advance :) ! > ~maymann > > _______________________________________________ > Rancid-discuss mailing list > Rancid-discuss at shrubbery.net > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss -- deny ip any any (4393649193 matches) _______________________________________________ Rancid-discuss mailing list Rancid-discuss at shrubbery.net http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss -------------- next part -------------- An HTML attachment was scrubbed... URL: From michael at maymann.org Fri Mar 9 12:18:14 2012 From: michael at maymann.org (Michael Maymann) Date: Fri, 9 Mar 2012 13:18:14 +0100 Subject: [rancid] Cisco ASA+WLC script In-Reply-To: References: Message-ID: Hi, Marito: thanks, that did it for the ASA's :) ! now I have the following on my WLC's: --- -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "sh ver" HOST HOST spawn ssh -c 3des -x -l USR HOST (Cisco Controller) User: USR Password:************ (Cisco Controller) >enable Incorrect usage. Use the '?' or key to list commands. (Cisco Controller) > Error: Check your Enable passwd --- These are the non-enable-commands that I can run on the WLC: --- (Cisco Controller) >? clear Clear selected configuration elements. config Configure switch options and settings. debug Manages system debug options. help Help license Manage Software License linktest Perform a link test to a specified MAC address. logout Exit this session. Any unsaved changes are lost. ping Send ICMP echo packets to a specified IP address. mping Send Mobility echo packets to a specified mobility peer IP address. eping Send Ethernet-over-IP echo packets to a specified mobility peer IP address. reset Reset options. save Save switch configurations. show Display switch options and settings. test Test trigger commands transfer Transfer a file to or from the switch. --- How can I get this to work as it seems that "enable" command is called "config" ? Should I create a new .cloginrc_wlc for this and what would it look like ? Thanks in advance :) ! ~maymann 2012/3/9 Marito ... > Hi Michael, > > You should set up autoenable to 0. As per Rancid .clogin help: > > ".B add autoenable {[01]} > When using locally defined usernames or AAA, it is possible to have a > login which is automatically enabled. This is, that user has enable > privileges without the need to execute the enable command. The router's > prompt is different for enabled mode, ending with a # rather than a >. > > Example: add autoenable * {1} > > Default: 0 > > zero, meaning that the user is not automatically enabled and should > execute the enable command to gain enable privileges, unless negated by the > noenable directive or \-noenable command\-line option. > " > > Regards. > > > ------------------------------ > From: michael at maymann.org > Date: Fri, 9 Mar 2012 12:23:24 +0100 > To: rancid-discuss at shrubbery.net > Subject: Re: [rancid] Cisco ASA+WLC script > > > Hi, > > Daniel+DenyIPAnyAny: Thanks for your quick reply :) ! > > 1. I'm running rancid 2.3.6... don't have any wlogin anywhere... can't see > any in 2.3.8 either - how do I get wlogin ? > I'm doing this because I have some equipment that rancid doesn't support, > that I also need backed-up (and don't know expect that well). So just > created a little wrapper around Rancid to perfect things for me. > > 2. How do you backup your ASA's ? > nothing is wrong with my .clogin: > --- > add method * ssh > #add method * telnet > add user * USR > add password * {PWD} {enable_PWD} > add autoenable * {1} > --- > works fine, logging in and trying to run command(s) and exits - but > doesn't enter enable mode and therefore can't run commands like "more > system:running-config" that is working fine manually logging in to enable > mode: > -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "more > system:running-config" HOST > HOST > spawn ssh -c 3des -x -l admin HOST > USR at HOST's password: > Type help or '?' for a list of available commands. > HOST> > HOST> terminal length 0 > ^ > ERROR: % Invalid input detected at '^' marker. > HOST> more system:running-config > ^ > ERROR: % Invalid input detected at '^' marker. > HOST>exit > > Logoff > > Connection to HOST closed. > > > Thanks in advance :-) ! > > ~maymann > > 2012/3/9 Deny IP Any Any > > I backup several Cisco ASAs without issue; with your symptoms, usually > the problem is with your .clogin file (specifically either the > autologin option) > > 2012/3/8 Michael Maymann : > > Hi List, > > > > I am trying to configure scheduled backups of my Cisco ASAs and WLCs. > > I am currently trying to use clogin. Login is successful, but it never > > enters enable/configure mode - and therefore is not able to run the > desired > > commands/retrieve all the necessary information (it tries to though !). > > Can't paste my .clogin, as I'm at home currently. But everything > > (password/enable_password) is ok there ! (I am running this already on > my HP > > Switches) > > > > just after login and before it should enter enable/configure mode, it > tries > > to execute the command (from within clogin - not something I told it > to...): > > "terminal length 0" > > but the right command for this on a ASA/WLC's is: > > "no pager" or "terminal pager 0" > > > > 1. Is there a better Xlogin that I should use ? > > 2. If clogin is the best script, where in the clogin can I fix this ? > > 3. Furthermore clogin doesn't logout of my WLC's when it finishes - I > guess > > I could just add a "; exit" or "; logout" at the end of my command, but > > where can I fix this as-well ? > > > > > > Thanks in advance :) ! > > ~maymann > > > > _______________________________________________ > > Rancid-discuss mailing list > > Rancid-discuss at shrubbery.net > > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss > > > > -- > deny ip any any (4393649193 matches) > > > > _______________________________________________ Rancid-discuss mailing > list Rancid-discuss at shrubbery.net > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss > -------------- next part -------------- An HTML attachment was scrubbed... URL: From rwest at zyedge.com Fri Mar 9 12:45:08 2012 From: rwest at zyedge.com (Ryan West) Date: Fri, 9 Mar 2012 12:45:08 +0000 Subject: [rancid] Cisco ASA+WLC script In-Reply-To: References: , Message-ID: <24E0598B-4E9E-4809-9267-0070143A72FB@zyedge.com> Do a search in the archive and you'll find the wlc script. What version are you running? Sent from handheld On Mar 9, 2012, at 7:19 AM, "Michael Maymann" > wrote: Hi, Marito: thanks, that did it for the ASA's :) ! now I have the following on my WLC's: --- -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "sh ver" HOST HOST spawn ssh -c 3des -x -l USR HOST (Cisco Controller) User: USR Password:************ (Cisco Controller) >enable Incorrect usage. Use the '?' or key to list commands. (Cisco Controller) > Error: Check your Enable passwd --- These are the non-enable-commands that I can run on the WLC: --- (Cisco Controller) >? clear Clear selected configuration elements. config Configure switch options and settings. debug Manages system debug options. help Help license Manage Software License linktest Perform a link test to a specified MAC address. logout Exit this session. Any unsaved changes are lost. ping Send ICMP echo packets to a specified IP address. mping Send Mobility echo packets to a specified mobility peer IP address. eping Send Ethernet-over-IP echo packets to a specified mobility peer IP address. reset Reset options. save Save switch configurations. show Display switch options and settings. test Test trigger commands transfer Transfer a file to or from the switch. --- How can I get this to work as it seems that "enable" command is called "config" ? Should I create a new .cloginrc_wlc for this and what would it look like ? Thanks in advance :) ! ~maymann 2012/3/9 Marito ... > Hi Michael, You should set up autoenable to 0. As per Rancid .clogin help: ".B add autoenable {[01]} When using locally defined usernames or AAA, it is possible to have a login which is automatically enabled. This is, that user has enable privileges without the need to execute the enable command. The router's prompt is different for enabled mode, ending with a # rather than a >. Example: add autoenable * {1} Default: 0 zero, meaning that the user is not automatically enabled and should execute the enable command to gain enable privileges, unless negated by the noenable directive or \-noenable command\-line option. " Regards. ________________________________ From: michael at maymann.org Date: Fri, 9 Mar 2012 12:23:24 +0100 To: rancid-discuss at shrubbery.net Subject: Re: [rancid] Cisco ASA+WLC script Hi, Daniel+DenyIPAnyAny: Thanks for your quick reply :) ! 1. I'm running rancid 2.3.6... don't have any wlogin anywhere... can't see any in 2.3.8 either - how do I get wlogin ? I'm doing this because I have some equipment that rancid doesn't support, that I also need backed-up (and don't know expect that well). So just created a little wrapper around Rancid to perfect things for me. 2. How do you backup your ASA's ? nothing is wrong with my .clogin: --- add method * ssh #add method * telnet add user * USR add password * {PWD} {enable_PWD} add autoenable * {1} --- works fine, logging in and trying to run command(s) and exits - but doesn't enter enable mode and therefore can't run commands like "more system:running-config" that is working fine manually logging in to enable mode: -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "more system:running-config" HOST HOST spawn ssh -c 3des -x -l admin HOST USR at HOST's password: Type help or '?' for a list of available commands. HOST> HOST> terminal length 0 ^ ERROR: % Invalid input detected at '^' marker. HOST> more system:running-config ^ ERROR: % Invalid input detected at '^' marker. HOST>exit Logoff Connection to HOST closed. Thanks in advance :-) ! ~maymann 2012/3/9 Deny IP Any Any > I backup several Cisco ASAs without issue; with your symptoms, usually the problem is with your .clogin file (specifically either the autologin option) 2012/3/8 Michael Maymann >: > Hi List, > > I am trying to configure scheduled backups of my Cisco ASAs and WLCs. > I am currently trying to use clogin. Login is successful, but it never > enters enable/configure mode - and therefore is not able to run the desired > commands/retrieve all the necessary information (it tries to though !). > Can't paste my .clogin, as I'm at home currently. But everything > (password/enable_password) is ok there ! (I am running this already on my HP > Switches) > > just after login and before it should enter enable/configure mode, it tries > to execute the command (from within clogin - not something I told it to...): > "terminal length 0" > but the right command for this on a ASA/WLC's is: > "no pager" or "terminal pager 0" > > 1. Is there a better Xlogin that I should use ? > 2. If clogin is the best script, where in the clogin can I fix this ? > 3. Furthermore clogin doesn't logout of my WLC's when it finishes - I guess > I could just add a "; exit" or "; logout" at the end of my command, but > where can I fix this as-well ? > > > Thanks in advance :) ! > ~maymann > > _______________________________________________ > Rancid-discuss mailing list > Rancid-discuss at shrubbery.net > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss -- deny ip any any (4393649193 matches) _______________________________________________ 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: From bha.Qaqish at NITC.gov.jo Fri Mar 9 13:12:10 2012 From: bha.Qaqish at NITC.gov.jo (bha Qaqish) Date: Fri, 9 Mar 2012 15:12:10 +0200 Subject: [rancid] password Message-ID: Dear i using rancid for 2 month and i check the config from the GUI , and i found line vty 0 4 password how can i appear the password . i do not want to hide it BR BHA QAQISH From michael at maymann.org Fri Mar 9 13:20:23 2012 From: michael at maymann.org (Michael Maymann) Date: Fri, 9 Mar 2012 14:20:23 +0100 Subject: [rancid] Cisco ASA+WLC script In-Reply-To: <24E0598B-4E9E-4809-9267-0070143A72FB@zyedge.com> References: <24E0598B-4E9E-4809-9267-0070143A72FB@zyedge.com> Message-ID: Hi, Ryan: thanks for your reply. I'm running... Rancid: 2.3.6 WLC: 6.0.202.0 found a wlogin here: http://www.gossamer-threads.com/lists/rancid/users/4674 but I can't get it to work: -bash-3.2$ /usr/libexec/rancid/wlogin -f ~/.cloginrc_cisco -c "sh cpu" HOST ": no such file or directory -bash-3.2$ /usr/libexec/rancid/wlogin -c "sh cpu" HOST ": no such file or directory Is this the one you are talking about - or is there a newer one somewhere ? Thanks in advance :-) ! ~maymann 2012/3/9 Ryan West > Do a search in the archive and you'll find the wlc script. What version > are you running? > > Sent from handheld > > On Mar 9, 2012, at 7:19 AM, "Michael Maymann" wrote: > > Hi, > > Marito: thanks, that did it for the ASA's :) ! > now I have the following on my WLC's: > --- > -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "sh ver" HOST > HOST > spawn ssh -c 3des -x -l USR HOST > > > (Cisco Controller) > User: USR > Password:************ > (Cisco Controller) >enable > > Incorrect usage. Use the '?' or key to list commands. > > (Cisco Controller) > > Error: Check your Enable passwd > --- > > These are the non-enable-commands that I can run on the WLC: > --- > (Cisco Controller) >? > > clear Clear selected configuration elements. > config Configure switch options and settings. > debug Manages system debug options. > help Help > license Manage Software License > linktest Perform a link test to a specified MAC address. > logout Exit this session. Any unsaved changes are lost. > ping Send ICMP echo packets to a specified IP address. > mping Send Mobility echo packets to a specified mobility peer IP > address. > eping Send Ethernet-over-IP echo packets to a specified mobility > peer IP address. > reset Reset options. > save Save switch configurations. > show Display switch options and settings. > test Test trigger commands > transfer Transfer a file to or from the switch. > --- > > How can I get this to work as it seems that "enable" command is called > "config" ? > Should I create a new .cloginrc_wlc for this and what would it look like ? > > > Thanks in advance :) ! > ~maymann > > > 2012/3/9 Marito ... > >> Hi Michael, >> >> You should set up autoenable to 0. As per Rancid .clogin help: >> >> ".B add autoenable {[01]} >> When using locally defined usernames or AAA, it is possible to have a >> login which is automatically enabled. This is, that user has enable >> privileges without the need to execute the enable command. The router's >> prompt is different for enabled mode, ending with a # rather than a >. >> >> Example: add autoenable * {1} >> >> Default: 0 >> >> zero, meaning that the user is not automatically enabled and should >> execute the enable command to gain enable privileges, unless negated by the >> noenable directive or \-noenable command\-line option. >> " >> >> Regards. >> >> >> ------------------------------ >> From: michael at maymann.org >> Date: Fri, 9 Mar 2012 12:23:24 +0100 >> To: rancid-discuss at shrubbery.net >> Subject: Re: [rancid] Cisco ASA+WLC script >> >> >> Hi, >> >> Daniel+DenyIPAnyAny: Thanks for your quick reply :) ! >> >> 1. I'm running rancid 2.3.6... don't have any wlogin anywhere... can't >> see any in 2.3.8 either - how do I get wlogin ? >> I'm doing this because I have some equipment that rancid doesn't support, >> that I also need backed-up (and don't know expect that well). So just >> created a little wrapper around Rancid to perfect things for me. >> >> 2. How do you backup your ASA's ? >> nothing is wrong with my .clogin: >> --- >> add method * ssh >> #add method * telnet >> add user * USR >> add password * {PWD} {enable_PWD} >> add autoenable * {1} >> --- >> works fine, logging in and trying to run command(s) and exits - but >> doesn't enter enable mode and therefore can't run commands like "more >> system:running-config" that is working fine manually logging in to enable >> mode: >> -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "more >> system:running-config" HOST >> HOST >> spawn ssh -c 3des -x -l admin HOST >> USR at HOST's password: >> Type help or '?' for a list of available commands. >> HOST> >> HOST> terminal length 0 >> ^ >> ERROR: % Invalid input detected at '^' marker. >> HOST> more system:running-config >> ^ >> ERROR: % Invalid input detected at '^' marker. >> HOST>exit >> >> Logoff >> >> Connection to HOST closed. >> >> >> Thanks in advance :-) ! >> >> ~maymann >> >> 2012/3/9 Deny IP Any Any >> >> I backup several Cisco ASAs without issue; with your symptoms, usually >> the problem is with your .clogin file (specifically either the >> autologin option) >> >> 2012/3/8 Michael Maymann : >> > Hi List, >> > >> > I am trying to configure scheduled backups of my Cisco ASAs and WLCs. >> > I am currently trying to use clogin. Login is successful, but it never >> > enters enable/configure mode - and therefore is not able to run the >> desired >> > commands/retrieve all the necessary information (it tries to though !). >> > Can't paste my .clogin, as I'm at home currently. But everything >> > (password/enable_password) is ok there ! (I am running this already on >> my HP >> > Switches) >> > >> > just after login and before it should enter enable/configure mode, it >> tries >> > to execute the command (from within clogin - not something I told it >> to...): >> > "terminal length 0" >> > but the right command for this on a ASA/WLC's is: >> > "no pager" or "terminal pager 0" >> > >> > 1. Is there a better Xlogin that I should use ? >> > 2. If clogin is the best script, where in the clogin can I fix this ? >> > 3. Furthermore clogin doesn't logout of my WLC's when it finishes - I >> guess >> > I could just add a "; exit" or "; logout" at the end of my command, but >> > where can I fix this as-well ? >> > >> > >> > Thanks in advance :) ! >> > ~maymann >> > >> > _______________________________________________ >> > Rancid-discuss mailing list >> > Rancid-discuss at shrubbery.net >> > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss >> >> >> >> -- >> deny ip any any (4393649193 matches) >> >> >> >> _______________________________________________ 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 > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From rwest at zyedge.com Fri Mar 9 13:29:35 2012 From: rwest at zyedge.com (Ryan West) Date: Fri, 9 Mar 2012 13:29:35 +0000 Subject: [rancid] Cisco ASA+WLC script In-Reply-To: References: <24E0598B-4E9E-4809-9267-0070143A72FB@zyedge.com>, Message-ID: Yes, that's it. I assume you set up rancid-fe and tried rancid-run -r devicename as well? Sent from handheld On Mar 9, 2012, at 8:20 AM, "Michael Maymann" > wrote: Hi, Ryan: thanks for your reply. I'm running... Rancid: 2.3.6 WLC: 6.0.202.0 found a wlogin here: http://www.gossamer-threads.com/lists/rancid/users/4674 but I can't get it to work: -bash-3.2$ /usr/libexec/rancid/wlogin -f ~/.cloginrc_cisco -c "sh cpu" HOST ": no such file or directory -bash-3.2$ /usr/libexec/rancid/wlogin -c "sh cpu" HOST ": no such file or directory Is this the one you are talking about - or is there a newer one somewhere ? Thanks in advance :-) ! ~maymann 2012/3/9 Ryan West > Do a search in the archive and you'll find the wlc script. What version are you running? Sent from handheld On Mar 9, 2012, at 7:19 AM, "Michael Maymann" > wrote: Hi, Marito: thanks, that did it for the ASA's :) ! now I have the following on my WLC's: --- -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "sh ver" HOST HOST spawn ssh -c 3des -x -l USR HOST (Cisco Controller) User: USR Password:************ (Cisco Controller) >enable Incorrect usage. Use the '?' or key to list commands. (Cisco Controller) > Error: Check your Enable passwd --- These are the non-enable-commands that I can run on the WLC: --- (Cisco Controller) >? clear Clear selected configuration elements. config Configure switch options and settings. debug Manages system debug options. help Help license Manage Software License linktest Perform a link test to a specified MAC address. logout Exit this session. Any unsaved changes are lost. ping Send ICMP echo packets to a specified IP address. mping Send Mobility echo packets to a specified mobility peer IP address. eping Send Ethernet-over-IP echo packets to a specified mobility peer IP address. reset Reset options. save Save switch configurations. show Display switch options and settings. test Test trigger commands transfer Transfer a file to or from the switch. --- How can I get this to work as it seems that "enable" command is called "config" ? Should I create a new .cloginrc_wlc for this and what would it look like ? Thanks in advance :) ! ~maymann 2012/3/9 Marito ... > Hi Michael, You should set up autoenable to 0. As per Rancid .clogin help: ".B add autoenable {[01]} When using locally defined usernames or AAA, it is possible to have a login which is automatically enabled. This is, that user has enable privileges without the need to execute the enable command. The router's prompt is different for enabled mode, ending with a # rather than a >. Example: add autoenable * {1} Default: 0 zero, meaning that the user is not automatically enabled and should execute the enable command to gain enable privileges, unless negated by the noenable directive or \-noenable command\-line option. " Regards. ________________________________ From: michael at maymann.org Date: Fri, 9 Mar 2012 12:23:24 +0100 To: rancid-discuss at shrubbery.net Subject: Re: [rancid] Cisco ASA+WLC script Hi, Daniel+DenyIPAnyAny: Thanks for your quick reply :) ! 1. I'm running rancid 2.3.6... don't have any wlogin anywhere... can't see any in 2.3.8 either - how do I get wlogin ? I'm doing this because I have some equipment that rancid doesn't support, that I also need backed-up (and don't know expect that well). So just created a little wrapper around Rancid to perfect things for me. 2. How do you backup your ASA's ? nothing is wrong with my .clogin: --- add method * ssh #add method * telnet add user * USR add password * {PWD} {enable_PWD} add autoenable * {1} --- works fine, logging in and trying to run command(s) and exits - but doesn't enter enable mode and therefore can't run commands like "more system:running-config" that is working fine manually logging in to enable mode: -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "more system:running-config" HOST HOST spawn ssh -c 3des -x -l admin HOST USR at HOST's password: Type help or '?' for a list of available commands. HOST> HOST> terminal length 0 ^ ERROR: % Invalid input detected at '^' marker. HOST> more system:running-config ^ ERROR: % Invalid input detected at '^' marker. HOST>exit Logoff Connection to HOST closed. Thanks in advance :-) ! ~maymann 2012/3/9 Deny IP Any Any > I backup several Cisco ASAs without issue; with your symptoms, usually the problem is with your .clogin file (specifically either the autologin option) 2012/3/8 Michael Maymann >: > Hi List, > > I am trying to configure scheduled backups of my Cisco ASAs and WLCs. > I am currently trying to use clogin. Login is successful, but it never > enters enable/configure mode - and therefore is not able to run the desired > commands/retrieve all the necessary information (it tries to though !). > Can't paste my .clogin, as I'm at home currently. But everything > (password/enable_password) is ok there ! (I am running this already on my HP > Switches) > > just after login and before it should enter enable/configure mode, it tries > to execute the command (from within clogin - not something I told it to...): > "terminal length 0" > but the right command for this on a ASA/WLC's is: > "no pager" or "terminal pager 0" > > 1. Is there a better Xlogin that I should use ? > 2. If clogin is the best script, where in the clogin can I fix this ? > 3. Furthermore clogin doesn't logout of my WLC's when it finishes - I guess > I could just add a "; exit" or "; logout" at the end of my command, but > where can I fix this as-well ? > > > Thanks in advance :) ! > ~maymann > > _______________________________________________ > Rancid-discuss mailing list > Rancid-discuss at shrubbery.net > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss -- deny ip any any (4393649193 matches) _______________________________________________ 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: From michael at maymann.org Fri Mar 9 13:38:02 2012 From: michael at maymann.org (Michael Maymann) Date: Fri, 9 Mar 2012 14:38:02 +0100 Subject: [rancid] Cisco ASA+WLC script In-Reply-To: References: <24E0598B-4E9E-4809-9267-0070143A72FB@zyedge.com> Message-ID: Hi, Ryan: ok. No, I didn't - do I have to :) ?. Shouldn't I just be able to: /usr/libexec/rancid/wlogin -f ~/.cloginrc_cisco -c "sh cpu" HOST ? Thanks in advance :-)! ~maymann 2012/3/9 Ryan West > Yes, that's it. I assume you set up rancid-fe and tried rancid-run -r > devicename as well? > > Sent from handheld > > On Mar 9, 2012, at 8:20 AM, "Michael Maymann" wrote: > > Hi, > > Ryan: thanks for your reply. > I'm running... > Rancid: 2.3.6 > WLC: 6.0.202.0 > > found a wlogin here: > http://www.gossamer-threads.com/lists/rancid/users/4674 > > but I can't get it to work: > -bash-3.2$ /usr/libexec/rancid/wlogin -f ~/.cloginrc_cisco -c "sh cpu" HOST > ": no such file or directory > -bash-3.2$ /usr/libexec/rancid/wlogin -c "sh cpu" HOST > ": no such file or directory > > Is this the one you are talking about - or is there a newer one somewhere ? > > > Thanks in advance :-) ! > ~maymann > > > 2012/3/9 Ryan West > >> Do a search in the archive and you'll find the wlc script. What >> version are you running? >> >> Sent from handheld >> >> On Mar 9, 2012, at 7:19 AM, "Michael Maymann" >> wrote: >> >> Hi, >> >> Marito: thanks, that did it for the ASA's :) ! >> now I have the following on my WLC's: >> --- >> -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "sh ver" >> HOST >> HOST >> spawn ssh -c 3des -x -l USR HOST >> >> >> (Cisco Controller) >> User: USR >> Password:************ >> (Cisco Controller) >enable >> >> Incorrect usage. Use the '?' or key to list commands. >> >> (Cisco Controller) > >> Error: Check your Enable passwd >> --- >> >> These are the non-enable-commands that I can run on the WLC: >> --- >> (Cisco Controller) >? >> >> clear Clear selected configuration elements. >> config Configure switch options and settings. >> debug Manages system debug options. >> help Help >> license Manage Software License >> linktest Perform a link test to a specified MAC address. >> logout Exit this session. Any unsaved changes are lost. >> ping Send ICMP echo packets to a specified IP address. >> mping Send Mobility echo packets to a specified mobility peer IP >> address. >> eping Send Ethernet-over-IP echo packets to a specified mobility >> peer IP address. >> reset Reset options. >> save Save switch configurations. >> show Display switch options and settings. >> test Test trigger commands >> transfer Transfer a file to or from the switch. >> --- >> >> How can I get this to work as it seems that "enable" command is called >> "config" ? >> Should I create a new .cloginrc_wlc for this and what would it look like ? >> >> >> Thanks in advance :) ! >> ~maymann >> >> >> 2012/3/9 Marito ... >> >>> Hi Michael, >>> >>> You should set up autoenable to 0. As per Rancid .clogin help: >>> >>> ".B add autoenable {[01]} >>> When using locally defined usernames or AAA, it is possible to have a >>> login which is automatically enabled. This is, that user has enable >>> privileges without the need to execute the enable command. The router's >>> prompt is different for enabled mode, ending with a # rather than a >. >>> >>> Example: add autoenable * {1} >>> >>> Default: 0 >>> >>> zero, meaning that the user is not automatically enabled and should >>> execute the enable command to gain enable privileges, unless negated by the >>> noenable directive or \-noenable command\-line option. >>> " >>> >>> Regards. >>> >>> >>> ------------------------------ >>> From: michael at maymann.org >>> Date: Fri, 9 Mar 2012 12:23:24 +0100 >>> To: rancid-discuss at shrubbery.net >>> Subject: Re: [rancid] Cisco ASA+WLC script >>> >>> >>> Hi, >>> >>> Daniel+DenyIPAnyAny: Thanks for your quick reply :) ! >>> >>> 1. I'm running rancid 2.3.6... don't have any wlogin anywhere... can't >>> see any in 2.3.8 either - how do I get wlogin ? >>> I'm doing this because I have some equipment that rancid doesn't >>> support, that I also need backed-up (and don't know expect that well). So >>> just created a little wrapper around Rancid to perfect things for me. >>> >>> 2. How do you backup your ASA's ? >>> nothing is wrong with my .clogin: >>> --- >>> add method * ssh >>> #add method * telnet >>> add user * USR >>> add password * {PWD} {enable_PWD} >>> add autoenable * {1} >>> --- >>> works fine, logging in and trying to run command(s) and exits - but >>> doesn't enter enable mode and therefore can't run commands like "more >>> system:running-config" that is working fine manually logging in to enable >>> mode: >>> -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "more >>> system:running-config" HOST >>> HOST >>> spawn ssh -c 3des -x -l admin HOST >>> USR at HOST's password: >>> Type help or '?' for a list of available commands. >>> HOST> >>> HOST> terminal length 0 >>> ^ >>> ERROR: % Invalid input detected at '^' marker. >>> HOST> more system:running-config >>> ^ >>> ERROR: % Invalid input detected at '^' marker. >>> HOST>exit >>> >>> Logoff >>> >>> Connection to HOST closed. >>> >>> >>> Thanks in advance :-) ! >>> >>> ~maymann >>> >>> 2012/3/9 Deny IP Any Any >>> >>> I backup several Cisco ASAs without issue; with your symptoms, usually >>> the problem is with your .clogin file (specifically either the >>> autologin option) >>> >>> 2012/3/8 Michael Maymann : >>> > Hi List, >>> > >>> > I am trying to configure scheduled backups of my Cisco ASAs and WLCs. >>> > I am currently trying to use clogin. Login is successful, but it never >>> > enters enable/configure mode - and therefore is not able to run the >>> desired >>> > commands/retrieve all the necessary information (it tries to though !). >>> > Can't paste my .clogin, as I'm at home currently. But everything >>> > (password/enable_password) is ok there ! (I am running this already on >>> my HP >>> > Switches) >>> > >>> > just after login and before it should enter enable/configure mode, it >>> tries >>> > to execute the command (from within clogin - not something I told it >>> to...): >>> > "terminal length 0" >>> > but the right command for this on a ASA/WLC's is: >>> > "no pager" or "terminal pager 0" >>> > >>> > 1. Is there a better Xlogin that I should use ? >>> > 2. If clogin is the best script, where in the clogin can I fix this ? >>> > 3. Furthermore clogin doesn't logout of my WLC's when it finishes - I >>> guess >>> > I could just add a "; exit" or "; logout" at the end of my command, but >>> > where can I fix this as-well ? >>> > >>> > >>> > Thanks in advance :) ! >>> > ~maymann >>> > >>> > _______________________________________________ >>> > Rancid-discuss mailing list >>> > Rancid-discuss at shrubbery.net >>> > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss >>> >>> >>> >>> -- >>> deny ip any any (4393649193 matches) >>> >>> >>> >>> _______________________________________________ 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 >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From me_gogorza at hotmail.com Fri Mar 9 13:40:35 2012 From: me_gogorza at hotmail.com (Marito ...) Date: Fri, 9 Mar 2012 10:40:35 -0300 Subject: [rancid] password In-Reply-To: References: Message-ID: Hi, At etc/rancid.conf, you need to change : # FILTER_PWDS determines which passwords are filtered from configs by the # value set (NO | YES | ALL). see rancid.conf(5). FILTER_PWDS=NO; export FILTER_PWDS This applies for all rancid scripts. Regards., > From: bha.Qaqish at NITC.gov.jo > To: rancid-discuss at shrubbery.net > Date: Fri, 9 Mar 2012 15:12:10 +0200 > Subject: [rancid] password > > Dear > i using rancid for 2 month > and i check the config from the GUI , and i found > line vty 0 4 > password > > how can i appear the password . > i do not want to hide it > > BR > BHA QAQISH > _______________________________________________ > Rancid-discuss mailing list > Rancid-discuss at shrubbery.net > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss -------------- next part -------------- An HTML attachment was scrubbed... URL: From rwest at zyedge.com Fri Mar 9 13:50:35 2012 From: rwest at zyedge.com (Ryan West) Date: Fri, 9 Mar 2012 13:50:35 +0000 Subject: [rancid] Cisco ASA+WLC script In-Reply-To: References: <24E0598B-4E9E-4809-9267-0070143A72FB@zyedge.com> , Message-ID: <11EFCCFF-BFE1-48F6-86EE-6E74393B72BD@zyedge.com> Try wlogin5 Sent from handheld On Mar 9, 2012, at 8:38 AM, "Michael Maymann" > wrote: Hi, Ryan: ok. No, I didn't - do I have to :) ?. Shouldn't I just be able to: /usr/libexec/rancid/wlogin -f ~/.cloginrc_cisco -c "sh cpu" HOST ? Thanks in advance :-)! ~maymann 2012/3/9 Ryan West > Yes, that's it. I assume you set up rancid-fe and tried rancid-run -r devicename as well? Sent from handheld On Mar 9, 2012, at 8:20 AM, "Michael Maymann" > wrote: Hi, Ryan: thanks for your reply. I'm running... Rancid: 2.3.6 WLC: 6.0.202.0 found a wlogin here: http://www.gossamer-threads.com/lists/rancid/users/4674 but I can't get it to work: -bash-3.2$ /usr/libexec/rancid/wlogin -f ~/.cloginrc_cisco -c "sh cpu" HOST ": no such file or directory -bash-3.2$ /usr/libexec/rancid/wlogin -c "sh cpu" HOST ": no such file or directory Is this the one you are talking about - or is there a newer one somewhere ? Thanks in advance :-) ! ~maymann 2012/3/9 Ryan West > Do a search in the archive and you'll find the wlc script. What version are you running? Sent from handheld On Mar 9, 2012, at 7:19 AM, "Michael Maymann" > wrote: Hi, Marito: thanks, that did it for the ASA's :) ! now I have the following on my WLC's: --- -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "sh ver" HOST HOST spawn ssh -c 3des -x -l USR HOST (Cisco Controller) User: USR Password:************ (Cisco Controller) >enable Incorrect usage. Use the '?' or key to list commands. (Cisco Controller) > Error: Check your Enable passwd --- These are the non-enable-commands that I can run on the WLC: --- (Cisco Controller) >? clear Clear selected configuration elements. config Configure switch options and settings. debug Manages system debug options. help Help license Manage Software License linktest Perform a link test to a specified MAC address. logout Exit this session. Any unsaved changes are lost. ping Send ICMP echo packets to a specified IP address. mping Send Mobility echo packets to a specified mobility peer IP address. eping Send Ethernet-over-IP echo packets to a specified mobility peer IP address. reset Reset options. save Save switch configurations. show Display switch options and settings. test Test trigger commands transfer Transfer a file to or from the switch. --- How can I get this to work as it seems that "enable" command is called "config" ? Should I create a new .cloginrc_wlc for this and what would it look like ? Thanks in advance :) ! ~maymann 2012/3/9 Marito ... > Hi Michael, You should set up autoenable to 0. As per Rancid .clogin help: ".B add autoenable {[01]} When using locally defined usernames or AAA, it is possible to have a login which is automatically enabled. This is, that user has enable privileges without the need to execute the enable command. The router's prompt is different for enabled mode, ending with a # rather than a >. Example: add autoenable * {1} Default: 0 zero, meaning that the user is not automatically enabled and should execute the enable command to gain enable privileges, unless negated by the noenable directive or \-noenable command\-line option. " Regards. ________________________________ From: michael at maymann.org Date: Fri, 9 Mar 2012 12:23:24 +0100 To: rancid-discuss at shrubbery.net Subject: Re: [rancid] Cisco ASA+WLC script Hi, Daniel+DenyIPAnyAny: Thanks for your quick reply :) ! 1. I'm running rancid 2.3.6... don't have any wlogin anywhere... can't see any in 2.3.8 either - how do I get wlogin ? I'm doing this because I have some equipment that rancid doesn't support, that I also need backed-up (and don't know expect that well). So just created a little wrapper around Rancid to perfect things for me. 2. How do you backup your ASA's ? nothing is wrong with my .clogin: --- add method * ssh #add method * telnet add user * USR add password * {PWD} {enable_PWD} add autoenable * {1} --- works fine, logging in and trying to run command(s) and exits - but doesn't enter enable mode and therefore can't run commands like "more system:running-config" that is working fine manually logging in to enable mode: -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "more system:running-config" HOST HOST spawn ssh -c 3des -x -l admin HOST USR at HOST's password: Type help or '?' for a list of available commands. HOST> HOST> terminal length 0 ^ ERROR: % Invalid input detected at '^' marker. HOST> more system:running-config ^ ERROR: % Invalid input detected at '^' marker. HOST>exit Logoff Connection to HOST closed. Thanks in advance :-) ! ~maymann 2012/3/9 Deny IP Any Any > I backup several Cisco ASAs without issue; with your symptoms, usually the problem is with your .clogin file (specifically either the autologin option) 2012/3/8 Michael Maymann >: > Hi List, > > I am trying to configure scheduled backups of my Cisco ASAs and WLCs. > I am currently trying to use clogin. Login is successful, but it never > enters enable/configure mode - and therefore is not able to run the desired > commands/retrieve all the necessary information (it tries to though !). > Can't paste my .clogin, as I'm at home currently. But everything > (password/enable_password) is ok there ! (I am running this already on my HP > Switches) > > just after login and before it should enter enable/configure mode, it tries > to execute the command (from within clogin - not something I told it to...): > "terminal length 0" > but the right command for this on a ASA/WLC's is: > "no pager" or "terminal pager 0" > > 1. Is there a better Xlogin that I should use ? > 2. If clogin is the best script, where in the clogin can I fix this ? > 3. Furthermore clogin doesn't logout of my WLC's when it finishes - I guess > I could just add a "; exit" or "; logout" at the end of my command, but > where can I fix this as-well ? > > > Thanks in advance :) ! > ~maymann > > _______________________________________________ > Rancid-discuss mailing list > Rancid-discuss at shrubbery.net > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss -- deny ip any any (4393649193 matches) _______________________________________________ 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: From bha.Qaqish at NITC.gov.jo Fri Mar 9 13:53:11 2012 From: bha.Qaqish at NITC.gov.jo (bha Qaqish) Date: Fri, 9 Mar 2012 15:53:11 +0200 Subject: [rancid] password In-Reply-To: References: , Message-ID: hi thank you for he response i have one more question can i modify that some of the password appear and some not. is there any way to do that ( anyone have a way) for example to hide the bgp password and show all the password , do you have any example Regards ________________________________________ From: Marito ... [me_gogorza at hotmail.com] Sent: Friday, March 09, 2012 3:40 PM To: bha Qaqish; rancid-discuss at shrubbery.net Subject: RE: [rancid] password Hi, At etc/rancid.conf, you need to change : # FILTER_PWDS determines which passwords are filtered from configs by the # value set (NO | YES | ALL). see rancid.conf(5). FILTER_PWDS=NO; export FILTER_PWDS This applies for all rancid scripts. Regards., > From: bha.Qaqish at NITC.gov.jo > To: rancid-discuss at shrubbery.net > Date: Fri, 9 Mar 2012 15:12:10 +0200 > Subject: [rancid] password > > Dear > i using rancid for 2 month > and i check the config from the GUI , and i found > line vty 0 4 > password > > how can i appear the password . > i do not want to hide it > > BR > BHA QAQISH > _______________________________________________ > Rancid-discuss mailing list > Rancid-discuss at shrubbery.net > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss From michael at maymann.org Fri Mar 9 14:12:19 2012 From: michael at maymann.org (Michael Maymann) Date: Fri, 9 Mar 2012 15:12:19 +0100 Subject: [rancid] Cisco ASA+WLC script In-Reply-To: <11EFCCFF-BFE1-48F6-86EE-6E74393B72BD@zyedge.com> References: <24E0598B-4E9E-4809-9267-0070143A72FB@zyedge.com> <11EFCCFF-BFE1-48F6-86EE-6E74393B72BD@zyedge.com> Message-ID: Hi, how do i try wlogin5 ? Thanks in advance :-) ! ~maymann 2012/3/9 Ryan West > Try wlogin5 > > Sent from handheld > > On Mar 9, 2012, at 8:38 AM, "Michael Maymann" wrote: > > Hi, > > Ryan: ok. > No, I didn't - do I have to :) ?. Shouldn't I just be able to: > /usr/libexec/rancid/wlogin -f ~/.cloginrc_cisco -c "sh cpu" HOST > ? > > > Thanks in advance :-)! > ~maymann > > 2012/3/9 Ryan West > >> Yes, that's it. I assume you set up rancid-fe and tried rancid-run -r >> devicename as well? >> >> Sent from handheld >> >> On Mar 9, 2012, at 8:20 AM, "Michael Maymann" >> wrote: >> >> Hi, >> >> Ryan: thanks for your reply. >> I'm running... >> Rancid: 2.3.6 >> WLC: 6.0.202.0 >> >> found a wlogin here: >> http://www.gossamer-threads.com/lists/rancid/users/4674 >> >> but I can't get it to work: >> -bash-3.2$ /usr/libexec/rancid/wlogin -f ~/.cloginrc_cisco -c "sh cpu" >> HOST >> ": no such file or directory >> -bash-3.2$ /usr/libexec/rancid/wlogin -c "sh cpu" HOST >> ": no such file or directory >> >> Is this the one you are talking about - or is there a newer one somewhere >> ? >> >> >> Thanks in advance :-) ! >> ~maymann >> >> >> 2012/3/9 Ryan West >> >>> Do a search in the archive and you'll find the wlc script. What >>> version are you running? >>> >>> Sent from handheld >>> >>> On Mar 9, 2012, at 7:19 AM, "Michael Maymann" >>> wrote: >>> >>> Hi, >>> >>> Marito: thanks, that did it for the ASA's :) ! >>> now I have the following on my WLC's: >>> --- >>> -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "sh ver" >>> HOST >>> HOST >>> spawn ssh -c 3des -x -l USR HOST >>> >>> >>> (Cisco Controller) >>> User: USR >>> Password:************ >>> (Cisco Controller) >enable >>> >>> Incorrect usage. Use the '?' or key to list commands. >>> >>> (Cisco Controller) > >>> Error: Check your Enable passwd >>> --- >>> >>> These are the non-enable-commands that I can run on the WLC: >>> --- >>> (Cisco Controller) >? >>> >>> clear Clear selected configuration elements. >>> config Configure switch options and settings. >>> debug Manages system debug options. >>> help Help >>> license Manage Software License >>> linktest Perform a link test to a specified MAC address. >>> logout Exit this session. Any unsaved changes are lost. >>> ping Send ICMP echo packets to a specified IP address. >>> mping Send Mobility echo packets to a specified mobility peer >>> IP address. >>> eping Send Ethernet-over-IP echo packets to a specified >>> mobility peer IP address. >>> reset Reset options. >>> save Save switch configurations. >>> show Display switch options and settings. >>> test Test trigger commands >>> transfer Transfer a file to or from the switch. >>> --- >>> >>> How can I get this to work as it seems that "enable" command is called >>> "config" ? >>> Should I create a new .cloginrc_wlc for this and what would it look like >>> ? >>> >>> >>> Thanks in advance :) ! >>> ~maymann >>> >>> >>> 2012/3/9 Marito ... >>> >>>> Hi Michael, >>>> >>>> You should set up autoenable to 0. As per Rancid .clogin help: >>>> >>>> ".B add autoenable {[01]} >>>> When using locally defined usernames or AAA, it is possible to have a >>>> login which is automatically enabled. This is, that user has enable >>>> privileges without the need to execute the enable command. The router's >>>> prompt is different for enabled mode, ending with a # rather than a >. >>>> >>>> Example: add autoenable * {1} >>>> >>>> Default: 0 >>>> >>>> zero, meaning that the user is not automatically enabled and should >>>> execute the enable command to gain enable privileges, unless negated by the >>>> noenable directive or \-noenable command\-line option. >>>> " >>>> >>>> Regards. >>>> >>>> >>>> ------------------------------ >>>> From: michael at maymann.org >>>> Date: Fri, 9 Mar 2012 12:23:24 +0100 >>>> To: rancid-discuss at shrubbery.net >>>> Subject: Re: [rancid] Cisco ASA+WLC script >>>> >>>> >>>> Hi, >>>> >>>> Daniel+DenyIPAnyAny: Thanks for your quick reply :) ! >>>> >>>> 1. I'm running rancid 2.3.6... don't have any wlogin anywhere... can't >>>> see any in 2.3.8 either - how do I get wlogin ? >>>> I'm doing this because I have some equipment that rancid doesn't >>>> support, that I also need backed-up (and don't know expect that well). So >>>> just created a little wrapper around Rancid to perfect things for me. >>>> >>>> 2. How do you backup your ASA's ? >>>> nothing is wrong with my .clogin: >>>> --- >>>> add method * ssh >>>> #add method * telnet >>>> add user * USR >>>> add password * {PWD} {enable_PWD} >>>> add autoenable * {1} >>>> --- >>>> works fine, logging in and trying to run command(s) and exits - but >>>> doesn't enter enable mode and therefore can't run commands like "more >>>> system:running-config" that is working fine manually logging in to enable >>>> mode: >>>> -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "more >>>> system:running-config" HOST >>>> HOST >>>> spawn ssh -c 3des -x -l admin HOST >>>> USR at HOST's password: >>>> Type help or '?' for a list of available commands. >>>> HOST> >>>> HOST> terminal length 0 >>>> ^ >>>> ERROR: % Invalid input detected at '^' marker. >>>> HOST> more system:running-config >>>> ^ >>>> ERROR: % Invalid input detected at '^' marker. >>>> HOST>exit >>>> >>>> Logoff >>>> >>>> Connection to HOST closed. >>>> >>>> >>>> Thanks in advance :-) ! >>>> >>>> ~maymann >>>> >>>> 2012/3/9 Deny IP Any Any >>>> >>>> I backup several Cisco ASAs without issue; with your symptoms, usually >>>> the problem is with your .clogin file (specifically either the >>>> autologin option) >>>> >>>> 2012/3/8 Michael Maymann : >>>> > Hi List, >>>> > >>>> > I am trying to configure scheduled backups of my Cisco ASAs and WLCs. >>>> > I am currently trying to use clogin. Login is successful, but it never >>>> > enters enable/configure mode - and therefore is not able to run the >>>> desired >>>> > commands/retrieve all the necessary information (it tries to though >>>> !). >>>> > Can't paste my .clogin, as I'm at home currently. But everything >>>> > (password/enable_password) is ok there ! (I am running this already >>>> on my HP >>>> > Switches) >>>> > >>>> > just after login and before it should enter enable/configure mode, it >>>> tries >>>> > to execute the command (from within clogin - not something I told it >>>> to...): >>>> > "terminal length 0" >>>> > but the right command for this on a ASA/WLC's is: >>>> > "no pager" or "terminal pager 0" >>>> > >>>> > 1. Is there a better Xlogin that I should use ? >>>> > 2. If clogin is the best script, where in the clogin can I fix this ? >>>> > 3. Furthermore clogin doesn't logout of my WLC's when it finishes - I >>>> guess >>>> > I could just add a "; exit" or "; logout" at the end of my command, >>>> but >>>> > where can I fix this as-well ? >>>> > >>>> > >>>> > Thanks in advance :) ! >>>> > ~maymann >>>> > >>>> > _______________________________________________ >>>> > Rancid-discuss mailing list >>>> > Rancid-discuss at shrubbery.net >>>> > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss >>>> >>>> >>>> >>>> -- >>>> deny ip any any (4393649193 matches) >>>> >>>> >>>> >>>> _______________________________________________ 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 >>> >>> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From rwest at zyedge.com Fri Mar 9 14:17:20 2012 From: rwest at zyedge.com (Ryan West) Date: Fri, 9 Mar 2012 14:17:20 +0000 Subject: [rancid] Cisco ASA+WLC script In-Reply-To: References: <24E0598B-4E9E-4809-9267-0070143A72FB@zyedge.com> <11EFCCFF-BFE1-48F6-86EE-6E74393B72BD@zyedge.com> Message-ID: <5DC4853C6CC3EE4788779E0726E034DD0107451F@zy-ex1.zyedge.local> Michael, /usr/libexec/rancid/wlogin -f ~/.cloginrc_cisco -c 'sh cpu' HOST This works for me. I was referring to ciscowlc5, my fault there. -ryan From: Michael Maymann [mailto:michael at maymann.org] Sent: Friday, March 09, 2012 9:12 AM To: Ryan West Cc: rancid-discuss at shrubbery.net Subject: Re: [rancid] Cisco ASA+WLC script Hi, how do i try wlogin5 ? Thanks in advance :-) ! ~maymann 2012/3/9 Ryan West > Try wlogin5 Sent from handheld On Mar 9, 2012, at 8:38 AM, "Michael Maymann" > wrote: Hi, Ryan: ok. No, I didn't - do I have to :) ?. Shouldn't I just be able to: /usr/libexec/rancid/wlogin -f ~/.cloginrc_cisco -c "sh cpu" HOST ? Thanks in advance :-)! ~maymann 2012/3/9 Ryan West > Yes, that's it. I assume you set up rancid-fe and tried rancid-run -r devicename as well? Sent from handheld On Mar 9, 2012, at 8:20 AM, "Michael Maymann" > wrote: Hi, Ryan: thanks for your reply. I'm running... Rancid: 2.3.6 WLC: 6.0.202.0 found a wlogin here: http://www.gossamer-threads.com/lists/rancid/users/4674 but I can't get it to work: -bash-3.2$ /usr/libexec/rancid/wlogin -f ~/.cloginrc_cisco -c "sh cpu" HOST ": no such file or directory -bash-3.2$ /usr/libexec/rancid/wlogin -c "sh cpu" HOST ": no such file or directory Is this the one you are talking about - or is there a newer one somewhere ? Thanks in advance :-) ! ~maymann 2012/3/9 Ryan West > Do a search in the archive and you'll find the wlc script. What version are you running? Sent from handheld On Mar 9, 2012, at 7:19 AM, "Michael Maymann" > wrote: Hi, Marito: thanks, that did it for the ASA's :) ! now I have the following on my WLC's: --- -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "sh ver" HOST HOST spawn ssh -c 3des -x -l USR HOST (Cisco Controller) User: USR Password:************ (Cisco Controller) >enable Incorrect usage. Use the '?' or key to list commands. (Cisco Controller) > Error: Check your Enable passwd --- These are the non-enable-commands that I can run on the WLC: --- (Cisco Controller) >? clear Clear selected configuration elements. config Configure switch options and settings. debug Manages system debug options. help Help license Manage Software License linktest Perform a link test to a specified MAC address. logout Exit this session. Any unsaved changes are lost. ping Send ICMP echo packets to a specified IP address. mping Send Mobility echo packets to a specified mobility peer IP address. eping Send Ethernet-over-IP echo packets to a specified mobility peer IP address. reset Reset options. save Save switch configurations. show Display switch options and settings. test Test trigger commands transfer Transfer a file to or from the switch. --- How can I get this to work as it seems that "enable" command is called "config" ? Should I create a new .cloginrc_wlc for this and what would it look like ? Thanks in advance :) ! ~maymann 2012/3/9 Marito ... > Hi Michael, You should set up autoenable to 0. As per Rancid .clogin help: ".B add autoenable {[01]} When using locally defined usernames or AAA, it is possible to have a login which is automatically enabled. This is, that user has enable privileges without the need to execute the enable command. The router's prompt is different for enabled mode, ending with a # rather than a >. Example: add autoenable * {1} Default: 0 zero, meaning that the user is not automatically enabled and should execute the enable command to gain enable privileges, unless negated by the noenable directive or \-noenable command\-line option. " Regards. ________________________________ From: michael at maymann.org Date: Fri, 9 Mar 2012 12:23:24 +0100 To: rancid-discuss at shrubbery.net Subject: Re: [rancid] Cisco ASA+WLC script Hi, Daniel+DenyIPAnyAny: Thanks for your quick reply :) ! 1. I'm running rancid 2.3.6... don't have any wlogin anywhere... can't see any in 2.3.8 either - how do I get wlogin ? I'm doing this because I have some equipment that rancid doesn't support, that I also need backed-up (and don't know expect that well). So just created a little wrapper around Rancid to perfect things for me. 2. How do you backup your ASA's ? nothing is wrong with my .clogin: --- add method * ssh #add method * telnet add user * USR add password * {PWD} {enable_PWD} add autoenable * {1} --- works fine, logging in and trying to run command(s) and exits - but doesn't enter enable mode and therefore can't run commands like "more system:running-config" that is working fine manually logging in to enable mode: -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "more system:running-config" HOST HOST spawn ssh -c 3des -x -l admin HOST USR at HOST's password: Type help or '?' for a list of available commands. HOST> HOST> terminal length 0 ^ ERROR: % Invalid input detected at '^' marker. HOST> more system:running-config ^ ERROR: % Invalid input detected at '^' marker. HOST>exit Logoff Connection to HOST closed. Thanks in advance :-) ! ~maymann 2012/3/9 Deny IP Any Any > I backup several Cisco ASAs without issue; with your symptoms, usually the problem is with your .clogin file (specifically either the autologin option) 2012/3/8 Michael Maymann >: > Hi List, > > I am trying to configure scheduled backups of my Cisco ASAs and WLCs. > I am currently trying to use clogin. Login is successful, but it never > enters enable/configure mode - and therefore is not able to run the desired > commands/retrieve all the necessary information (it tries to though !). > Can't paste my .clogin, as I'm at home currently. But everything > (password/enable_password) is ok there ! (I am running this already on my HP > Switches) > > just after login and before it should enter enable/configure mode, it tries > to execute the command (from within clogin - not something I told it to...): > "terminal length 0" > but the right command for this on a ASA/WLC's is: > "no pager" or "terminal pager 0" > > 1. Is there a better Xlogin that I should use ? > 2. If clogin is the best script, where in the clogin can I fix this ? > 3. Furthermore clogin doesn't logout of my WLC's when it finishes - I guess > I could just add a "; exit" or "; logout" at the end of my command, but > where can I fix this as-well ? > > > Thanks in advance :) ! > ~maymann > > _______________________________________________ > Rancid-discuss mailing list > Rancid-discuss at shrubbery.net > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss -- deny ip any any (4393649193 matches) _______________________________________________ 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: From paolo at paolodemichele.it Fri Mar 9 14:09:42 2012 From: paolo at paolodemichele.it (Paolo De Michele) Date: Fri, 09 Mar 2012 15:09:42 +0100 Subject: [rancid] - problem sending mail and matching configuration In-Reply-To: References: <4F59E720.4020404@paolodemichele.it> Message-ID: <4F5A0F26.6030300@paolodemichele.it> How do I? On 03/09/2012 02:07 PM, bha Qaqish wrote: > ______hi > do you test to send an email using another domain > > br > bha qaqish > > __________________________________ > From: rancid-discuss-bounces at shrubbery.net [rancid-discuss-bounces at shrubbery.net] On Behalf Of Paolo De Michele [paolo at paolodemichele.it] > Sent: Friday, March 09, 2012 1:18 PM > To: rancid-discuss at shrubbery.net > Subject: [rancid] - problem sending mail and matching configuration > > Hi all, > > using rancid 2.3.8 with os ubuntu 11.04 server. > I did the various configurations and are quite happy with it. > My problem is that when software rancid makes a matching configuration creates a new file. > > What I would do is this: > - create a file when the new configuration is detected ( OK ) > - send me an email with the changes detected in the new configuration > > I failed in any way using /etc/aliases and sendmail to send a mail to an address of a royal domain. > can you help me somehow? > thanks in advance -------------- next part -------------- An HTML attachment was scrubbed... URL: From michael at maymann.org Fri Mar 9 14:25:48 2012 From: michael at maymann.org (Michael Maymann) Date: Fri, 9 Mar 2012 15:25:48 +0100 Subject: [rancid] Cisco ASA+WLC script In-Reply-To: <5DC4853C6CC3EE4788779E0726E034DD0107451F@zy-ex1.zyedge.local> References: <24E0598B-4E9E-4809-9267-0070143A72FB@zyedge.com> <11EFCCFF-BFE1-48F6-86EE-6E74393B72BD@zyedge.com> <5DC4853C6CC3EE4788779E0726E034DD0107451F@zy-ex1.zyedge.local> Message-ID: Hi, ok - no worries... Can you share your /usr/libexec/rancid/wlogin ? Thanks in advance :) ! ~maymann 2012/3/9 Ryan West > Michael,**** > > ** ** > > /usr/libexec/rancid/wlogin -f ~/.cloginrc_cisco -c ?sh cpu? HOST**** > > ** ** > > This works for me. I was referring to ciscowlc5, my fault there.**** > > ** ** > > -ryan**** > > ** ** > > *From:* Michael Maymann [mailto:michael at maymann.org] > *Sent:* Friday, March 09, 2012 9:12 AM > *To:* Ryan West > *Cc:* rancid-discuss at shrubbery.net > > *Subject:* Re: [rancid] Cisco ASA+WLC script**** > > ** ** > > Hi, > > how do i try wlogin5 ? > > > Thanks in advance :-) ! > ~maymann**** > > 2012/3/9 Ryan West **** > > Try wlogin5 > > Sent from handheld **** > > > On Mar 9, 2012, at 8:38 AM, "Michael Maymann" wrote: > **** > > Hi, > > Ryan: ok. > No, I didn't - do I have to :) ?. Shouldn't I just be able to: > /usr/libexec/rancid/wlogin -f ~/.cloginrc_cisco -c "sh cpu" HOST > ? > > > Thanks in advance :-)! > ~maymann**** > > 2012/3/9 Ryan West **** > > Yes, that's it. I assume you set up rancid-fe and tried rancid-run -r > devicename as well? > > Sent from handheld **** > > > On Mar 9, 2012, at 8:20 AM, "Michael Maymann" wrote: > **** > > Hi, > > Ryan: thanks for your reply. > I'm running... > Rancid: 2.3.6 > WLC: 6.0.202.0 > > found a wlogin here: > http://www.gossamer-threads.com/lists/rancid/users/4674 > > but I can't get it to work: > -bash-3.2$ /usr/libexec/rancid/wlogin -f ~/.cloginrc_cisco -c "sh cpu" HOST > ": no such file or directory > -bash-3.2$ /usr/libexec/rancid/wlogin -c "sh cpu" HOST > ": no such file or directory > > Is this the one you are talking about - or is there a newer one somewhere ? > > > Thanks in advance :-) ! > ~maymann > > **** > > 2012/3/9 Ryan West **** > > Do a search in the archive and you'll find the wlc script. What version > are you running? > > Sent from handheld **** > > > On Mar 9, 2012, at 7:19 AM, "Michael Maymann" wrote: > **** > > Hi, > > Marito: thanks, that did it for the ASA's :) ! > now I have the following on my WLC's: > --- > -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "sh ver" HOST > HOST > spawn ssh -c 3des -x -l USR HOST > > > (Cisco Controller) > User: USR > Password:************ > (Cisco Controller) >enable > > Incorrect usage. Use the '?' or key to list commands. > > (Cisco Controller) > > Error: Check your Enable passwd > --- > > These are the non-enable-commands that I can run on the WLC: > --- > (Cisco Controller) >? > > clear Clear selected configuration elements. > config Configure switch options and settings. > debug Manages system debug options. > help Help > license Manage Software License > linktest Perform a link test to a specified MAC address. > logout Exit this session. Any unsaved changes are lost. > ping Send ICMP echo packets to a specified IP address. > mping Send Mobility echo packets to a specified mobility peer IP > address. > eping Send Ethernet-over-IP echo packets to a specified mobility > peer IP address. > reset Reset options. > save Save switch configurations. > show Display switch options and settings. > test Test trigger commands > transfer Transfer a file to or from the switch. > --- > > How can I get this to work as it seems that "enable" command is called > "config" ? > Should I create a new .cloginrc_wlc for this and what would it look like ? > > > Thanks in advance :) ! > ~maymann > > **** > > 2012/3/9 Marito ... **** > > Hi Michael, > > You should set up autoenable to 0. As per Rancid .clogin help: > > ".B add autoenable {[01]} > When using locally defined usernames or AAA, it is possible to have a > login which is automatically enabled. This is, that user has enable > privileges without the need to execute the enable command. The router's > prompt is different for enabled mode, ending with a # rather than a >. > > Example: add autoenable * {1} > > Default: 0 > > zero, meaning that the user is not automatically enabled and should > execute the enable command to gain enable privileges, unless negated by the > noenable directive or \-noenable command\-line option. > " > > Regards. > > **** > ------------------------------ > > From: michael at maymann.org > Date: Fri, 9 Mar 2012 12:23:24 +0100 > To: rancid-discuss at shrubbery.net > Subject: Re: [rancid] Cisco ASA+WLC script **** > > > > Hi, > > Daniel+DenyIPAnyAny: Thanks for your quick reply :) ! > > 1. I'm running rancid 2.3.6... don't have any wlogin anywhere... can't see > any in 2.3.8 either - how do I get wlogin ? > I'm doing this because I have some equipment that rancid doesn't support, > that I also need backed-up (and don't know expect that well). So just > created a little wrapper around Rancid to perfect things for me. > > 2. How do you backup your ASA's ? > nothing is wrong with my .clogin: > --- > add method * ssh > #add method * telnet > add user * USR > add password * {PWD} {enable_PWD} > add autoenable * {1} > --- > works fine, logging in and trying to run command(s) and exits - but > doesn't enter enable mode and therefore can't run commands like "more > system:running-config" that is working fine manually logging in to enable > mode: > -bash-3.2$ /usr/libexec/rancid/clogin -f ~/.cloginrc_cisco -c "more > system:running-config" HOST > HOST > spawn ssh -c 3des -x -l admin HOST > USR at HOST's password: > Type help or '?' for a list of available commands. > HOST> > HOST> terminal length 0 > ^ > ERROR: % Invalid input detected at '^' marker. > HOST> more system:running-config > ^ > ERROR: % Invalid input detected at '^' marker. > HOST>exit > > Logoff > > Connection to HOST closed. > > > Thanks in advance :-) ! > > ~maymann**** > > 2012/3/9 Deny IP Any Any **** > > I backup several Cisco ASAs without issue; with your symptoms, usually > the problem is with your .clogin file (specifically either the > autologin option) > > 2012/3/8 Michael Maymann :**** > > > Hi List, > > > > I am trying to configure scheduled backups of my Cisco ASAs and WLCs. > > I am currently trying to use clogin. Login is successful, but it never > > enters enable/configure mode - and therefore is not able to run the > desired > > commands/retrieve all the necessary information (it tries to though !). > > Can't paste my .clogin, as I'm at home currently. But everything > > (password/enable_password) is ok there ! (I am running this already on > my HP > > Switches) > > > > just after login and before it should enter enable/configure mode, it > tries > > to execute the command (from within clogin - not something I told it > to...): > > "terminal length 0" > > but the right command for this on a ASA/WLC's is: > > "no pager" or "terminal pager 0" > > > > 1. Is there a better Xlogin that I should use ? > > 2. If clogin is the best script, where in the clogin can I fix this ? > > 3. Furthermore clogin doesn't logout of my WLC's when it finishes - I > guess > > I could just add a "; exit" or "; logout" at the end of my command, but > > where can I fix this as-well ? > > > > > > Thanks in advance :) ! > > ~maymann > >**** > > > _______________________________________________ > > Rancid-discuss mailing list > > Rancid-discuss at shrubbery.net > > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss > > > > -- > deny ip any any (4393649193 matches)**** > > > > _______________________________________________ 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**** > > ** ** > > ** ** > > ** ** > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bha.Qaqish at NITC.gov.jo Fri Mar 9 19:38:02 2012 From: bha.Qaqish at NITC.gov.jo (bha Qaqish) Date: Fri, 9 Mar 2012 21:38:02 +0200 Subject: [rancid] adding new command Message-ID: Dear am trying to add the sh cdp nei to the command table @commandtable but i can not find the path of it, where does it exist in any file am using rancid with ubuntu BR From bha.Qaqish at NITC.gov.jo Sat Mar 10 11:57:05 2012 From: bha.Qaqish at NITC.gov.jo (bha Qaqish) Date: Sat, 10 Mar 2012 13:57:05 +0200 Subject: [rancid] adding new command to command table Message-ID: HI all am trying to add the sh cdp neighbor or show interface status to the command table i search in the internet and in rencid discuss ===> i found that i can add the command in the @commandtable @commandtable but i can not find the path of it, where does it exist in any file am using rancid with ubuntu thank you BR _______________________________________________ From paolo at paolodemichele.it Sat Mar 10 13:59:41 2012 From: paolo at paolodemichele.it (Paolo De Michele) Date: Sat, 10 Mar 2012 14:59:41 +0100 Subject: [rancid] - problem sending mail and matching configuration In-Reply-To: <20120309170130.GI86937@shrubbery.net> References: <4F59E720.4020404@paolodemichele.it> <4F5A0F26.6030300@paolodemichele.it> <20120309170130.GI86937@shrubbery.net> Message-ID: <4F5B5E4D.2010705@paolodemichele.it> hi heasley, thank you for your reply On 03/09/2012 06:01 PM, heasley wrote: >>> using rancid 2.3.8 with os ubuntu 11.04 server. >>> I did the various configurations and are quite happy with it. >>> My problem is that when software rancid makes a matching configuration creates a new file. >>> >>> What I would do is this: >>> - create a file when the new configuration is detected ( OK ) >>> - send me an email with the changes detected in the new configuration >>> >>> I failed in any way using /etc/aliases and sendmail to send a mail to an address of a royal domain. >>> can you help me somehow? > diffs are sent to rancid-. you should test sending email > to that alias. administrative messages are send to rancid-admin- name>; so test that alias too. > > If you can not get these aliases to work, refer to the mail lists or forums > that are for support of whatever you are using for you MTA, whether that is > sendmail or postfix. > > if that does work; then look in the rancid logs files for errors. You can have a config example file/etc/aliases? -------------- next part -------------- An HTML attachment was scrubbed... URL: From l.mohanphy at gmail.com Sat Mar 10 14:16:09 2012 From: l.mohanphy at gmail.com (Mohan L) Date: Sat, 10 Mar 2012 19:46:09 +0530 Subject: [rancid] adding new command to command table In-Reply-To: References: Message-ID: On Sat, Mar 10, 2012 at 5:27 PM, bha Qaqish wrote: > > HI all > > am trying to add the > sh cdp neighbor > or show interface status > to the command table > i search in the internet and in rencid discuss ===> i found that i can > add the command in the @commandtable > @commandtable > > but i can not find the path of it, where does it exist in any file > am using rancid with ubuntu > > thank you > > > BR > Dear BR, Read the below link, It will help you : 1). http://certifiedgeek.blogsome.com/2011/10/23/rancid-under-the-hood/ 2). http://certifiedgeek.blogsome.com/2011/11/02/rancid-additional-commands/ and also take look at the below thread in rancid mailing list http://www.shrubbery.net/pipermail/rancid-discuss/2012-February/006228.html I am using the same script with little modification. Thanks Mohan L -------------- next part -------------- An HTML attachment was scrubbed... URL: From vaclav.ovsik at i.cz Wed Mar 7 10:15:22 2012 From: vaclav.ovsik at i.cz (=?iso-8859-1?Q?V=E1clav_Ovs=EDk?=) Date: Wed, 7 Mar 2012 11:15:22 +0100 Subject: [rancid] my scripts for Cisco WLC Message-ID: <20120307101522.GA3052@bobek.localdomain> Hi, We have: (Cisco Controller) >show udi NAME: "Chassis" , DESCR: "Cisco Wireless Controller" PID: WS-C3750G-24WS-S25, VID: V02, SN: FOCxxxxxxx (Cisco Controller) >show sysinfo Manufacturer's Name.............................. Cisco Systems Inc. Product Name..................................... Cisco Controller Product Version.................................. 5.2.193.0 RTOS Version..................................... 5.2.193.0 Bootloader Version............................... 4.0.217.0 Emergency Image Version.......................... 5.2.157.0 ... This box has a prompt as show above `(Cisco Controller) >' and non standard command to disable paging: config paging disable so a standard clogin can't handle it. I found a post http://www.shrubbery.net/pipermail/rancid-discuss/2010-February/004652.html and start with attached wlogin and ciscowlc5, many thanks for this starting point to Jeremy. The original wlogin not used disabled paging and the stupid box did paging in the middle of the line. Fortunately I found the command above for disabling paging. After learning expect a bit :) I took original clogin from Rancid, strip down enable mode and apply the different prompt and command to disable paging. I modify a little ciscowlc5, so it can be used with http://sites.google.com/site/jrbinks/code/rancid/wraprancid. My versions of files wlogin and ciscowlc5 are attached. Hope it can be useful for someone. I'm not subscribed on this list, so keep me in the Cc please if I should receive a reply.. Regards -- Zito -------------- next part -------------- #! /usr/bin/expect -- ## ## $Id: clogin.in 2162 2010-03-15 21:20:31Z heas $ ## ## rancid 2.3.3 ## Copyright (c) 1997-2009 by Terrapin Communications, Inc. ## All rights reserved. ## ## This code is derived from software contributed to and maintained by ## Terrapin Communications, Inc. by Henry Kilmer, John Heasley, Andrew Partan, ## Pete Whiting, Austin Schutz, and Andrew Fort. ## ## Redistribution and use in source and binary forms, with or without ## modification, are permitted provided that the following conditions ## are met: ## 1. Redistributions of source code must retain the above copyright ## notice, this list of conditions and the following disclaimer. ## 2. Redistributions in binary form must reproduce the above copyright ## notice, this list of conditions and the following disclaimer in the ## documentation and/or other materials provided with the distribution. ## 3. All advertising materials mentioning features or use of this software ## must display the following acknowledgement: ## This product includes software developed by Terrapin Communications, ## Inc. and its contributors for RANCID. ## 4. Neither the name of Terrapin Communications, Inc. nor the names of its ## contributors may be used to endorse or promote products derived from ## this software without specific prior written permission. ## 5. It is requested that non-binding fixes and modifications be contributed ## back to Terrapin Communications, Inc. ## ## THIS SOFTWARE IS PROVIDED BY Terrapin Communications, INC. AND CONTRIBUTORS ## ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED ## TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR ## PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COMPANY OR CONTRIBUTORS ## BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR ## CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF ## SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS ## INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN ## CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ## ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE ## POSSIBILITY OF SUCH DAMAGE. # # The expect login scripts were based on Erik Sherk's gwtn, by permission. # # wlogin - Cisco Wireless Controller login # # # Usage line set usage "Usage: $argv0 \[-dSV\] \[-c command\] \ \[-Evar=x\] \[-f cloginrc-file\] \[-p user-password\] \ \[-s script-file\] \[-t timeout\] \[-u username\] \ \[-v vty-password\] \[-x command-file\] \ \[-y ssh_cypher_type\] router \[router...\]\n" # env(CLOGIN) may contain: # x == do not set xterm banner or name # Password file set password_file $env(HOME)/.cloginrc # Default is to login to the router set do_command 0 set do_script 0 # The default is to look in the password file to find the passwords. This # tracks if we receive them on the command line. set do_passwd 1 # Save config, if prompted set do_saveconfig 0 # Sometimes routers take awhile to answer (the default is 10 sec) set timeoutdflt 45 # set send_human {.4 .4 .7 .3 5} # new option to provide "login" command capabilities set loginonly 0 # Find the user in the ENV, or use the unix userid. if {[ info exists env(CISCO_USER) ]} { set default_user $env(CISCO_USER) } elseif {[ info exists env(USER) ]} { set default_user $env(USER) } elseif {[ info exists env(LOGNAME) ]} { set default_user $env(LOGNAME) } else { # This uses "id" which I think is portable. At least it has existed # (without options) on all machines/OSes I've been on recently - # unlike whoami or id -nu. if [ catch {exec id} reason ] { send_error "\nError: could not exec id: $reason\n" exit 1 } regexp {\(([^)]*)} "$reason" junk default_user } if {[ info exists env(CLOGINRC) ]} { set password_file $env(CLOGINRC) } # Process the command line for {set i 0} {$i < $argc} {incr i} { set arg [lindex $argv $i] switch -glob -- $arg { # Expect debug mode -d* { exp_internal 1 # Username } -u* { if {! [regexp .\[uU\](.+) $arg ignore user]} { incr i set username [ lindex $argv $i ] } # VTY Password } -p* { if {! [regexp .\[pP\](.+) $arg ignore userpasswd]} { incr i set userpasswd [ lindex $argv $i ] } set do_passwd 0 # VTY Password } -v* { if {! [regexp .\[vV\](.+) $arg ignore passwd]} { incr i set passwd [ lindex $argv $i ] } set do_passwd 0 # Version string } -V* { send_user "rancid 2.3.3\n" exit 0 # Environment variable to pass to -s scripts } -E* { if {[regexp .\[E\](.+)=(.+) $arg ignore varname varvalue]} { set E$varname $varvalue } else { send_user "\nError: invalid format for -E in $arg\n" exit 1 } # Command to run. } -c* { if {! [regexp .\[cC\](.+) $arg ignore command]} { incr i set command [ lindex $argv $i ] } set do_command 1 # Expect script to run. } -s* { if {! [regexp .\[sS\](.+) $arg ignore sfile]} { incr i set sfile [ lindex $argv $i ] } if { ! [ file readable $sfile ] } { send_user "\nError: Can't read $sfile\n" exit 1 } set do_script 1 # save config on exit } -S* { set do_saveconfig 1 # 'ssh -c' cypher type } -y* { if {! [regexp .\[eE\](.+) $arg ignore cypher]} { incr i set cypher [ lindex $argv $i ] } # alternate cloginrc file } -f* { if {! [regexp .\[fF\](.+) $arg ignore password_file]} { incr i set password_file [ lindex $argv $i ] } # Timeout } -t* { if {! [regexp .\[tT\](.+) $arg ignore timeout]} { incr i set timeoutdflt [ lindex $argv $i ] } # Command file } -x* { if {! [regexp .\[xX\](.+) $arg ignore cmd_file]} { incr i set cmd_file [ lindex $argv $i ] } if [ catch {set cmd_fd [open $cmd_file r]} reason ] { send_user "\nError: $reason\n" exit 1 } set cmd_text [read $cmd_fd] close $cmd_fd set command [join [split $cmd_text \n] \;] set do_command 1 } -* { send_user "\nError: Unknown argument! $arg\n" send_user $usage exit 1 } default { break } } } # Process routers...no routers listed is an error. if { $i == $argc } { send_user "\nError: $usage" } # Only be quiet if we are running a script (it can log its output # on its own) if { $do_script } { log_user 0 } else { log_user 1 } # # Done configuration/variable setting. Now run with it... # # Sets Xterm title if interactive...if its an xterm and the user cares proc label { host } { global env # if CLOGIN has an 'x' in it, don't set the xterm name/banner if [info exists env(CLOGIN)] { if {[string first "x" $env(CLOGIN)] != -1} { return } } # take host from ENV(TERM) if [info exists env(TERM)] { if [ regexp \^(xterm|vs) $env(TERM) ignore ] { send_user "\033]1;[lindex [split $host "."] 0]\a" send_user "\033]2;$host\a" } } } # This is a helper function to make the password file easier to # maintain. Using this the password file has the form: # add password sl* pete cow # add password at* steve # add password * hanky-pie proc add {var args} { global int_$var ; lappend int_$var $args} proc include {args} { global env regsub -all "(^{|}$)" $args {} args if { [ regexp "^/" $args ignore ] == 0 } { set args $env(HOME)/$args } source_password_file $args } proc find {var router} { upvar int_$var list if { [info exists list] } { foreach line $list { if { [string match [lindex $line 0] $router ] } { return [lrange $line 1 end] } } } return {} } # Loads the password file. Note that as this file is tcl, and that # it is sourced, the user better know what to put in there, as it # could install more than just password info... I will assume however, # that a "bad guy" could just as easy put such code in the clogin # script, so I will leave .cloginrc as just an extention of that script proc source_password_file { password_file } { global env if { ! [file exists $password_file] } { send_user "\nError: password file ($password_file) does not exist\n" exit 1 } file stat $password_file fileinfo if { [expr ($fileinfo(mode) & 007)] != 0000 } { send_user "\nError: $password_file must not be world readable/writable\n" exit 1 } if [ catch {source $password_file} reason ] { send_user "\nError: $reason\n" exit 1 } } # Log into the router. # returns: 0 on success, 1 on failure, -1 if rsh was used successfully proc login { router user userpswd passwd cmethod cyphertype } { global command spawn_id in_proc do_command do_script platform global prompt u_prompt p_prompt e_prompt sshcmd set in_proc 1 set uprompt_seen 0 # try each of the connection methods in $cmethod until one is successful set progs [llength $cmethod] foreach prog [lrange $cmethod 0 end] { incr progs -1 if [string match "telnet*" $prog] { regexp {telnet(:([^[:space:]]+))*} $prog methcmd suffix port if {"$port" == ""} { set retval [ catch {spawn telnet $router} reason ] } else { set retval [ catch {spawn telnet $router $port} reason ] } if { $retval } { send_user "\nError: telnet failed: $reason\n" return 1 } } elseif [string match "ssh*" $prog] { regexp {ssh(:([^[:space:]]+))*} $prog methcmd suffix port set cmd [join [lindex $sshcmd 0] " "] if {"$port" != ""} { set cmd "$cmd -p $port" } set retval [ catch {eval spawn [split "$cmd -c $cyphertype -x -l $user $router" { }]} reason ] if { $retval } { send_user "\nError: $sshcmd failed: $reason\n" return 1 } } elseif ![string compare $prog "rsh"] { if { ! $do_command } { if { [llength $cmethod] == 1 } { send_user "\nError: rsh is an invalid method for -x and " send_user "interactive logins\n" } if { $progs == 0 } { return 1 } continue; } set commands [split $command \;] set num_commands [llength $commands] set rshfail 0 for {set i 0} {$i < $num_commands && !$rshfail} { incr i} { log_user 0 set retval [ catch {spawn rsh $user@$router [lindex $commands $i] } reason ] if { $retval } { send_user "\nError: rsh failed: $reason\n" log_user 1; return 1 } send_user "$router# [lindex $commands $i]\n" # rcmd does not get a pager and no prompts, so we just have to # look for failures & lines. expect { "Connection refused" { catch {close}; catch {wait}; send_user "\nError: Connection\ Refused ($prog): $router\n" set rshfail 1 } -re "(Connection closed by|Connection to \[^\n\r]+ closed)" { catch {close}; catch {wait}; send_user "\nError: Connection\ closed ($prog): $router\n" set rshfail 1 } "Host is unreachable" { catch {close}; catch {wait}; send_user "\nError: Host Unreachable:\ $router\n" set rshfail 1 } "No address associated with" { catch {close}; catch {wait}; send_user "\nError: Unknown host\ $router\n" set rshfail 1 } -re "\b+" { exp_continue } -re "\[\n\r]+" { send_user -- "$expect_out(buffer)" exp_continue } timeout { catch {close}; catch {wait}; send_user "\nError: TIMEOUT reached\n" set rshfail 1 } eof { catch {close}; catch {wait}; } } log_user 1 } if { $rshfail } { if { !$progs } { return 1 } else { continue } } # fake the end of the session for rancid. send_user "$router# exit\n" # return rsh "success" return -1 } else { send_user "\nError: unknown connection method: $prog\n" return 1 } sleep 0.3 # This helps cleanup each expect clause. expect_after { timeout { send_user "\nError: TIMEOUT reached\n" catch {close}; catch {wait}; if { $in_proc} { return 1 } else { continue } } eof { send_user "\nError: EOF received\n" catch {close}; catch {wait}; if { $in_proc} { return 1 } else { continue } } } # Here we get a little tricky. There are several possibilities: # the router can ask for a username and passwd and then # talk to the TACACS server to authenticate you... # Or, the router might not have TACACS turned on, # then it will just send the passwd. # if telnet fails with connection refused, try ssh expect { -re "(Connection refused|Secure connection \[^\n\r]+ refused)" { catch {close}; catch {wait}; if !$progs { send_user "\nError: Connection Refused ($prog): $router\n" return 1 } } -re "(Connection closed by|Connection to \[^\n\r]+ closed)" { catch {close}; catch {wait}; if !$progs { send_user "\nError: Connection closed ($prog): $router\n" return 1 } } eof { send_user "\nError: Couldn't login: $router\n"; wait; return 1 } -nocase "unknown host\r" { send_user "\nError: Unknown host $router\n"; catch {close}; catch {wait}; return 1 } "Host is unreachable" { send_user "\nError: Host Unreachable: $router\n"; catch {close}; catch {wait}; return 1 } "No address associated with name" { send_user "\nError: Unknown host $router\n"; catch {close}; catch {wait}; return 1 } -re "(Host key not found |The authenticity of host .* be established).*\(yes\/no\)\?" { send "yes\r" send_user "\nHost $router added to the list of known hosts.\n" exp_continue } -re "HOST IDENTIFICATION HAS CHANGED.* \(yes\/no\)\?" { send "no\r" send_user "\nError: The host key for $router has changed. Update the SSH known_hosts file accordingly.\n" catch {close}; catch {wait}; return 1 } -re "Offending key for .* \(yes\/no\)\?" { send "no\r" send_user "\nError: host key mismatch for $router. Update the SSH known_hosts file accordingly.\n" catch {close}; catch {wait}; return 1 } -re "(denied|Sorry)" { send_user "\nError: Check your passwd for $router\n" catch {close}; catch {wait}; return 1 } "Login failed" { send_user "\nError: Check your passwd for $router\n" catch {close}; catch {wait}; return 1 } -re "% (Bad passwords|Authentication failed)" { send_user "\nError: Check your passwd for $router\n" catch {close}; catch {wait}; return 1 } "Press any key to continue" { # send_user "Pressing the ANY key\n" send "\r" exp_continue } -re "Enter Selection: " { # Catalyst 1900s have some lame menu. Enter # K to reach a command-line. send "K\r" exp_continue } -re "Last login:" { exp_continue } -re "@\[^\r\n]+ $p_prompt" { # ssh pwd prompt sleep 1 send -- "$userpswd\r" exp_continue } -re "$u_prompt" { send -- "$user\r" set uprompt_seen 1 exp_continue } -re "$p_prompt" { sleep 1 if {$uprompt_seen == 1} { send -- "$userpswd\r" } else { send -- "$passwd\r" } exp_continue } -re "$prompt" { break; } "Login invalid" { send_user "\nError: Invalid login: $router\n"; catch {close}; catch {wait}; return 1 } } } set in_proc 0 return 0 } # Run commands given on the command line. proc run_commands { prompt command } { global do_saveconfig in_proc platform set in_proc 1 send "config paging disable\r" expect -re $prompt {} set reprompt $prompt # this is the only way i see to get rid of more prompts in o/p..grrrrr log_user 0 set commands [split $command \;] set num_commands [llength $commands] for {set i 0} {$i < $num_commands} { incr i} { send -- "[subst -nocommands [lindex $commands $i]]\r" expect { -re "\b+" { exp_continue } -re "^\[^\n\r *]*$reprompt" { send_user -- "$expect_out(buffer)" } -re "^\[^\n\r]*$reprompt." { send_user -- "$expect_out(buffer)" exp_continue } -re "^--More--\[\r\n]+" { # specific match c1900 pager send " " exp_continue } -re "\[\n\r]+" { send_user -- "$expect_out(buffer)" exp_continue } } } log_user 1 send -h "exit\r" expect { -re "^\[^\n\r *]*$reprompt" { # the Cisco CE and Jnx ERX # return to non-enabled mode # on exit in enabled mode. send -h "exit\r" exp_continue; } "The system has unsaved changes" { # Force10 SFTOS if {$do_saveconfig} { catch {send "y\r"} } else { catch {send "n\r"} } exp_continue } "Would you like to save them now" { # Force10 if {$do_saveconfig} { catch {send "y\r"} } else { catch {send "n\r"} } exp_continue } -re "(Profile|Configuration) changes have occurred.*" { # Cisco CSS if {$do_saveconfig} { catch {send "y\r"} } else { catch {send "n\r"} } exp_continue } "Do you wish to save your configuration changes" { if {$do_saveconfig} { catch {send "y\r"} } else { catch {send "n\r"} } exp_continue } -re "\[\n\r]+" { exp_continue } timeout { catch {close}; catch {wait}; return 0 } eof { return 0 } } set in_proc 0 } # # For each router... (this is main loop) # source_password_file $password_file set in_proc 0 set exitval 0 foreach router [lrange $argv $i end] { set router [string tolower $router] # attempt at platform switching. set platform "" send_user -- "$router\n" # device timeout set timeout [find timeout $router] if { [llength $timeout] == 0 } { set timeout $timeoutdflt } set prompt ">" # Figure out passwords if { $do_passwd } { set pswd [find password $router] if { [llength $pswd] == 0 } { send_user -- "\nError: no password for $router in $password_file.\n" continue } set passwd [join [lindex $pswd 0] ""] } else { set passwd $userpasswd } # Figure out username if {[info exists username]} { # command line username set ruser $username } else { set ruser [join [find user $router] ""] if { "$ruser" == "" } { set ruser $default_user } } # Figure out username's password (if different from the vty password) if {[info exists userpasswd]} { # command line username set userpswd $userpasswd } else { set userpswd [join [find userpassword $router] ""] if { "$userpswd" == "" } { set userpswd $passwd } } # Figure out prompts set u_prompt [find userprompt $router] if { "$u_prompt" == "" } { set u_prompt "(Username|Login|login|user name|User):" } else { set u_prompt [join [lindex $u_prompt 0] ""] } set p_prompt [find passprompt $router] if { "$p_prompt" == "" } { set p_prompt "(\[Pp]assword|passwd):" } else { set p_prompt [join [lindex $p_prompt 0] ""] } # Figure out cypher type if {[info exists cypher]} { # command line cypher type set cyphertype $cypher } else { set cyphertype [find cyphertype $router] if { "$cyphertype" == "" } { set cyphertype "3des" } } # Figure out connection method set cmethod [find method $router] if { "$cmethod" == "" } { set cmethod {{telnet} {ssh}} } # Figure out the SSH executable name set sshcmd [find sshcmd $router] if { "$sshcmd" == "" } { set sshcmd {ssh} } # Login to the router if {[login $router $ruser $userpswd $passwd $cmethod $cyphertype]} { incr exitval # if login failed or rsh was unsuccessful, move on to the next device continue } # we are logged in, now figure out the full prompt send "\r" expect { -re "\[\r\n]+" { exp_continue; } -re "^.+$prompt" { set junk $expect_out(0,string); regsub -all "\[\]\[\(\)]" $junk {\\&} prompt; } } if { $do_command } { if {[run_commands $prompt $command]} { incr exitval continue } } elseif { $do_script } { send "config paging disable\r" expect -re $prompt {} source $sfile catch {close}; } else { label $router log_user 1 interact } # End of for each router catch {wait}; sleep 0.3 } exit $exitval -------------- next part -------------- #! /usr/bin/perl ## ## Copyright (C) 1997-2004 by Terrapin Communications, Inc. ## All rights reserved. ## ## This software may be freely copied, modified and redistributed ## without fee for non-commerical purposes provided that this license ## remains intact and unmodified with any RANCID distribution. ## ## There is no warranty or other guarantee of fitness of this software. ## It is provided solely "as is". The author(s) disclaim(s) all ## responsibility and liability with respect to this software's usage ## or its effect upon hardware, computer systems, other software, or ## anything else. ## ## Except where noted otherwise, rancid was written by and is maintained by ## Henry Kilmer, John Heasley, Andrew Partan, Pete Whiting, and Austin Schutz. ## # # # Modified from ciscoips by Josh Yost # Created on 4/16/2008 # # This is meant to try handle Cisco's WLCs V4.X and on # # RANCID - Really Awesome New Cisco confIg Differ # # usage: ciscowlc [-d] [-l] [-f filename] [-r rawfile | $host] use Getopt::Std; getopts('df:lr:'); $log = $opt_l; $debug = $opt_d; $file = $opt_f; $rawfile = $opt_r; $host = $ARGV[0]; $clean_run = 0; $found_end = 0; $timeo = 90; # wlogin timeout in seconds my(@commandtable, %commands, @commands);# command lists my(%filter_pwds); # password filtering mode # This routine is used to print out the router configuration sub ProcessHistory { my($new_hist_tag,$new_command,$command_string, at string) = (@_); if ((($new_hist_tag ne $hist_tag) || ($new_command ne $command)) && defined %history) { print eval "$command \%history"; undef %history; } if (($new_hist_tag) && ($new_command) && ($command_string)) { if ($history{$command_string}) { $history{$command_string} = "$history{$command_string}@string"; } else { $history{$command_string} = "@string"; } } elsif (($new_hist_tag) && ($new_command)) { $history{++$#history} = "@string"; } else { print "@string"; } $hist_tag = $new_hist_tag; $command = $new_command; 1; } sub numerically { $a <=> $b; } # This is a sort routine that will sort numerically on the # keys of a hash as if it were a normal array. sub keynsort { local(%lines) = @_; local($i) = 0; local(@sorted_lines); foreach $key (sort numerically keys(%lines)) { $sorted_lines[$i] = $lines{$key}; $i++; } @sorted_lines; } # This is a sort routine that will sort on the # keys of a hash as if it were a normal array. sub keysort { local(%lines) = @_; local($i) = 0; local(@sorted_lines); foreach $key (sort keys(%lines)) { $sorted_lines[$i] = $lines{$key}; $i++; } @sorted_lines; } # This is a sort routine that will sort on the # values of a hash as if it were a normal array. sub valsort{ local(%lines) = @_; local($i) = 0; local(@sorted_lines); foreach $key (sort values %lines) { $sorted_lines[$i] = $key; $i++; } @sorted_lines; } # This is a numerical sort routine (ascending). sub numsort { local(%lines) = @_; local($i) = 0; local(@sorted_lines); foreach $num (sort {$a <=> $b} keys %lines) { $sorted_lines[$i] = $lines{$num}; $i++; } @sorted_lines; } # This is a sort routine that will sort on the # ip address when the ip address is anywhere in # the strings. sub ipsort { local(%lines) = @_; local($i) = 0; local(@sorted_lines); foreach $addr (sort sortbyipaddr keys %lines) { $sorted_lines[$i] = $lines{$addr}; $i++; } @sorted_lines; } # These two routines will sort based upon IP addresses sub ipaddrval { my(@a) = ($_[0] =~ m#^(\d+)\.(\d+)\.(\d+)\.(\d+)$#); $a[3] + 256 * ($a[2] + 256 * ($a[1] +256 * $a[0])); } sub sortbyipaddr { &ipaddrval($a) <=> &ipaddrval($b); } # This routine parses "show running-config" sub ShowConfig { print STDERR " In ShowConfig: $_" if ($debug); ProcessHistory("","","","\n!--WLC Begin Config Data--!\n\n"); $firstexit=0; while () { tr/\015//d; tr/\020//d; $skipprocess=0; #remove snmp community string data if (/^(\s*snmp community create)/ && $filter_pwds >= 1) { ProcessHistory("","","","!$1 \n"); next; } if (/^(\s*snmp community accessmode (ro|rw))/ && $filter_pwds >= 1) { ProcessHistory("","","","!$1 \n"); next; } if (/^(\s*snmp community ipaddr\s\S+\s\S+) / && $filter_pwds >= 1) { ProcessHistory("","","","!$1 \n"); next; } last if (/^$prompt/); next if (/^(\s*|\s*$cmd\s*)$/); if ( ! /^$prompt/) { if ( ! $skipprocess ) { print STDOUT " ShowConfig Data: $_" if ($debug); ProcessHistory("","","","$_"); } } } $clean_run=1; ProcessHistory("","","","\n!--WLC End Config Data--!\n"); print STDERR " Exiting ShowConfig: $_" if ($debug); return(0); } # This routine parses "show sysinfo" sub ShowSysinfo { print STDERR " In ShowSysinfo: $_" if ($debug); ProcessHistory("","","","\n!WLC Show Sysinfo Start\n!\n"); while () { tr/\015//d; $skipprocess=0; if ( /^System Up Time/ ) { $skipprocess=1; } if ( /^Number of Active Clients/ ) { $skipprocess=1; } if ( /^Internal Temperature/ ) { $skipprocess=1; } last if (/^$prompt/); next if (/^(\s*|\s*$cmd\s*)$/); if ( ! /^$prompt/) { if ( ! $skipprocess ) { print STDOUT " ShowSysinfo Data: $_" if ($debug); ProcessHistory("","","","! $_"); } } } ProcessHistory("","","","!\n!WLC Show Sysinfo End\n"); print STDERR " Exiting ShowSysinfo: $_" if ($debug); return(0); } # This routine parses "show udi" sub ShowUdi { print STDERR " In ShowUdi: $_" if ($debug); ProcessHistory("","","","\n!WLC Show Udi Start\n!\n"); while () { tr/\015//d; $skipprocess=0; last if (/^$prompt/); next if (/^(\s*|\s*$cmd\s*)$/); if ( ! /^$prompt/) { if ( ! $skipprocess ) { print STDOUT " ShowUdi Data: $_" if ($debug); ProcessHistory("","","","! $_"); } } } ProcessHistory("","","","!\n!WLC Show Udi End\n"); print STDERR " Exiting ShowSysinfo: $_" if ($debug); return(0); } # dummy function sub DoNothing {print STDOUT;} # Main @commandtable = ( {'show udi' => 'ShowUdi'}, {'show sysinfo' => 'ShowSysinfo'}, {'show run-config commands' => 'ShowConfig'} ); # Use an array to preserve the order of the commands and a hash for mapping # commands to the subroutine and track commands that have been completed. @commands = map(keys(%$_), @commandtable); %commands = map(%$_, @commandtable); $cisco_cmds = join(";", at commands); $cmds_regexp = join("|", map quotemeta($_), @commands); $file = "$host.new" unless $file; open(OUTPUT,">$file") || die "Can't open $file for writing: $!\n"; select(OUTPUT); # make OUTPUT unbuffered if debugging if ($debug) { $| = 1; } if ($rawfile) { print STDERR "opening file $rawfile\n" if ($debug); print STDOUT "opening file $rawfile\n" if ($log); open(INPUT,"<$rawfile") || die "open failed for $rawfile: $!\n"; } else { print STDERR "executing wlogin -t $timeo -c\"$cisco_cmds\" $host\n" if ($debug); print STDOUT "executing wlogin -t $timeo -c\"$cisco_cmds\" $host\n" if ($log); if (defined($ENV{NOPIPE})) { $rawfile = "$host.raw"; system "wlogin -t $timeo -c \"$cisco_cmds\" $host $rawfile 2>&1" || die "wlogin failed for $host: $!\n"; open(INPUT, "< $rawfile") || die "wlogin failed for $host: $!\n"; } else { open(INPUT,"wlogin -t $timeo -c \"$cisco_cmds\" $host ) { tr/\015//d; if (/[>#]\s?exit$/) { $clean_run = 1; last; } if (/^Error:/) { print STDOUT ("$host wlogin error: $_"); print STDERR ("$host wlogin error: $_") if ($debug); $clean_run = 0; last; } while (/>\s*($cmds_regexp)\s*$/) { $cmd = $1; if (!defined($prompt)) { $prompt = ($_ =~ /^([^#]+>)/)[0]; $prompt =~ s/([][}{)(\\])/\\$1/g; print STDERR ("PROMPT MATCH: $prompt\n") if ($debug); } print STDERR ("WLC COMMAND:$_") if ($debug); if (! defined($commands{$cmd})) { print STDERR "$host: found unexpected command - \"$cmd\"\n"; $clean_run = 0; last TOP; } $rval = &{$commands{$cmd}}; delete($commands{$cmd}); if ($rval == -1) { $clean_run = 0; last TOP; } } } print STDOUT "Done $logincmd: $_\n" if ($log); # Flush History ProcessHistory("","","",""); # Cleanup close(INPUT); close(OUTPUT); if (defined($ENV{NOPIPE})) { unlink($rawfile) if (! $debug); } # check for completeness if (scalar(%commands) || !$clean_run ) { if (scalar(%commands)) { printf(STDOUT "$host: missed cmd(s): %s\n", join(',', keys(%commands))); printf(STDERR "$host: missed cmd(s): %s\n", join(',', keys(%commands))) if ($debug); } if (!$clean_run ) { print STDOUT "$host: End of run not found\n"; print STDERR "$host: End of run not found\n" if ($debug); system("/usr/bin/tail -1 $file"); } unlink "$host.new" if (! $debug); } From CDeRemer at caron.org Mon Mar 12 12:18:31 2012 From: CDeRemer at caron.org (Chris DeRemer) Date: Mon, 12 Mar 2012 12:18:31 +0000 Subject: [rancid] --PossibleSpam-- : my scripts for Cisco WLC In-Reply-To: <20120307101522.GA3052@bobek.localdomain> References: <20120307101522.GA3052@bobek.localdomain> Message-ID: <2C6B540215FBC442AD3F68684AF747E209858593@EX10-MB01.caron.local> Zito, What version of code are you running on your WLC. I've found in the past that different versions of the code respond differently to the login scripts. Even intermediate versions from 5.1 to 5.2. Great work on this script! Cheers, Chris -----Original Message----- From: rancid-discuss-bounces at shrubbery.net [mailto:rancid-discuss-bounces at shrubbery.net] On Behalf Of V?clav Ovs?k Sent: Wednesday, March 07, 2012 5:15 AM To: rancid-discuss at shrubbery.net Subject: --PossibleSpam-- : [rancid] my scripts for Cisco WLC Importance: Low Hi, We have: (Cisco Controller) >show udi NAME: "Chassis" , DESCR: "Cisco Wireless Controller" PID: WS-C3750G-24WS-S25, VID: V02, SN: FOCxxxxxxx (Cisco Controller) >show sysinfo Manufacturer's Name.............................. Cisco Systems Inc. Product Name..................................... Cisco Controller Product Version.................................. 5.2.193.0 RTOS Version..................................... 5.2.193.0 Bootloader Version............................... 4.0.217.0 Emergency Image Version.......................... 5.2.157.0 ... This box has a prompt as show above `(Cisco Controller) >' and non standard command to disable paging: config paging disable so a standard clogin can't handle it. I found a post http://www.shrubbery.net/pipermail/rancid-discuss/2010-February/004652.html and start with attached wlogin and ciscowlc5, many thanks for this starting point to Jeremy. The original wlogin not used disabled paging and the stupid box did paging in the middle of the line. Fortunately I found the command above for disabling paging. After learning expect a bit :) I took original clogin from Rancid, strip down enable mode and apply the different prompt and command to disable paging. I modify a little ciscowlc5, so it can be used with http://sites.google.com/site/jrbinks/code/rancid/wraprancid. My versions of files wlogin and ciscowlc5 are attached. Hope it can be useful for someone. I'm not subscribed on this list, so keep me in the Cc please if I should receive a reply.. Regards -- Zito From paolo at paolodemichele.it Mon Mar 12 18:16:06 2012 From: paolo at paolodemichele.it (Paolo De Michele) Date: Mon, 12 Mar 2012 19:16:06 +0100 Subject: [rancid] - problem sending mail and matching configuration In-Reply-To: <20120310163457.GC8136@shrubbery.net> References: <4F59E720.4020404@paolodemichele.it> <4F5A0F26.6030300@paolodemichele.it> <20120309170130.GI86937@shrubbery.net> <4F5B5E4D.2010705@paolodemichele.it> <20120310163457.GC8136@shrubbery.net> Message-ID: <4F5E3D66.8090801@paolodemichele.it> hi heasley, On 03/10/2012 05:34 PM, heasley wrote: > Sat, Mar 10, 2012 at 02:59:41PM +0100, Paolo De Michele: >> hi heasley, >> >> thank you for your reply >> >> >> >> On 03/09/2012 06:01 PM, heasley wrote: >>>>> using rancid 2.3.8 with os ubuntu 11.04 server. >>>>> I did the various configurations and are quite happy with it. >>>>> My problem is that when software rancid makes a matching configuration creates a new file. >>>>> >>>>> What I would do is this: >>>>> - create a file when the new configuration is detected ( OK ) >>>>> - send me an email with the changes detected in the new configuration >>>>> >>>>> I failed in any way using /etc/aliases and sendmail to send a mail to an address of a royal domain. >>>>> can you help me somehow? >>> diffs are sent to rancid-. you should test sending email >>> to that alias. administrative messages are send to rancid-admin->> name>; so test that alias too. >>> >>> If you can not get these aliases to work, refer to the mail lists or forums >>> that are for support of whatever you are using for you MTA, whether that is >>> sendmail or postfix. >>> >>> if that does work; then look in the rancid logs files for errors. >> You can have a config example file/etc/aliases? > that is specific to your MTA and what you want to do. look for an aliases(5) > manpage. I solved the problem with the provision of mail. I have configured postfix as an agent and now are sent correctly how do I send mails when rancid find differences in configurations? thanks in advance -------------- next part -------------- An HTML attachment was scrubbed... URL: From paolo at paolodemichele.it Tue Mar 13 08:36:25 2012 From: paolo at paolodemichele.it (Paolo De Michele) Date: Tue, 13 Mar 2012 09:36:25 +0100 Subject: [rancid] - problem sending mail and matching configuration In-Reply-To: <20120312215840.GI61990@shrubbery.net> References: <4F59E720.4020404@paolodemichele.it> <4F5A0F26.6030300@paolodemichele.it> <20120309170130.GI86937@shrubbery.net> <4F5B5E4D.2010705@paolodemichele.it> <20120310163457.GC8136@shrubbery.net> <4F5E3D66.8090801@paolodemichele.it> <20120312215840.GI61990@shrubbery.net> Message-ID: <4F5F0709.2060207@paolodemichele.it> hi heasley, On 03/12/2012 10:58 PM, heasley wrote: > Mon, Mar 12, 2012 at 07:16:06PM +0100, Paolo De Michele: >> how do I send mails when rancid find differences in configurations? > see rancid_intro(1) man-page and the README that came with the rancid dist > for the aliases. the problem is solved. thanks for your cooperation -------------- next part -------------- An HTML attachment was scrubbed... URL: From brodard.anthony at gmail.com Tue Mar 13 11:44:35 2012 From: brodard.anthony at gmail.com (Anthony BRODARD) Date: Tue, 13 Mar 2012 12:44:35 +0100 Subject: [rancid] End of run not found Message-ID: Hi list, For one host only, i have this error : Trying to get all of the configs. 192.168.1.1: End of run not found I can make a "show clock" with clogin : $ /usr/lib/rancid/bin/clogin -t 30 -c "show clock" 192.168.1.1 192.168.1.1 spawn telnet 192.168.1.1 Trying 192.168.1.1... Connected to 192.168.1.1. Escape character is '^]'. User Access Verification Username: admin Password: router> router>terminal length 0 router>show clock 12:08:29.591 CET Tue Mar 13 2012 router>exit Connection closed by foreign host. Backup had already worked fine with rancid. Have you any idea to solve my problem ? I don't think that it's a rancid configuration mistake, because clogin works fine with this router. Regards, Anthony -------------- next part -------------- An HTML attachment was scrubbed... URL: From me_gogorza at hotmail.com Tue Mar 13 17:58:26 2012 From: me_gogorza at hotmail.com (Marito ...) Date: Tue, 13 Mar 2012 14:58:26 -0300 Subject: [rancid] password In-Reply-To: References: , , Message-ID: You should change your XXrancid. Search the lines that contains (you will find lines for username, ospf, etc), and modify the if statement. I have not done it,so I am not sure at all how to change it, but I can assure that there you will make it work as you need/want. Regards. > From: bha.Qaqish at NITC.gov.jo > To: me_gogorza at hotmail.com; rancid-discuss at shrubbery.net > Date: Fri, 9 Mar 2012 15:53:11 +0200 > Subject: RE: [rancid] password > > hi > thank you for he response > i have one more question > can i modify that some of the password appear and some not. > is there any way to do that ( anyone have a way) > for example to hide the bgp password and show all the password , do you have any example > > > Regards > > > > > ________________________________________ > From: Marito ... [me_gogorza at hotmail.com] > Sent: Friday, March 09, 2012 3:40 PM > To: bha Qaqish; rancid-discuss at shrubbery.net > Subject: RE: [rancid] password > > Hi, > > At etc/rancid.conf, you need to change : > > # FILTER_PWDS determines which passwords are filtered from configs by the > # value set (NO | YES | ALL). see rancid.conf(5). > FILTER_PWDS=NO; export FILTER_PWDS > > This applies for all rancid scripts. > > Regards., > > > From: bha.Qaqish at NITC.gov.jo > > To: rancid-discuss at shrubbery.net > > Date: Fri, 9 Mar 2012 15:12:10 +0200 > > Subject: [rancid] password > > > > Dear > > i using rancid for 2 month > > and i check the config from the GUI , and i found > > line vty 0 4 > > password > > > > how can i appear the password . > > i do not want to hide it > > > > BR > > BHA QAQISH > > _______________________________________________ > > Rancid-discuss mailing list > > Rancid-discuss at shrubbery.net > > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss -------------- next part -------------- An HTML attachment was scrubbed... URL: From sbarnard at krollfactualdata.com Tue Mar 13 18:48:36 2012 From: sbarnard at krollfactualdata.com (Barnard, Samuel) Date: Tue, 13 Mar 2012 18:48:36 +0000 Subject: [rancid] rancid-run cront job does not work with F5, but rancid-run -r does. Message-ID: <5F95420E594F4C4388CEC60A35230EF62E136A29@LV1UNEXMB01.corp.factualdata.com> Rancid-Discuss: My F5s are on version 10.0.0.1 I have a crontab job that runs twice a night (yes the times are right): 0 0,3 * * * /opt/rancid/bin/rancid-run It works just fine for every cisco device, however for the F5 Devices it complains about the following: Getting missed routers: round 4. F5a: missed cmd(s): ls --full-time --color=never /config/ssl/ssl.crt,ls --full-time --color=never /config/ssl/ssl.key F5b: missed cmd(s): ls --full-time --color=never /config/ssl/ssl.crt,ls --full-time --color=never /config/ssl/ssl.key However when I run the command: Rancid-run -r F5a The device works just fine: cvs diff: Diffing . cvs diff: Diffing configs cvs commit: Examining . cvs commit: Examining configs Checking in configs/F5a; /opt/rancid/var/CVS/kfd/configs/F5a,v <-- F5a new revision: 1.5; previous revision: 1.4 done I cannot figure out what the problem seems to be when it does the full rancid-run job. Running a f5rancid manually runs all the commands just fine as well. Does anyone have any insight? Thank you, Sam Barnard, IT Specialist - Network [Description: Description: Description: Description: cid:image001.jpg at 01CBBBD4.3E04E480] sbarnard at krollfactualdata.com www.krollfactualdata.com -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image001.jpg Type: image/jpeg Size: 1826 bytes Desc: image001.jpg URL: From krzysztof.zygmunt at gmail.com Wed Mar 14 08:08:42 2012 From: krzysztof.zygmunt at gmail.com (Krzysztof Zygmunt) Date: Wed, 14 Mar 2012 09:08:42 +0100 Subject: [rancid] F5 BIG-IP devices - any tricks? In-Reply-To: References: Message-ID: " Hopefully we can provide 'full shell, read only' somehow. " Has anyone managed to do that ? (full shell, read only access) or access using sudo ? This is (full shell access) the only thing that keeps us not using rancid for bigips. On Fri, Jan 13, 2012 at 12:06 AM, Dale Shaw wrote: > Hi Lance, > > On Fri, Jan 13, 2012 at 1:16 AM, Lance Vermilion wrote: >> In the? F5 you need to change the setting under the user so they will get a >> full shell > > Thanks, yeah, that does appear to be the issue -- f5rancid/clogin > expect to be dropped into a full shell. We discovered yesterday (after > posting to the list) that using the 'root' user results in working > RANCID. > > On the surface it seemed that all we needed to do was figure out a way > to disable the pager on a per-session basis within the bigpipe shell. > That still seems like the cleanest way to make this work to me. > > Anyway, I'll work with the folks more familiar with the operation of > the F5s to figure out how we provide 'full shell' access to the user > RANCID uses. Hopefully we can provide 'full shell, read only' somehow. > > Cheers, > Dale > _______________________________________________ > Rancid-discuss mailing list > Rancid-discuss at shrubbery.net > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss From mwlucas at blackhelicopters.org Thu Mar 15 23:28:44 2012 From: mwlucas at blackhelicopters.org (Michael W. Lucas) Date: Thu, 15 Mar 2012 19:28:44 -0400 Subject: [rancid] mtlogin script error Message-ID: <20120315232844.GA79115@bewilderbeast.blackhelicopters.org> Hi, Following the newest RouterOS upgrades, RANCID is having trouble getting router info. If I try a single command with clogin -c"command" hostname, the connection works, but the logout fails. "exit" is no longer a valid logout command on RouterOS; only "quit" works. Is there a way to easily switch the logout command? I've appended my clogin output below. The "mikrotiklogin.sh" script is just: #!/bin/sh exec ssh -p 2222 $@ Thanks, ==ml % clogin -t 15 -c"system license print" barn barn spawn /usr/local/scripts/microtiklogin.sh -c 3des -x -l admin+ct barn admin+ct at barn.lodden.com's password: MMM MMM KKK TTTTTTTTTTT KKK MMMM MMMM KKK TTTTTTTTTTT KKK MMM MMMM MMM III KKK KKK RRRRRR OOOOOO TTT III KKK KKK MMM MM MMM III KKKKK RRR RRR OOO OOO TTT III KKKKK MMM MMM III KKK KKK RRRRRR OOO OOO TTT III KKK KKK MMM MMM III KKK KKK RRR RRR OOOOOO TTT III KKK KKK MikroTik RouterOS 5.11 (c) 1999-2011 http://www.mikrotik.com/ [admin at LODDENTOWER] > [admin at LODDENTOWER] > terminal length 0 bad command name length (line 1 column 10) [admin at LODDENTOWER] > system license print software-id: 70LA-H4WP upgradable-to: v6.x nlevel: 4 features: [admin at LODDENTOWER] >exit bad command name exit (line 1 column 1) [admin at LODDENTOWER] > exit bad command name exit (line 1 column 1) [admin at LODDENTOWER] > exit bad command name exit (line 1 column 1) [admin at LODDENTOWER] > ^C% -- Michael W. Lucas http://www.MichaelWLucas.com/, http://blather.MichaelWLucas.com/ Latest book: SSH Mastery http://www.michaelwlucas.com/nonfiction/ssh-mastery mwlucas at BlackHelicopters.org, Twitter @mwlauthor From bobthebaritone at gmail.com Fri Mar 16 01:05:30 2012 From: bobthebaritone at gmail.com (bob watson) Date: Fri, 16 Mar 2012 12:05:30 +1100 Subject: [rancid] mtlogin script error In-Reply-To: <20120315232844.GA79115@bewilderbeast.blackhelicopters.org> References: <20120315232844.GA79115@bewilderbeast.blackhelicopters.org> Message-ID: Really easy - in the bottom of the rancid perl code - main loop - you'll see where it checks for exit - change that to quit! You will need to change similar entries in the login expect script. Cheers Bob On 16 March 2012 10:28, Michael W. Lucas wrote: > Hi, > > Following the newest RouterOS upgrades, RANCID is having trouble > getting router info. > > If I try a single command with clogin -c"command" hostname, the > connection works, but the logout fails. "exit" is no longer a valid > logout command on RouterOS; only "quit" works. > > Is there a way to easily switch the logout command? > > I've appended my clogin output below. ?The "mikrotiklogin.sh" script is just: > > #!/bin/sh > exec ssh -p 2222 $@ > > Thanks, > ==ml > > % clogin -t 15 -c"system license print" barn > barn > spawn /usr/local/scripts/microtiklogin.sh -c 3des -x -l admin+ct barn > admin+ct at barn.lodden.com's password: > > > > > > > > > ?MMM ? ? ?MMM ? ? ? KKK ? ? ? ? ? ? ? ? ? ? ? ? ?TTTTTTTTTTT ? ? ?KKK > ?MMMM ? ?MMMM ? ? ? KKK ? ? ? ? ? ? ? ? ? ? ? ? ?TTTTTTTTTTT ? ? ?KKK > ?MMM MMMM MMM ?III ?KKK ?KKK ?RRRRRR ? ? OOOOOO ? ? ?TTT ? ? III ?KKK ?KKK > ?MMM ?MM ?MMM ?III ?KKKKK ? ? RRR ?RRR ?OOO ?OOO ? ? TTT ? ? III ?KKKKK > ?MMM ? ? ?MMM ?III ?KKK KKK ? RRRRRR ? ?OOO ?OOO ? ? TTT ? ? III ?KKK KKK > ?MMM ? ? ?MMM ?III ?KKK ?KKK ?RRR ?RRR ? OOOOOO ? ? ?TTT ? ? III ?KKK ?KKK > > ?MikroTik RouterOS 5.11 (c) 1999-2011 ? ? ? http://www.mikrotik.com/ > > [admin at LODDENTOWER] > > [admin at LODDENTOWER] > terminal length 0 > bad command name length (line 1 column 10) > [admin at LODDENTOWER] > ?system license print > ? ?software-id: 70LA-H4WP > ?upgradable-to: v6.x > ? ? ? ? nlevel: 4 > ? ? ? features: > [admin at LODDENTOWER] >exit > bad command name exit (line 1 column 1) > [admin at LODDENTOWER] > exit > bad command name exit (line 1 column 1) > [admin at LODDENTOWER] > exit > bad command name exit (line 1 column 1) > [admin at LODDENTOWER] > ^C% > > > > -- > Michael W. Lucas > http://www.MichaelWLucas.com/, http://blather.MichaelWLucas.com/ > Latest book: SSH Mastery http://www.michaelwlucas.com/nonfiction/ssh-mastery > mwlucas at BlackHelicopters.org, Twitter @mwlauthor > _______________________________________________ > Rancid-discuss mailing list > Rancid-discuss at shrubbery.net > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss From froztbyte at froztbyte.net Fri Mar 16 05:51:22 2012 From: froztbyte at froztbyte.net (JP Viljoen) Date: Fri, 16 Mar 2012 07:51:22 +0200 Subject: [rancid] mtlogin script error In-Reply-To: <20120315232844.GA79115@bewilderbeast.blackhelicopters.org> References: <20120315232844.GA79115@bewilderbeast.blackhelicopters.org> Message-ID: <21109ac7f13fd6254e449e4ed56a6597@froztbyte.net> On Thu, 15 Mar 2012 19:28:44 -0400, "Michael W. Lucas" wrote: > Hi, > > Following the newest RouterOS upgrades, RANCID is having trouble > getting router info. Hi Not that I can really help with this issue directly, but I've recently written a post covering another method for using Rancid with Mikrotik routers. You can find it here: http://blog.froztbyte.net/2012/03/mikrotik-and-rancid/. -J From stefan.jakob at de-cix.net Fri Mar 16 10:24:53 2012 From: stefan.jakob at de-cix.net (Stefan Jakob) Date: Fri, 16 Mar 2012 11:24:53 +0100 Subject: [rancid] arrancid (2.3.4) - ignore bytes free in ShowFlash Message-ID: <4F6314F5.9060203@de-cix.net> Hi rancid list, Is it rancid style to ignore the output of bytes free in sub ShowFlash of arrancid? Versions: arrancid: rancid 2.3.4, Debian Squeeze EOS: Software image version: 4.8.3, Arista DCS-7124SX-F Looks like Arista stores some ntp drift info on a regular base to the flash: bash-4.0# pwd /mnt/flash/persist bash-4.0# ls -ls -rtl total 20 12 -rwxrwx--- 1 root eosadmin 10240 Mar 14 12:07 sys 8 -rwxrwx--- 1 root eosadmin 5120 Mar 16 08:12 local Guess this causes arrancid to "see" a diff in ShowFlash everytime this happens. Guess this is just noise? - !Flash: 1779585024 bytes total (1318834176 bytes free) + !Flash: 1779585024 bytes total (1318830080 bytes free) @Arista: Why not in tmpfs? This might hurt the flash. If there is ntp configured, this shouldn't matter to lose the drift info, after a reboot. I checked 2.3.8, but can't really see, that it's parsed diffrent So is it possible to ignore the line? Rgds, SJ From heruan at aldu.net Mon Mar 19 10:33:30 2012 From: heruan at aldu.net (Giovanni Lovato) Date: Mon, 19 Mar 2012 11:33:30 +0100 Subject: [rancid] 3Com 4400 TFTP Message-ID: Hi all! I'm trying Rancid to backup 3Com 4400 switches configurations. I can successfully login via telnet, then I need to configure Rancid to run the command "system backupConfig save backupConfig" and expect for the "Save of system configuration successful" message to retrieve the contents of "/srv/tftp/". It's very straightforward but I don't know Perl. Maybe someone has already done something like this? Thank you very much! From tyler at tolaris.com Mon Mar 19 11:12:59 2012 From: tyler at tolaris.com (Tyler J. Wagner) Date: Mon, 19 Mar 2012 11:12:59 +0000 Subject: [rancid] 3Com 4400 TFTP In-Reply-To: References: Message-ID: <4F6714BB.4010506@tolaris.com> There is a plugin which may cover the 4400, or may need modifying to do so: https://sites.google.com/site/jrbinks/code/rancid/h3c Another person did it without rancid: http://thebackroomtech.com/2008/06/05/howto-export-3com-4xxx-family-switch-configurations-to-a-text-file-for-backup-and-change-management/ Regards, Tyler On 2012-03-19 10:33, Giovanni Lovato wrote: > Hi all! > I'm trying Rancid to backup 3Com 4400 switches configurations. > I can successfully login via telnet, then I need to configure Rancid to > run the command "system backupConfig save > backupConfig" and expect for the "Save of system configuration successful" > message to retrieve the contents of "/srv/tftp/". > It's very straightforward but I don't know Perl. Maybe someone has already > done something like this? > > Thank you very much! > > _______________________________________________ > Rancid-discuss mailing list > Rancid-discuss at shrubbery.net > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss > -- "It is wrong to think that the task of physics is to find out how nature is. Physics concerns what we can say about nature." -- Niels Bohr From jethro.binks at strath.ac.uk Mon Mar 19 11:25:34 2012 From: jethro.binks at strath.ac.uk (Jethro R Binks) Date: Mon, 19 Mar 2012 11:25:34 +0000 (GMT) Subject: [rancid] 3Com 4400 TFTP In-Reply-To: <4F6714BB.4010506@tolaris.com> References: <4F6714BB.4010506@tolaris.com> Message-ID: On Mon, 19 Mar 2012, Tyler J. Wagner wrote: > On 2012-03-19 10:33, Giovanni Lovato wrote: > > Hi all! > > I'm trying Rancid to backup 3Com 4400 switches configurations. > > I can successfully login via telnet, then I need to configure Rancid to > > run the command "system backupConfig save > > backupConfig" and expect for the "Save of system configuration successful" > > message to retrieve the contents of "/srv/tftp/". > > It's very straightforward but I don't know Perl. Maybe someone has already > > done something like this? > > There is a plugin which may cover the 4400, or may need modifying to do so: > > https://sites.google.com/site/jrbinks/code/rancid/h3c No; that is only for later 3Com products with/as H3C, products derived from Huawei (and products now branded as part of HP Networking's range). The 4400 is part of the traditional Comware Superstack heritage which goes back through the 4200, 3300, 1100, PSHub50 and so on. I modified Michael Stefaniuc wrancid to create wraprancid partly with these products in mind: https://sites.google.com/site/jrbinks/code/rancid/wraprancid however in the end I never actually bothered to write the plugin required to do the tftp part. I still have some of switches, but I doubt I will have time to write the wraprancid plugin. Jethro. . . . . . . . . . . . . . . . . . . . . . . . . . Jethro R Binks, Network Manager, Information Services Directorate, University Of Strathclyde, Glasgow, UK The University of Strathclyde is a charitable body, registered in Scotland, number SC015263. From jeff.magneto417x at gmail.com Mon Mar 19 12:17:52 2012 From: jeff.magneto417x at gmail.com (Jeff) Date: Mon, 19 Mar 2012 08:17:52 -0400 Subject: [rancid] Rancid Message-ID: I need to advice on how to poll my Dell Powerconnect switch with rancid 2.3.2. Any help would be greatly appreciated. Thanks +++---- Magneto the Master of Magnetism ----+++ -------------- next part -------------- An HTML attachment was scrubbed... URL: From rwest at zyedge.com Mon Mar 19 12:51:51 2012 From: rwest at zyedge.com (Ryan West) Date: Mon, 19 Mar 2012 12:51:51 +0000 Subject: [rancid] Rancid In-Reply-To: References: Message-ID: <5DC4853C6CC3EE4788779E0726E034DD01097CB9@zy-ex1.zyedge.local> On Mon, Mar 19, 2012 at 08:17:52, Jeff wrote: > Subject: [rancid] Rancid > > I need to advice on how to poll my Dell Powerconnect switch with > rancid 2.3.2. Any help would be greatly appreciated. Thanks Have you checked out drancid/dlogin? -ryan From heas at shrubbery.net Tue Mar 20 22:43:27 2012 From: heas at shrubbery.net (heasley) Date: Tue, 20 Mar 2012 22:43:27 +0000 Subject: [rancid] mtlogin script error In-Reply-To: References: <20120315232844.GA79115@bewilderbeast.blackhelicopters.org> Message-ID: <20120320224327.GH39349@shrubbery.net> Fri, Mar 16, 2012 at 12:05:30PM +1100, bob watson: > Really easy - in the bottom of the rancid perl code - main loop - > you'll see where it checks for exit - change that to quit! > > You will need to change similar entries in the login expect script. the original from Chris Boot that is in the current dist already uses quit. From heas at shrubbery.net Tue Mar 20 23:53:29 2012 From: heas at shrubbery.net (heasley) Date: Tue, 20 Mar 2012 23:53:29 +0000 Subject: [rancid] arrancid (2.3.4) - ignore bytes free in ShowFlash In-Reply-To: <20120320235150.41A9388ADA@guelah.shrubbery.net> <4F6314F5.9060203@de-cix.net> Message-ID: <20120320235329.GL39349@shrubbery.net> Fri, Mar 16, 2012 at 11:24:53AM +0100, Stefan Jakob: > Hi rancid list, > > Is it rancid style to ignore the output of bytes free in sub ShowFlash > of arrancid? > > Versions: > > arrancid: rancid 2.3.4, Debian Squeeze > EOS: Software image version: 4.8.3, Arista DCS-7124SX-F > > > Looks like Arista stores some ntp drift info on a regular base to the flash: > > happens. Guess this is just noise? until it gets to zero? > - !Flash: 1779585024 bytes total (1318834176 bytes free) > + !Flash: 1779585024 bytes total (1318830080 bytes free) > > @Arista: Why not in tmpfs? This might hurt the flash. If there is ntp > configured, this shouldn't matter to lose the drift info, after a reboot. for XR, it summarized as follows. does this work for arista? Index: bin/arrancid.in =================================================================== --- bin/arrancid.in (revision 2431) +++ bin/arrancid.in (working copy) @@ -304,6 +304,21 @@ # persist changes constantly if you're running ntp, so # skip its updates. /\spersist$/ && next; + + if (/.*\((\d+) bytes free\)/) { + my($tmp) = $1; + if ($tmp >= (1024 * 1024 * 1024)) { + $tmp = int($tmp / (1024 * 1024 * 1024)); + s/$1 bytes free/$tmp GB free/; + } elsif ($tmp >= (1024 * 1024)) { + $tmp = int($tmp / (1024 * 1024)); + s/$1 bytes free/$tmp MB free/; + } else { + $tmp = int($tmp / 1024); + s/$1 bytes free/$tmp KB free/; + } + } + ProcessHistory("FLASH","","","!Flash: $_"); } ProcessHistory("","","","!\n"); From shain.singh at gmail.com Wed Mar 21 08:58:40 2012 From: shain.singh at gmail.com (Shain Singh) Date: Wed, 21 Mar 2012 19:58:40 +1100 Subject: [rancid] F5 BIG-IP devices - any tricks? In-Reply-To: References: Message-ID: > Has anyone managed to do that ? (full shell, read only access) or > access using sudo ? I'd say it may be easier trying to write another Expect script to use the tmsh instead. Makes it future proof as I believe F5 is heading away from giving complete shell access to their devices. -- Shaineel Singh e: shain.singh at gmail.com p: +61 422 921 951 w: http://buffet.shainsingh.com -- "Too many have dispensed with generosity to practice charity" - Albert Camus From cico5 at gmx.de Wed Mar 21 16:01:14 2012 From: cico5 at gmx.de (=?iso-8859-1?Q?=22Ingo_Sch=FC=DFler=22?=) Date: Wed, 21 Mar 2012 17:01:14 +0100 Subject: [rancid] Fwd: Re: HP VC Flex-10 and rancid Message-ID: <20120321160114.77100@gmx.net> Hi, see the question below. May someone can help me!? BR -------- Original-Nachricht -------- Datum: Wed, 21 Mar 2012 14:41:49 +0000 Von: heasley An: "\\"Ingo Sch??ler\\"" CC: rancid at shrubbery.net Betreff: Re: HP VC Flex-10 and rancid Wed, Mar 21, 2012 at 11:12:24AM +0100, "Ingo Sch??ler": > Hi *, > > does anyone of you know how to backup the HP virtual connect switches with rancid. I do not know anything about these. you can try the hp device type, or find out if they are an OEM of some other device supported by the existing scripts. else, you should ask on rancid-discuss@ > BR > -- > NEU: FreePhone 3-fach-Flat mit kostenlosem Smartphone! > Jetzt informieren: http://mobile.1und1.de/?ac=OM.PW.PW003K20328T7073a -- NEU: FreePhone 3-fach-Flat mit kostenlosem Smartphone! Jetzt informieren: http://mobile.1und1.de/?ac=OM.PW.PW003K20328T7073a From krzysztof.zygmunt at gmail.com Thu Mar 22 16:57:46 2012 From: krzysztof.zygmunt at gmail.com (Krzysztof Zygmunt) Date: Thu, 22 Mar 2012 17:57:46 +0100 Subject: [rancid] Fwd: Re: HP VC Flex-10 and rancid In-Reply-To: <20120321160114.77100@gmx.net> References: <20120321160114.77100@gmx.net> Message-ID: as far as I recall, there is no way to backup vc configs using rancid they use Virtual Connect Support Utility to make backups, and the backup files are binary ? you use this util like this: vcutil -a configbackup -i -u -p -vcu - vcp from windows management station On Wed, Mar 21, 2012 at 5:01 PM, "Ingo Sch??ler" wrote: > Hi, > > see the question below. May someone can help me!? > > BR > > -------- Original-Nachricht -------- > Datum: Wed, 21 Mar 2012 14:41:49 +0000 > Von: heasley > An: "\\"Ingo Sch??ler\\"" > CC: rancid at shrubbery.net > Betreff: Re: HP VC Flex-10 and rancid > > Wed, Mar 21, 2012 at 11:12:24AM +0100, "Ingo Sch??ler": >> Hi *, >> >> does anyone of you know how to backup the HP virtual connect switches with rancid. > > I do not know anything about these. ?you can try the hp device type, or find > out if they are an OEM of some other device supported by the existing scripts. > else, you should ask on rancid-discuss@ > >> BR >> -- >> NEU: FreePhone 3-fach-Flat mit kostenlosem Smartphone! >> Jetzt informieren: http://mobile.1und1.de/?ac=OM.PW.PW003K20328T7073a > > -- > NEU: FreePhone 3-fach-Flat mit kostenlosem Smartphone! > Jetzt informieren: http://mobile.1und1.de/?ac=OM.PW.PW003K20328T7073a > _______________________________________________ > Rancid-discuss mailing list > Rancid-discuss at shrubbery.net > http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss From skyeh at uidaho.edu Sat Mar 24 18:41:21 2012 From: skyeh at uidaho.edu (Skye Hagen) Date: Sat, 24 Mar 2012 11:41:21 -0700 Subject: [rancid] SNMP community string not being removed (ASA/PIX/FWSM) Message-ID: I am running RANCID 2.3.6, and noticed that the snmp community string was not being removed on certain lines from our Firewall Services Module (FWSM) configs. The specific line was 'snmp-server host outside 10.10.196.238 poll community '. I checked, and it doesn?t look like this bug was fixed in 2.3.8. There is no Cisco Command Lookup Tool for the FWSM directly, however it is based on older versions of the PIX/ASA commands. For ASA version 7.x and lower, the format of the command is 'snmp-server host interface_name ip_address [trap | poll] [community text] [version {1 | 2c}] [udp-port port] '. For ASA version 8.x and higher, the format changed a little. It is 'snmp-server host {interface {hostname | ip_address}} [trap | poll] [community 0 | 8 community-string] [version {1 | 2c | 3 username}] [udp-port port] '. To cover both of these formats, I changed this section of rancid from... if (/^(snmp-server community) (\S+)/) { if ($filter_commstr) { ProcessHistory("SNMPSERVERCOMM","keysort","$_", "!$1 $'") && next; } else { ProcessHistory("SNMPSERVERCOMM","keysort","$_","$_") && next; } } To... if (/^(snmp-server .*community) ([08] )?(\S+)/) { if ($filter_commstr) { ProcessHistory("SNMPSERVERCOMM","keysort","$_", "!$1 $2$'") && next; } else { ProcessHistory("SNMPSERVERCOMM","keysort","$_","$_") && next; } } I don't have an ASA 8.x device, so I couldn't test this with a real config. It worked when I dummied up an ASA config, and it works with my FWSM configs. Skye. -------------- next part -------------- An HTML attachment was scrubbed... URL: From remyheiden at gmail.com Mon Mar 26 14:58:01 2012 From: remyheiden at gmail.com (Remy Heiden) Date: Mon, 26 Mar 2012 16:58:01 +0200 Subject: [rancid] password In-Reply-To: References: Message-ID: Marito, If you do change the XXrancid script, please remember to make a backup of both the original and the modified files, so you can replace or re-modify the script at any time. (Especially after an update of RANCID). Kind Regards, Remy Heiden === -------------- next part -------------- An HTML attachment was scrubbed... URL: From istong at costar.com Mon Mar 26 19:06:06 2012 From: istong at costar.com (Ian Stong) Date: Mon, 26 Mar 2012 19:06:06 +0000 Subject: [rancid] Re: F5 load balancer support Message-ID: <6ED7B4C44A4C234FA7427C0BFDF35A3216031F4B@DCMBXPRD100.us.costar.local> When I execute rancid -d or f5login it shows the following then a ton of errors "Unknown option: t" executing f5login -t 90 -c"TERM=xterm;export TERM;bigpipe platform;bigpipe version;bigpipe list;bigpipe base list;bigpipe route static show;ls --full-time --color=never /config/ssl/ssl.crt;ls --full-time --color=never /config/ssl/ssl.key" 10.20.30.1 Any ideas and can someone send their working F5 script for a 9.x version? Thanks, Ian -------------- next part -------------- An HTML attachment was scrubbed... URL: From rwest at zyedge.com Mon Mar 26 19:24:03 2012 From: rwest at zyedge.com (Ryan West) Date: Mon, 26 Mar 2012 19:24:03 +0000 Subject: [rancid] F5 load balancer support In-Reply-To: <6ED7B4C44A4C234FA7427C0BFDF35A3216031F4B@DCMBXPRD100.us.costar.local> References: <6ED7B4C44A4C234FA7427C0BFDF35A3216031F4B@DCMBXPRD100.us.costar.local> Message-ID: Try commenting out the ls commands in the command table. Sent from handheld On Mar 26, 2012, at 3:09 PM, "Ian Stong" > wrote: When I execute rancid ?d or f5login it shows the following then a ton of errors ?Unknown option: t? executing f5login -t 90 -c"TERM=xterm;export TERM;bigpipe platform;bigpipe version;bigpipe list;bigpipe base list;bigpipe route static show;ls --full-time --color=never /config/ssl/ssl.crt;ls --full-time --color=never /config/ssl/ssl.key" 10.20.30.1 Any ideas and can someone send their working F5 script for a 9.x version? Thanks, Ian _______________________________________________ Rancid-discuss mailing list Rancid-discuss at shrubbery.net http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss -------------- next part -------------- An HTML attachment was scrubbed... URL: From istong at costar.com Mon Mar 26 19:27:23 2012 From: istong at costar.com (Ian Stong) Date: Mon, 26 Mar 2012 19:27:23 +0000 Subject: [rancid] F5 load balancer support In-Reply-To: References: <6ED7B4C44A4C234FA7427C0BFDF35A3216031F4B@DCMBXPRD100.us.costar.local> Message-ID: <6ED7B4C44A4C234FA7427C0BFDF35A3216031F9F@DCMBXPRD100.us.costar.local> No luck with that. I do see an f5login -t section in the script and believe it's failing on that but not sure what to do about it. Thanks, Ian From: Ryan West [mailto:rwest at zyedge.com] Sent: Monday, March 26, 2012 3:24 PM To: Ian Stong Cc: rancid-discuss at shrubbery.net Subject: Re: [rancid] Re: F5 load balancer support Try commenting out the ls commands in the command table. Sent from handheld On Mar 26, 2012, at 3:09 PM, "Ian Stong" > wrote: When I execute rancid -d or f5login it shows the following then a ton of errors "Unknown option: t" executing f5login -t 90 -c"TERM=xterm;export TERM;bigpipe platform;bigpipe version;bigpipe list;bigpipe base list;bigpipe route static show;ls --full-time --color=never /config/ssl/ssl.crt;ls --full-time --color=never /config/ssl/ssl.key" 10.20.30.1 Any ideas and can someone send their working F5 script for a 9.x version? Thanks, Ian _______________________________________________ Rancid-discuss mailing list Rancid-discuss at shrubbery.net http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss -------------- next part -------------- An HTML attachment was scrubbed... URL: From rwest at zyedge.com Mon Mar 26 21:04:41 2012 From: rwest at zyedge.com (Ryan West) Date: Mon, 26 Mar 2012 21:04:41 +0000 Subject: [rancid] F5 load balancer support In-Reply-To: <6ED7B4C44A4C234FA7427C0BFDF35A3216031F9F@DCMBXPRD100.us.costar.local> References: <6ED7B4C44A4C234FA7427C0BFDF35A3216031F4B@DCMBXPRD100.us.costar.local> <6ED7B4C44A4C234FA7427C0BFDF35A3216031F9F@DCMBXPRD100.us.costar.local> Message-ID: <5DC4853C6CC3EE4788779E0726E034DD010CAA62@zy-ex1.zyedge.local> Ian, My install uses clogin and f5rancid, I do not have an f5login. The -t is for timeout. -ryan From: Ian Stong [mailto:istong at costar.com] Sent: Monday, March 26, 2012 3:27 PM To: Ryan West Cc: rancid-discuss at shrubbery.net Subject: RE: [rancid] Re: F5 load balancer support No luck with that. I do see an f5login -t section in the script and believe it's failing on that but not sure what to do about it. Thanks, Ian From: Ryan West [mailto:rwest at zyedge.com] Sent: Monday, March 26, 2012 3:24 PM To: Ian Stong Cc: rancid-discuss at shrubbery.net Subject: Re: [rancid] Re: F5 load balancer support Try commenting out the ls commands in the command table. Sent from handheld On Mar 26, 2012, at 3:09 PM, "Ian Stong" > wrote: When I execute rancid -d or f5login it shows the following then a ton of errors "Unknown option: t" executing f5login -t 90 -c"TERM=xterm;export TERM;bigpipe platform;bigpipe version;bigpipe list;bigpipe base list;bigpipe route static show;ls --full-time --color=never /config/ssl/ssl.crt;ls --full-time --color=never /config/ssl/ssl.key" 10.20.30.1 Any ideas and can someone send their working F5 script for a 9.x version? Thanks, Ian _______________________________________________ Rancid-discuss mailing list Rancid-discuss at shrubbery.net http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss -------------- next part -------------- An HTML attachment was scrubbed... URL: From gabbawp at gmail.com Wed Mar 28 08:36:48 2012 From: gabbawp at gmail.com (Gareth Hopkins) Date: Wed, 28 Mar 2012 10:36:48 +0200 Subject: [rancid] Rancid 2.3.8 and multiple vendor devices Message-ID: <3B508DF5-D324-4D3D-A7C0-FF10C8067EB2@gmail.com> Hi, I've upgraded some of our rancid instances to 2.3.8 and am seeing the following issues. When polling fortigate devices, I get the following $ fnlogin fortigate_device fortigate_device spawn ssh -p -c 3des -x -l rancid fortigate_device Bad port '' Error: Couldn't login: fortigate_device So ssh is connecting with a port but there is no port specified in my .cloginrc file. add method * {ssh} {telnet} When I add a ssh port fortigates start working, but junipers then break. .cloginrc file is now add method * {ssh:22} {telnet} $ jlogin juniper_device juniper_device Error: unknown connection method: ssh:22 It seems that either fnlogin or jlogin is not reading the port settings from .cloginrc correctly ? Cheers, Gareth From chris.weakland at gmail.com Wed Mar 28 18:48:51 2012 From: chris.weakland at gmail.com (Chris Weakland) Date: Wed, 28 Mar 2012 14:48:51 -0400 Subject: [rancid] Cisco GSS 4492 Config Fetch... Message-ID: I had some time today and added a routine into my rancid config to gather my Cisco GSS's running config and gslb config. Here is how you add it: Edit file: rancid-fe In the %vendortable section near the top of the file add the following: 'gss' => 'gssrancid', Here is some context to help you: 'foundry' => 'francid', 'gss' => 'gssrancid', 'hitachi' => 'htrancid', In the same directory as your rancid-fe file, you have a file called "rancid". Copy this file to a new file named gssrancid. Edit file: gssrancid Add the follwing code: # This routine parses "show gslb-config" sub ShowGslbConfig { print STDERR " In ShowGslbConfig: $_" if ($debug); ProcessHistory("","","","!Begin GSLB Config\n!\n"); while () { tr/\015//d; last if (/^$prompt/); next if (/^(\s*|\s*$cmd\s*)$/); return(1) if /^\s*\^\s*$/; return(1) if /Line has invalid autocommand /; return(1) if /(Invalid input detected|Type help or )/; return(-1) if (/command authorization failed/i); # the pager can not be disabled per-session on the PIX if (/^(<-+ More -+>)/) { my($len) = length($1); s/^$1\s{$len}//; } ProcessHistory("","","","$_"); } ProcessHistory("","","","\n!\n!End GSLB Config\n!\n"); return(0); } I added the above section right above this line: # This routine processes a "write term" sub WriteTerm { Lastly, in the commandtable section add the following line: {'show gslb-config' => 'ShowGslbConfig'}, Again here is some context to guide you: # {'show debug' => 'ShowDebug'}, {'show gslb-config' => 'ShowGslbConfig'}, {'show running-config' => 'WriteTerm'}, Optionally, you can rem out the `show debug` as it does not work at all on the GSS and it makes your rancid config look ugly. Here is a diff of my gssrancid vs rancid: ~/bin$ diff gssrancid rancid 1525,1548d1524 < # This routine parses "show gslb-config" < sub ShowGslbConfig { < print STDERR " In ShowGslbConfig: $_" if ($debug); < ProcessHistory("","","","!Begin GSLB Config\n!\n"); < while () { < tr/\015//d; < last if (/^$prompt/); < next if (/^(\s*|\s*$cmd\s*)$/); < return(1) if /^\s*\^\s*$/; < return(1) if /Line has invalid autocommand /; < return(1) if /(Invalid input detected|Type help or )/; < return(-1) if (/command authorization failed/i); < # the pager can not be disabled per-session on the PIX < if (/^(<-+ More -+>)/) { < my($len) = length($1); < s/^$1\s{$len}//; < } < < ProcessHistory("","","","$_"); < } < ProcessHistory("","","","\n!\n!End GSLB Config\n!\n"); < return(0); < } < 1946,1947c1922,1923 < # {'show debug' => 'ShowDebug'}, < {'show gslb-config' => 'ShowGslbConfig'}, --- > {'show debug' => 'ShowDebug'}, > {'more system:running-config' => 'WriteTerm'}, # ASA/PIX Enjoy, Chris -------------- next part -------------- An HTML attachment was scrubbed... URL: From guillaume.dupuis at novidys.com Thu Mar 29 12:53:33 2012 From: guillaume.dupuis at novidys.com (Guillaume Dupuis) Date: Thu, 29 Mar 2012 12:53:33 +0000 (UTC) Subject: [rancid] Palo Alto Networks References: Message-ID: Nate Beck jivesoftware.com> writes: > > > Has anyone on the list worked with Palo Alto Network firewalls and Rancid? ?I was wondering if anyone has created a *login for them. > Thanks------------------- > Nathan BeckSr. IT Engineer > Jive Software > 503.972.9024 Hi Nate, Did you find a *login script for PAN? Thanks, Guillaume Dupuis