[rancid] Rancid submits random characters after logon - causes config read failure
heasley
heas at shrubbery.net
Fri Sep 12 13:41:40 UTC 2014
Fri, Sep 12, 2014 at 08:03:23AM -0400, Jon Lewis:
> On Fri, 12 Sep 2014, Neil Arnold wrote:
> > I've got an issue with 3 HP Procurve switches. All are running a recent
> > firmware version. The problem is that no config is being pulled from 3 HP
> > switches. in my network, the others give up their config just fine. I've
> > discovered the reason but I'm unsure of how to fix it.
> > The issue is caused because rancid is issuing the following command to the
> > switch after it logs on: ^[[46;148R
> >
> > I can see this by running /bin/clogin 10.100.20.149 and seeing that I get
> > dropped to the following:
> >
> > HP_SWITCH_1# ^[[46;148R
> > HP_SWITCH_1#
> >
> > So Rancid is issuing the manager username and password and then issuing
> > ^[[46;148R which the switch doesn't understand, Rancid, having not received
>
> I have similar problems with clogin and arista gear. In this case, it's
> solved by clearing the TERM environment variable before running clogin.
the garbage text is from the switch, screen manipulation codes. certainly
try hlogin first, but you can also try this patch. without one of these
to poke, it is hard to figure out the fix.
Index: bin/hrancid.in
===================================================================
--- bin/hrancid.in (revision 2859)
+++ bin/hrancid.in (working copy)
@@ -61,6 +61,9 @@
$found_end = 0; # unused - hp lacks an end-of-config tag
$timeo = 90; # hlogin timeout in seconds
+# force a terminal type to work-around a problem seen with HP2910/J9145A
+$ENV{'TERM'} = "vt100";
+
my(@commandtable, %commands, @commands);# command lists
my($aclsort) = ("ipsort"); # ACL sorting mode
my($filter_commstr); # SNMP community string filtering
More information about the Rancid-discuss
mailing list