Problems getting config when not enable mode
Bill Rowan
browan at houston.rr.com
Fri Feb 17 08:05:49 UTC 2006
john heasley <heas <at> shrubbery.net> writes:
>
> Wed, Jul 09, 2003 at 01:13:19PM -0400, Fred Jordan:
> > John,
> > Thanks for the reply. We do have creative AAA statements that
> > do allow us to type "show config" and we can see the
> > startup-config file. Really this is where I am headed. At the
> > privilege level we log in , which is less than 15; we can do almost
> > all of the show commands. With that, I was hoping we would be able to
> > either get the default clogin to work by creating the proper entry in the
> > .cloginrc file for these hosts;
>
> This is something we're aiming to do (more configurable), but it will be
> after 2.3 which I hope to push out next week sometime.
>
> > OR would I need to hack a xlogin
> > and/or xrancid to get this to work. From your email, sounds like
> > I will have to have a modified xlogin and/or xrancid and I don't know
> > if I need the first, the second or both.
>
> xlogin/xrancid are not for the cisco.
>
>
I ran into this problem too with the current release of RANCID. Here is a very
simple hack that seemed to fix it all for me:
Line 1550 in rancid change from :
system "clogin -t $timeo -c \"$cisco_cmds\" $host </dev/null > $host.raw 2>&1"
|| die "clogin failed for $host: $!\n";
to
system "clogin -t $timeo -c \"$cisco_cmds\" $host </dev/null | sed 's/\>/\#/g' >
$host.raw 2>&1" || die "clogin failed for $host: $!\n";
Also line 1553 needs to change from :
open(INPUT,"clogin -t $timeo -c \"$cisco_cmds\" $host </dev/null |") || die
"clogin failed for $host: $!\n";
to
open(INPUT,"clogin -t $timeo -c \"$cisco_cmds\" $host </dev/null | sed
's/\>/\#/g' |") || die "clogin failed for $host: $!\n";
That should be a nice quick hack for you. Basically, it just changes the prompt
from "$HOSTNAME>" to "$HOSTNAME#", so that RANCID behaves accordingly.
2.5 years after the request is better than never. ;-)
More information about the Rancid-discuss
mailing list