Re: [rancid] paloalto feedback in current alpha [was: Re: clogin commenting script commands following multiple blanks lines]

2018-10-30 Thread Gauthier, Chris
Interesting!  I have yet to upgrade our installations to 8.1.4.  Thanks for the 
heads up!


Chris Gauthier Senior Network Engineer | comScore, Inc.
t +1 (503) 331-2704 |
cgauth...@comscore.com
317 SW Alder Street, Suite 700 | Portland, OR 97204  United States
comscore.com
​​​This e-mail (including any attachments) may contain information that is 
private, confidential, or protected by attorney-client or other privilege. If 
you received this e-mail in error, please delete it from your system and notify 
sender.
-Original Message-
From: Rancid-discuss  on behalf of Erik 
Muller 
Date: Friday, October 26, 2018 at 3:25 PM
To: heasley 
Cc: rancid list 
Subject: [rancid] paloalto feedback in current alpha [was: Re: clogin 
commenting script commands following multiple blanks lines]

On 10/24/18 18:32 , heasley wrote:
> Wed, Oct 24, 2018 at 09:19:31PM +, heasley:
> ok; committed.  Either the alpha tarball or the svn repo.  Welcome testers,
> esp for palo alto, of which I have none.

At least on 8.1.4 on my 3250s, the cli is a little bit busted until you get out 
of interactive mode - for every space you enter between words in the command, 
it redraws the current line, which was messing up the prompt matching as below. 
 Fix for that attached at end of message.
-e

