From heas at shrubbery.net Mon Nov 1 03:59:30 2021 From: heas at shrubbery.net (heasley) Date: Mon, 1 Nov 2021 03:59:30 +0000 Subject: [rancid] Rancid in FreeBSD ports break on FreeBSD 13.0 In-Reply-To: <0b574d12-5705-d422-3fb3-1f28d1d1cf0e@xs4all.nl> References: <0b574d12-5705-d422-3fb3-1f28d1d1cf0e@xs4all.nl> Message-ID: Sun, Oct 31, 2021 at 11:36:14PM +0100, Geert Jan de Groot: > Hi, > > Perhaps I should not report this because the current version of Rancid > is 3.1, but the version in FreeBSD pkg is still 2.3.8. Anyway.. > > With the upgrade to FreeBSD 13.0, this old version of Rancid broke. > Root cause seems to be the use of "diff -u -4" in control-rancid. > I'm not sure what '-4' does; could not find it in the man pages of diff. > > Anyway, omitting it makes things work again. I should just install from > the repository, but "not today". Hey. -N sets the number of lines of context. at least two forms have appeared over time; -N, -uN. Why the need for change, I do not know. I expect configure to have found the right options. Did you re-install from source? do you have multiple versions of diff? > Geert Jan > > *** control_rancid.SAV Sun Apr 3 14:32:28 2016 > --- control_rancid Sun Oct 31 16:36:14 2021 > *************** > *** 199,213 **** > tr '[A-Z]' '[a-z]' | sort -u > routers.db > cut -d: -f1,2 routers.db > routers.all.new > if [ ! -f routers.all ] ; then touch routers.all; fi > ! diff -u -4 routers.all routers.all.new > /dev/null 2>&1; RALL=$? > perl5 -F: -ane '{$F[2] =~ s/\s*\$//; ($F[0] =~ tr at A-Z@a-z@, print $_) > if ($F[2] !~ /^up$/i);}' routers.db > routers.down.new > if [ ! -f routers.down ] ; then touch routers.down; fi > ! diff -u -4 routers.down routers.down.new > /dev/null 2>&1; RDOWN=$? > perl5 -F: -ane '{$F[2] =~ s/\s*\$//; ($F[0] =~ tr at A-Z@a-z@, > print "$F[0]:$F[1]\n") if ($F[2] =~ /^up$/i);}' routers.db > > routers.up.new > if [ ! -f routers.up ] ; then touch routers.up; fi > ! diff -u -4 routers.up routers.up.new > /dev/null 2>&1; RUP=$? > > if [ $RALL -ne 0 -o $RDOWN -ne 0 -o $RUP -ne 0 ] ; then > ( > --- 199,213 ---- > tr '[A-Z]' '[a-z]' | sort -u > routers.db > cut -d: -f1,2 routers.db > routers.all.new > if [ ! -f routers.all ] ; then touch routers.all; fi > ! diff -u routers.all routers.all.new > /dev/null 2>&1; RALL=$? > perl5 -F: -ane '{$F[2] =~ s/\s*\$//; ($F[0] =~ tr at A-Z@a-z@, print $_) > if ($F[2] !~ /^up$/i);}' routers.db > routers.down.new > if [ ! -f routers.down ] ; then touch routers.down; fi > ! diff -u routers.down routers.down.new > /dev/null 2>&1; RDOWN=$? > perl5 -F: -ane '{$F[2] =~ s/\s*\$//; ($F[0] =~ tr at A-Z@a-z@, > print "$F[0]:$F[1]\n") if ($F[2] =~ /^up$/i);}' routers.db > > routers.up.new > if [ ! -f routers.up ] ; then touch routers.up; fi > ! diff -u routers.up routers.up.new > /dev/null 2>&1; RUP=$? > > if [ $RALL -ne 0 -o $RDOWN -ne 0 -o $RUP -ne 0 ] ; then > ( > > _______________________________________________ > Rancid-discuss mailing list > Rancid-discuss at www.shrubbery.net > https://www.shrubbery.net/mailman/listinfo/rancid-discuss From pokui at psg.com Mon Nov 1 17:56:57 2021 From: pokui at psg.com (Patrick Okui) Date: Mon, 01 Nov 2021 20:56:57 +0300 Subject: [rancid] Rancid in FreeBSD ports break on FreeBSD 13.0 In-Reply-To: <0b574d12-5705-d422-3fb3-1f28d1d1cf0e@xs4all.nl> References: <0b574d12-5705-d422-3fb3-1f28d1d1cf0e@xs4all.nl> Message-ID: <67B02B36-60C8-488B-8833-44F43CC686B2@psg.com> On 1 Nov 2021, at 1:36 EAT, Geert Jan de Groot wrote: > Hi, > > Perhaps I should not report this because the current version of Rancid is 3.1, but the version in FreeBSD pkg is still 2.3.8. Anyway.. I only see 3.13.1 in the repos. https://freebsd.pkgs.org/13/freebsd-amd64/rancid3-3.13_1.txz.html -- patrick From GeertJan.deGroot at xs4all.nl Mon Nov 1 21:44:21 2021 From: GeertJan.deGroot at xs4all.nl (Geert Jan de Groot) Date: Mon, 1 Nov 2021 22:44:21 +0100 Subject: [rancid] Rancid in FreeBSD ports break on FreeBSD 13.0 In-Reply-To: References: Message-ID: <7cfedc35-b66a-9394-8541-e8fd8bdb7b11@xs4all.nl> Hi, > Hey. -N sets the number of lines of context. at least two forms have > appeared over time; -N, -uN. Why the need for change, I do not know. > > I expect configure to have found the right options. Did you re-install > from source? do you have multiple versions of diff? The machine is in an inaccessible place (radio-tower, now double inaccessible because of COVID) and I simply run pkg update on FreeBSD every so often, and run an upgrade when I must. Stangely, it was stuck with the old version of rancid from pkg and pkg wasn't complaining. I un-installed rancid, installed rancid (now 'rancid3' in pkg) and all is well. I don't know how this package got stuck on the old version, but now all is well. Apologies for crying wolf. Geert Jan From m_zouhairy at skno.by Tue Nov 2 12:56:58 2021 From: m_zouhairy at skno.by (Vacheslav) Date: Tue, 2 Nov 2021 15:56:58 +0300 Subject: [rancid] ucs backup Message-ID: <147d594d-65fa-c852-7575-720f13261050@skno.by> Peace and blessings to you, searching rancid and ucs cisco fabric backup lead to: show configuration | no-more connect nxos show running-config | no-more exit so i created: ########### Cisco Fabric Ucs cisco-ucs;script;rancid -t cisco-ucs cisco-ucs;login;clogin cisco-ucs;module;nxos cisco-ucs;inloop;nxos::inloop cisco-ucs;command;nxos::ShowVersion;show version cisco-ucs;command;nxos::WriteTerm;show configuration | no more cisco-ucs;command;nxos::WriteTerm;connect nxos cisco-ucs;command;nxos::WriteTerm;show running-config cisco-ucs;command;nxos::WriteTerm;exit ########### in rancid.types.base but the log file shows: ===================================== Getting missed routers: round 4. fi-a: missed cmd(s): show running-config fi-a: End of run not found FI-A(nxos)# exit fi-b: missed cmd(s): show running-config rfi-b: End of run not found FI-B(nxos)# exit ending: Tue Nov 2 03:32:58 PM +03 2021 anyone backing ucs here? From heas at shrubbery.net Tue Nov 2 16:14:37 2021 From: heas at shrubbery.net (heasley) Date: Tue, 2 Nov 2021 16:14:37 +0000 Subject: [rancid] ucs backup In-Reply-To: <147d594d-65fa-c852-7575-720f13261050@skno.by> References: <147d594d-65fa-c852-7575-720f13261050@skno.by> Message-ID: Tue, Nov 02, 2021 at 03:56:58PM +0300, Vacheslav: > ########### Cisco Fabric Ucs > cisco-ucs;script;rancid -t cisco-ucs > cisco-ucs;login;clogin > cisco-ucs;module;nxos > cisco-ucs;inloop;nxos::inloop > cisco-ucs;command;nxos::ShowVersion;show version > cisco-ucs;command;nxos::WriteTerm;show configuration | no more > cisco-ucs;command;nxos::WriteTerm;connect nxos Does the prompt change after this command? > cisco-ucs;command;nxos::WriteTerm;show running-config > cisco-ucs;command;nxos::WriteTerm;exit > ########### > in rancid.types.base rancid.types.conf - otherwise the next upgrade will overwrite your custom definition > but the log file shows: > > ===================================== > Getting missed routers: round 4. > fi-a: missed cmd(s): show running-config > fi-a: End of run not found > FI-A(nxos)# exit > fi-b: missed cmd(s): show running-config > rfi-b: End of run not found > FI-B(nxos)# exit > ending: Tue Nov 2 03:32:58 PM +03 2021 From m_zouhairy at skno.by Tue Nov 2 16:52:14 2021 From: m_zouhairy at skno.by (vacheslav) Date: Tue, 2 Nov 2021 19:52:14 +0300 Subject: [rancid] ucs backup In-Reply-To: References: <147d594d-65fa-c852-7575-720f13261050@skno.by> Message-ID: 2.11.21 19:14, heasley ?????: > connect nxos RUP-FI-A# connect nxos Cisco Nexus Operating System (NX-OS) Software TAC support: http://www.cisco.com/tac Copyright (c) 2002-2021, Cisco Systems, Inc. All rights reserved. The copyrights to certain works contained in this software are owned by other third parties and used and distributed under license. Certain components of this software are licensed under the GNU General Public License (GPL) version 2.0 or the GNU Lesser General Public License (LGPL) Version 2.1. A copy of each such license is available at http://www.opensource.org/licenses/gpl-2.0.php and http://www.opensource.org/licenses/lgpl-2.1.php RUP-FI-A(nxos)# From peo at chalmers.se Tue Nov 9 12:58:24 2021 From: peo at chalmers.se (Per-Olof Olsson) Date: Tue, 9 Nov 2021 13:58:24 +0100 Subject: [rancid] Error handler for rancid.types.conf/base files. Message-ID: <64d49f42-8cbb-4f6a-a3d6-a1ea59a1966a@chalmers.se> Hello. 1. If you miss or typo the "script" line in rancid.types.conf you end up with: (rancid 3.13) >/etc/rancid.types.conf -t Use of uninitialized value $prog in pattern match (m//) at /home/rancid/peo/rancid/lib/rancid/rancid.pm line 569. Use of uninitialized value $prog in join or string at /home/rancid/peo/rancid/lib/rancid/rancid.pm line 573. Use of uninitialized value $prog in join or string at /home/rancid/peo/rancid/lib/rancid/rancid.pm line 573. Use of uninitialized value $prog in join or string at /home/rancid/peo/rancid/lib/rancid/rancid.pm line 573. Use of uninitialized value $prog in join or string at /home/rancid/peo/rancid/lib/rancid/rancid.pm line 573. Use of uninitialized value $prog in join or string at /home/rancid/peo/rancid/lib/rancid/rancid.pm line 573. Use of uninitialized value $prog in join or string at /home/rancid/peo/rancid/lib/rancid/rancid.pm line 573. Use of uninitialized value $prog in join or string at /home/rancid/peo/rancid/lib/rancid/rancid.pm line 573. Use of uninitialized value $prog in join or string at /home/rancid/peo/rancid/lib/rancid/rancid.pm line 573. Use of uninitialized value $prog in join or string at /home/rancid/peo/rancid/lib/rancid/rancid.pm line 573. Can't exec "": No such file or directory at /home/rancid/peo/rancid/bin/rancid line 107. exec() failed: No such file or directory What I can see is the "script" line mandatory so is i possible to do some test on that this line exists? --------------------------------------------------------------- $ diff -u rancid.in.org rancid.in --- rancid.in.org 2021-11-08 16:46:35.000637103 +0100 +++ rancid.in 2021-11-08 16:47:08.133136600 +0100 @@ -41,6 +41,9 @@ if (loadtype($devtype)) { die "Couldn't load device type spec for $rancid::devtype\n"; } +if (! defined($script)) { + die "script not defined for device type $rancid::devtype\n"; +} if (! defined($lscript)) { die "login script not defined for device type $rancid::devtype\n"; } --------------------------------------------------------------------------- Have been nice and stop me from digging deep into perl scripts any more. Just point me to my typos in rancid.types.*. 2. Also a minor type in rancid.conf.sample.in #ACLFILTERSEQ=YES; export FILTERSEQ Expect to export the variable that is been defined. #ACLFILTERSEQ=YES; export ACLFILTERSEQ /Peo ---------------------------------------------------------- Per-Olof Olsson Email: peo at chalmers.se Chalmers tekniska h?gskola IT-avdelningen Sven Hultins gata 8 412 96 G?teborg Tel: 031/772 6738 Mob: 0707 88 3708 ---------------------------------------------------------- From jake at secrist.org Tue Nov 9 15:03:02 2021 From: jake at secrist.org (Jake Secrist) Date: Tue, 9 Nov 2021 10:03:02 -0500 Subject: [rancid] Palo Alto Panorama 'show config' - End of run not found Message-ID: In panos.pm (sub ShowConfig), RANCID finds the end of the 'show config' output by matching a bare close bracket from the following regex: if (/^}\s*$|\[edit\]/) { We have a Panorama with an HTTP server profile that has a payload data section which shows in the configuration like this: { ************ lines of data ************* ************ lines of data ************* ************ lines of data ************* } So the closing bracket of this data section matches the regex in panos.pm and RANCID stops collecting the config output there. But this is not the end of the configuration. I can't think of any way around this since the actual end of the 'show config' command is a bare close bracket. There must be a good reason the prompt is not used to match as the end of output? Thank you, Jake * * -------------- next part -------------- An HTML attachment was scrubbed... URL: From jake at secrist.org Tue Nov 9 17:17:19 2021 From: jake at secrist.org (Jake Secrist) Date: Tue, 9 Nov 2021 12:17:19 -0500 Subject: [rancid] Palo Alto Panorama 'show config' Message-ID: I guess posts are not editable? I put 'End of run not found' in the subject of my last post but that is not relevant. I was getting 'End of run not found' when I tried to change the regex below and when I tried to match on the prompt. ------------- Original post is below ------------- In panos.pm (sub ShowConfig), RANCID finds the end of the 'show config' output by matching a bare close bracket from the following regex: if (/^}\s*$|\[edit\]/) { We have a Panorama with an HTTP server profile that has a payload data section which shows in the configuration like this: { ************ lines of data ************* ************ lines of data ************* ************ lines of data ************* } So the closing bracket of this data section matches the regex in panos.pm and RANCID stops collecting the config output there. But this is not the end of the configuration. I can't think of any way around this since the actual end of the 'show config' command is a bare close bracket. There must be a good reason the prompt is not used to match as the end of output? Thank you, Jake * * -------------- next part -------------- An HTML attachment was scrubbed... URL: From heas at shrubbery.net Thu Nov 11 23:52:49 2021 From: heas at shrubbery.net (heasley) Date: Thu, 11 Nov 2021 23:52:49 +0000 Subject: [rancid] RANCID no longer working with MikroTik RouterOS 6.49 and 7.1rc3 and 7.1rc4 In-Reply-To: References: Message-ID: Sat, Oct 16, 2021 at 05:35:16PM -0700, Michael Ducharme: > Hello, > > Unfortunately, that does not fix it, and neither does "network" or "dumb". > Something that I might suggest is that you install the free CHR (cloud > hosted router) as a VM rather easily, as long as you have a hypervisor, and > test against that. Does this fix the issue for you? https://github.com/haussli/rancid/commit/fef0b6ec166ae2892e8fc6e6a3d0f2de82379c29 From mducharme at gmail.com Fri Nov 12 00:32:27 2021 From: mducharme at gmail.com (Michael Ducharme) Date: Thu, 11 Nov 2021 16:32:27 -0800 Subject: [rancid] RANCID no longer working with MikroTik RouterOS 6.49 and 7.1rc3 and 7.1rc4 In-Reply-To: References: Message-ID: Hello, Yes, that fixes it. On Thu, Nov 11, 2021 at 3:52 PM heasley wrote: > Sat, Oct 16, 2021 at 05:35:16PM -0700, Michael Ducharme: > > Hello, > > > > Unfortunately, that does not fix it, and neither does "network" or > "dumb". > > Something that I might suggest is that you install the free CHR (cloud > > hosted router) as a VM rather easily, as long as you have a hypervisor, > and > > test against that. > > Does this fix the issue for you? > > > https://github.com/haussli/rancid/commit/fef0b6ec166ae2892e8fc6e6a3d0f2de82379c29 > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mhuff at ox.com Fri Nov 12 11:35:14 2021 From: mhuff at ox.com (Matthew Huff) Date: Fri, 12 Nov 2021 11:35:14 +0000 Subject: [rancid] Cisco Nexus switches running 10.2 and icamsql/logflash Message-ID: <769601f9ac954c97a85bcc713e6eced6@ox.com> We have a number of new Cisco Nexus switches running 10.2 and every rancid update, we see changes in: @@ -199,8 +199,8 @@ !Flash: logflash: 4096 Sep 13 07:59:23 2021 evt_log_snapshot/ !Flash: logflash: 4096 Dec 31 19:01:46 2000 generic/ !Flash: logflash: 315392 Nov 11 12:18:22 2021 icamsql_1_1.db - !Flash: logflash: 32768 Nov 11 22:19:02 2021 icamsql_1_1.db-shm - !Flash: logflash: 4148872 Nov 11 22:19:02 2021 icamsql_1_1.db-wal + !Flash: logflash: 32768 Nov 12 02:19:18 2021 icamsql_1_1.db-shm + !Flash: logflash: 4148872 Nov 12 02:19:18 2021 icamsql_1_1.db-wal !Flash: logflash: 4096 log/ !Flash: logflash: 4096 Sep 11 14:19:06 2021 vdc_1/ !Flash: logflash: Usage for logflash://sup-local Any way of masking this? Matthew Huff | Director of Technical Operations | OTA Management LLC Office: 914-460-4039 mhuff at ox.com | www.ox.com ........................................................................................................................................... -------------- next part -------------- An HTML attachment was scrubbed... URL: From peo at chalmers.se Fri Nov 12 13:38:41 2021 From: peo at chalmers.se (Per-Olof Olsson) Date: Fri, 12 Nov 2021 14:38:41 +0100 Subject: [rancid] Cisco Nexus switches running 10.2 and icamsql/logflash In-Reply-To: <769601f9ac954c97a85bcc713e6eced6@ox.com> References: <769601f9ac954c97a85bcc713e6eced6@ox.com> Message-ID: Hi. Also notis this an just now test to remove timestam like is done to "log/" line. In "sub DirSlotN" Replace if (/( debug_logs| log)\/$/) { with if (/ (debug_logs\/|log\/|icamsql_1_1.db-shm|icamsql_1_1.db-wal)$/) { /Peo ---------------------------------------------------------- Per-Olof Olsson Email: peo at chalmers.se Chalmers tekniska h?gskola IT-avdelningen Sven Hultins gata 8 412 96 G?teborg Tel: 031/772 6738 Mob: 0707 88 3708 ---------------------------------------------------------- Den 2021-11-12 kl. 12:35, skrev Matthew Huff: > We have a number of new Cisco Nexus switches running 10.2 and every > rancid update, we see changes in: > > @@ -199,8 +199,8 @@ > > !Flash: logflash:4096Sep 13 07:59:23 2021evt_log_snapshot/ > > !Flash: logflash:4096Dec 31 19:01:46 2000generic/ > > !Flash: logflash:315392Nov 11 12:18:22 2021icamsql_1_1.db > > - !Flash: logflash:32768Nov 11 22:19:02 2021icamsql_1_1.db-shm > > - !Flash: logflash:4148872Nov 11 22:19:02 2021icamsql_1_1.db-wal > > + !Flash: logflash:32768Nov 12 02:19:18 2021icamsql_1_1.db-shm > > + !Flash: logflash:4148872Nov 12 02:19:18 2021icamsql_1_1.db-wal > > !Flash: logflash:4096log/ > > !Flash: logflash:4096Sep 11 14:19:06 2021vdc_1/ > > !Flash: logflash: Usage for logflash://sup-local > > Any way of masking this? > > *Matthew Huff*| Director of Technical Operations | OTA Management LLC > > /Office: 914-460-4039/ > > /mhuff at ox.com | //www.ox.com / > > *...........................................................................................................................................* > > > _______________________________________________ > Rancid-discuss mailing list > Rancid-discuss at www.shrubbery.net > https://www.shrubbery.net/mailman/listinfo/rancid-discuss > From branko.kobal at sb-celje.si Mon Nov 22 22:09:47 2021 From: branko.kobal at sb-celje.si (Branko Kobal) Date: Mon, 22 Nov 2021 23:09:47 +0100 Subject: [rancid] help Message-ID: <032101d7dfed$a9c08a50$fd419ef0$@sb-celje.si> Hi, BR, bkobal -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/pkcs7-signature Size: 6747 bytes Desc: not available URL: From guy20034u at yahoo.com Tue Nov 30 18:16:58 2021 From: guy20034u at yahoo.com (simon ben) Date: Tue, 30 Nov 2021 18:16:58 +0000 (UTC) Subject: [rancid] Backup Fortygate 100D References: <1784901331.1817859.1638296218241.ref@mail.yahoo.com> Message-ID: <1784901331.1817859.1638296218241@mail.yahoo.com> Dear All, I am running Rancid in production environment and backing up Cisco Routers and Switches and its working greatPlan to backup FortygateI have 2 fortgates in active/active HA in our production data center Can I go with the same steps as I do when I add another cisco switch or router or anything needs to be done either on rancid server side or the Fortygate sideAppreciate your kind advice. Since this fortygate is in Production just want to be more cautious Thanks and Regards simon -------------- next part -------------- An HTML attachment was scrubbed... URL: