Discussion:
[rancid] missed cmd(s): show full-configuration,get system status
Gerhard Mourani
2012-05-30 17:06:57 UTC
Permalink
Helo list,

After an update to Rancid version 2.3.8, the method used to login into FortiGate device no longer work and report the following error in the log file.

Getting missed routers: round 4.
192.168.2.1 fnlogin error: Error: Couldn't login: 192.168.2.1
192.168.2.1: missed cmd(s): show full-configuration,get system status
0: found end
192.168.2.1: End of run not found

With previous version of Rancid, everything worked correctly. According to the above error I've run the following commands to verify if the missed cmd is true or not.

/usr/bin/clogin -f /usr/share/rancid/.cloginrc 192.168.2.1
The above works and I can manually run the 'show full-configuration' or 'get system status' command without problem!

Therefore no idea about why this error occur now and from which part it's really coming from!

Gerhard,
Gareth Hopkins
2012-05-31 08:30:13 UTC
Permalink
Hi,

If you run fnlogin instead of clogin, you'll see it complains about an ssh port not being specified. I ran into exactly the same problem and mailed the list a couple of weeks ago but heard nothing back unfortunately.

A quick work around is to add the following to your cloginrc file

add method device_name {ssh:22}

I hope someone can take a look at this though.

Cheers,

Gareth
Post by Gerhard Mourani
Helo list,
After an update to Rancid version 2.3.8, the method used to login into FortiGate device no longer work and report the following error in the log file.
Getting missed routers: round 4.
192.168.2.1 fnlogin error: Error: Couldn't login: 192.168.2.1
192.168.2.1: missed cmd(s): show full-configuration,get system status
0: found end
192.168.2.1: End of run not found
With previous version of Rancid, everything worked correctly. According to the above error I’ve run the following commands to verify if the missed cmd is true or not.
/usr/bin/clogin -f /usr/share/rancid/.cloginrc 192.168.2.1
The above works and I can manually run the ‘show full-configuration’ or ‘get system status’ command without problem!
Therefore no idea about why this error occur now and from which part it’s really coming from!
Gerhard,
_______________________________________________
Rancid-discuss mailing list
http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss
Gerhard Mourani
2012-05-31 12:20:30 UTC
Permalink
Thanks Gareth,

That's worked for me too.

Gerhard,

From: Gareth Hopkins [mailto:***@gmail.com]
Sent: May-31-12 4:30 AM
To: Gerhard Mourani
Cc: rancid-***@shrubbery.net
Subject: Re: [rancid] missed cmd(s): show full-configuration,get system status

Hi,

If you run fnlogin instead of clogin, you'll see it complains about an ssh port not being specified. I ran into exactly the same problem and mailed the list a couple of weeks ago but heard nothing back unfortunately.

A quick work around is to add the following to your cloginrc file

add method device_name {ssh:22}

I hope someone can take a look at this though.

Cheers,

Gareth

On 30 May 2012, at 7:06 PM, Gerhard Mourani wrote:


Helo list,

After an update to Rancid version 2.3.8, the method used to login into FortiGate device no longer work and report the following error in the log file.

Getting missed routers: round 4.
192.168.2.1 fnlogin error: Error: Couldn't login: 192.168.2.1
192.168.2.1: missed cmd(s): show full-configuration,get system status
0: found end
192.168.2.1: End of run not found

With previous version of Rancid, everything worked correctly. According to the above error I've run the following commands to verify if the missed cmd is true or not.

/usr/bin/clogin -f /usr/share/rancid/.cloginrc 192.168.2.1
The above works and I can manually run the 'show full-configuration' or 'get system status' command without problem!

Therefore no idea about why this error occur now and from which part it's really coming from!

Gerhard,
heasley
2012-08-16 21:12:08 UTC
Permalink
Post by Gerhard Mourani
Thanks Gareth,
That's worked for me too.
Gerhard,
Sent: May-31-12 4:30 AM
To: Gerhard Mourani
Subject: Re: [rancid] missed cmd(s): show full-configuration,get system status
Hi,
If you run fnlogin instead of clogin, you'll see it complains about an ssh port not being specified. I ran into exactly the same problem and mailed the list a couple of weeks ago but heard nothing back unfortunately.
A quick work around is to add the following to your cloginrc file
add method device_name {ssh:22}
I hope someone can take a look at this though.
Does this patch to fnlogin fix your problem:

Index: bin/fnlogin.in
===================================================================
--- bin/fnlogin.in (revision 2376)
+++ bin/fnlogin.in (revision 2435)
@@ -303,7 +303,7 @@
} elseif [string match "ssh*" $prog] {
regexp {ssh(:([^[:space:]]+))*} $prog methcmd suffix port
set cmd $sshcmd
- if {"$port" == ""} {
+ if {"$port" != ""} {
set cmd "$cmd -p $port"
}
set retval [ catch {eval spawn [split "$cmd -c $cyphertype -x -l $user $router" { }]} reason ]
Post by Gerhard Mourani
Cheers,
Gareth
Helo list,
After an update to Rancid version 2.3.8, the method used to login into FortiGate device no longer work and report the following error in the log file.
Getting missed routers: round 4.
192.168.2.1 fnlogin error: Error: Couldn't login: 192.168.2.1
192.168.2.1: missed cmd(s): show full-configuration,get system status
0: found end
192.168.2.1: End of run not found
With previous version of Rancid, everything worked correctly. According to the above error I've run the following commands to verify if the missed cmd is true or not.
/usr/bin/clogin -f /usr/share/rancid/.cloginrc 192.168.2.1
The above works and I can manually run the 'show full-configuration' or 'get system status' command without problem!
Therefore no idea about why this error occur now and from which part it's really coming from!
Gerhard,
Loading...