rancid@status:~$ rancid -t paloalto -d fw1.ams
loadtype: device type paloalto
loadtype: found device type paloalto in 
/home/erikm/rancidtest/etc/rancid.types.base
executing panlogin -t 90 -c"set cli scripting-mode on;set cli pager off;show 
system info;show config running" fw1.ams
line: fw1.ams
line: spawn ssh -c aes256-ctr,aes192-ctr -x -l rancid fw1.ams
line: Password:
line: Last login: Fri Oct 26 20:04:51 2018 from 10.x.x.x
line: No entry for terminal type "network";
line: using dumb terminal settings.
line:
line: Number of failed attempts since last successful login: 0
line:
line:
line: ran...@fw1.ams(active)>
line: ran...@fw1.ams(active)>
line: ran...@fw1.ams(active)> set
line: ran...@fw1.ams(active)> set cli
line: ran...@fw1.ams(active)> set cli scripting-mode
line: ran...@fw1.ams(active)> set cli scripting-mode on
PROMPT MATCH: ran...@fw1.ams\(active\)[#>]
HIT COMMAND:ran...@fw1.ams(active)> set cli scripting-mode on

COMMAND is: set cli scripting-mode on|rancid::RunCommand
In RunCommand: ran...@fw1.ams(active)> set cli scripting-mode on
line: sran...@fw1.ams(active)> how system info
line: s
line: hostname: fw1.ams
line: ip-address: 10.x.x.x
...
line: family: 3200
line: model: PA-3250
line: sw-version: 8.1.4-h2
...
line: multi-vsys: off
line: operational-mode: normal
line:
line: ran...@fw1.ams(active)> how config running
line: exit
line:
line: config {
line:   mgt-config {
line: users {
...
line: ran...@fw1.ams(active)> Connection to fw1.ams closed.
fw1.ams: missed cmd(s): set cli pager off, show system info
fw1.ams: End of run not found
fw1.ams: clean_run is false
fw1.ams: found_end is false
!



erikm@status:~/src$ diff -ur rancid-3.99.99 rancid-3.99.99-em/
diff -ur 
rancid-3.99.99/bin/https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fpanlogin.in&c=E,1,6ITCpn7S8etHwRGxye4nnY-WXsOspZJKTHaSxUMwn7CUVVRDtL9N4eULfbpZKMnS2fE-49UrdfNQg0zd5F8rE7gq5t_QzpoQwMmdI9v87bdIynxj_kNZYaM,&typo=1
 
rancid-3.99.99-em/bin/https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fpanlogin.in&c=E,1,AFuvKrybC8GB6DG7swV-DVjqoacwb3bN-9HbNrwIHSu3eQM0RtFFTm_43KfETWr8-Uz_SJGx3N-3-OaDDhdxtdoNE4ZVfLEnq_ly_T8O8XSbFZ9ZEA,,&typo=1
--- 
rancid-3.99.99/bin/https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fpanlogin.in&c=E,1,PaBCXESaFYWjzoqImlahNbNlLrsy_b2vXybrRIrH36LE0245jqMqk6zO7RNZojKH5MycizqdsA_XLMSlWFTJWC55BdQ4EZyVefR65_EuhGMq766dEcz4ZHHC&typo=1
2018-10-24 18:26:50.0 -0400
+++ 
rancid-3.99.99-em/bin/https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fpanlogin.in&c=E,1,EMioRKDRQlsHo46MUuAFylZdiNznL5XtoxGxMWzoJ-zE-yjczHpChxK9eUwVOkVfFMmWgFqx3n44hw-w1Ry9jmPUH43kK_du2ctguUJdL-p0-eIk&typo=1
 2018-10-26 17:24:55.945967567 -0400
@@ -455,14 +455,22 @@
}
 }

+# PAN-OS in interactive mode will send a newline and then redraw the
+# whole prompt-and-command if you send a space.
+if { $do_command || $do_script } {
+   set cmd "set cli scripting-mode on\r"
+   send $cmd
+   # ensure we eat the partial commands redrawn while entering the command
+   expect -re "$cmd.*$prompt"  {}
+   send "set cli pager off\r"
+   expect -re $prompt  {}
+}
+
 if { $do_command } {
if {[run_commands $prompt $command]} {
continue
}
 } elseif { $do_script } {
-#  send "set cli scripting-mode on\r"
-#  send "set cli pager off\r"
-   expect -re $prompt  {}
source $sfile
close
 } else {
diff -ur rancid-3.99.99/etc/rancid.types.base 
rancid-3.99.99-em/etc/rancid.types.base
--- rancid-3.99.99/etc/rancid.types.base2018-10-24 11:13:49.0 
-0400
+++ rancid-3.99.99-em/etc/rancid.types.base 2018-10-26 17:16:53.950868

Re: [rancid] juniper devices

2018-10-30 Thread h...@shrubbery.net
Tue, Oct 30, 2018 at 01:43:33PM +, Andrew Meyer:
> Also I installed this from CentOS 7 EPEL repo. 

well, it appears to have a flaw.  either fix the PATH or install 3.8 from
source.

> On Monday, October 29, 2018 7:29 PM, Andrew Meyer  
> wrote:
>  
> 
>  Amazon Linux 2 is based on redhat/centos 7.
> 
> Sent from Yahoo Mail on Android 
>  
>   On Mon, Oct 29, 2018 at 19:02, heasley wrote:   > Mon, 
> Oct 29, 2018 at 09:11:31PM +, Andrew Meyer:
> > I am having some issues with rancid-3.2-2 on Amazon Linux 2.  I am trying 
> > to    
> > get rancid to talk to my Juniper (junos) switches and SRX firewalls and am
> > stuck.
> >  
> > Juniper EX2200
> > Juniper SRX650
> > 
> > I have everything setup in my config.
> > 
> > router.db
> > [rancid@rancid01 configs]$ cat ../router.db
> > fw.location.example.net;juniper-srx;up
> > sw1.location.example.net;junos;up
> > sw2.location.example.net;juniper;up
> > sw3.location.example.net;juniper;up
> > sw4.location.example.net;juniper;up
> > sw5.location.example.net;juniper;up
> > aruba1.location.example.net;aruba;up
> > aruba2.location.example.net;aruba;down
> > [rancid@rancid01 configs]$
> > 
> > 
> > Here is my logs.
> > =
> > Getting missed routers: round 4.
> > unknown router manufacturer for sw1.location.example.net: junos
>   ^^^
> type should be juniper
> 
> > sh: jlogin: command not found
>   ^
> > fw.location.example.net: missed cmd(s): all commands
> > fw.location.example.net: End of run not found
> > sh: jlogin: command not found
> > sw2.location.example.net: missed cmd(s): all commands
> > sw2.location.example.net: End of run not found
> > #
> > #
> > sh: clogin: command not found
>   ^
> I do not know what an Amazon Linux 2 is nor how you installed rancid,
> but because you can run clogin from your shell prompt, i assume you are
> not missing prerequisite packages.  so, you probably just have a deficient
> PATH in your rancid.conf.
> 
> > aruba1.location.example.net: missed cmd(s): all commands
> > aruba1.location.example.net: End of run not found
> > !
> > sh: jlogin: command not found
> > sw3.location.example.net: missed cmd(s): all commands
> > sw3.location.example.net: End of run not found
> > sh: jlogin: command not found
> > sw4.location.example.net: missed cmd(s): all commands
> > sw4.location.example.net: End of run not found
> > #
> > #
> > sh: jlogin: command not found
> > sw5.location.example.net: missed cmd(s): all commands
> > sw5.location.example.net: End of run not found
> > #
> >  
> > On branch master
> > Your branch is up-to-date with 'origin/master'.
> > 
> > nothing to commit, working tree clean
> > Everything up-to-date
> > 
> > ending: Mon Oct 29 21:01:01 UTC 2018
> > [rancid@rancid01 logs]$
> > 
> > When I run a clogin command on its own, I can ssh in just fine but there is 
> > a
> > sligh issue with the terminal.  I suspect it's pagination.
> > 
> > 
> > It has been while since having to do this so I'm not sure where I got this
> > mixed up.
> > 
> > Any thoughts?
> > 
> > Regards,
> > Andrew
> > 
> > 
> > ___
> > Rancid-discuss mailing list
> > Rancid-discuss@shrubbery.net
> > http://www.shrubbery.net/mailman/listinfo/rancid-discuss
> 
>   
> 
> 
>

___
Rancid-discuss mailing list
Rancid-discuss@shrubbery.net
http://www.shrubbery.net/mailman/listinfo/rancid-discuss


Re: [rancid] Problem rancid 3.7 after cmw / hp 5130 routers 5130 firmware upgrade

2018-10-30 Thread heasley
Tue, Oct 30, 2018 at 12:02:09PM +0100, Service Informatique CH DECIZE:
> Hello,
> 
> We have made a firmware update on our cwm / hp 5130 routers : upgrade from
> 3115P05 release (7.1.045) to 3208P03 release (7.1.070).
> Since upgrade, we receive "config fetcher problems" mails, that indicates " 
> The
> following routers have not been successfully contacted for more than 24
> hours".
> In the rancid logs, we can see for these routers :
> " Trying to get all of the configs.
> swsr1: End of run not found
> return
> =
> Getting missed routers: round 1.
> swsr1: End of run not found
> return
> ... "
> Does anyone know where is the problem ?
> Before upgrade, everything was ok with these routers in rancid.

what device type are you using for these?  It looks like you are using a
older version of rancid or have a custom module?

___
Rancid-discuss mailing list
Rancid-discuss@shrubbery.net
http://www.shrubbery.net/mailman/listinfo/rancid-discuss


[rancid] Problem rancid 3.7 after cmw / hp 5130 routers 5130 firmware upgrade

2018-10-30 Thread Service Informatique CH DECIZE
Hello,

We have made a firmware update on our cwm / hp 5130 routers : upgrade from
3115P05 release (7.1.045) to 3208P03 release (7.1.070).
Since upgrade, we receive "config fetcher problems" mails, that indicates " The
following routers have not been successfully contacted for more than 24
hours".
In the rancid logs, we can see for these routers :
" Trying to get all of the configs.
swsr1: End of run not found
return
=
Getting missed routers: round 1.
swsr1: End of run not found
return
... "
Does anyone know where is the problem ?
Before upgrade, everything was ok with these routers in rancid.
Please help, we don't know how to solve the problem.
Thanks.

Yann.
___
Rancid-discuss mailing list
Rancid-discuss@shrubbery.net
http://www.shrubbery.net/mailman/listinfo/rancid-discuss