[rancid] new rancid install not working

Alan McKinnon alan.mckinnon at gmail.com
Fri Apr 17 23:05:14 UTC 2015


On 18/04/2015 00:41, Jeffrey d'Ambly wrote:
> I cannot for the life of me figure out what I’m doing wrong here.
> 
> When I run /usr/bin/rancid-run it seems like nothing happens. When I run
> rancid manually I get the following
> 
> qa-scl009-005:/var/rancid# /usr/bin/rancid -d -t cisco sjc-vpe1
> 
> loadtype: device type cisco
> 
> loadtype: found device type cisco in /etc/rancid/rancid.types.base
> 
> executing clogin -t 90 -c"show version;show redundancy;show idprom
> backplane;show install active;show env all;show rsp chassis-info;show
> gsr chassis;show diag chassis-info;show boot;show bootvar;show variables
> boot;show flash;dir /all nvram:;dir /all bootflash:;dir /all slot0:;dir
> /all disk0:;dir /all slot1:;dir /all disk1:;dir /all slot2:;dir /all
> disk2:;dir /all harddisk:;dir /all harddiska:;dir /all harddiskb:;dir
> /all sup-bootdisk:;dir /all sup-bootflash:;dir /all sup-microcode:;dir
> /all slavenvram:;dir /all slavebootflash:;dir /all slaveslot0:;dir /all
> slavedisk0:;dir /all slaveslot1:;dir /all slavedisk1:;dir /all
> slaveslot2:;dir /all slavedisk2:;dir /all slavesup-bootflash:;dir /all
> sec-nvram:;dir /all sec-bootflash:;dir /all sec-slot0:;dir /all
> sec-disk0:;dir /all sec-slot1:;dir /all sec-disk1:;dir /all
> sec-slot2:;dir /all sec-disk2:;show controllers;show controllers
> cbus;show diagbus;show diag;show capture;show module;show spe
> version;show c7200;show inventory raw;show vtp status;show vlan;show
> vlan-switch;show switch detail;show sdm prefer;show system mtu;show
> debug;show shun;more system:running-config;show running-config view
> full;show running-config;write term" sjc-vpe1
> 
> sh: clogin: command not found


This is your problem. When you run rancid manually you provided the full
path. When you ran clogin manually, you provided the full path.

When rancid-run calls rancid which calls clogin, it does not provide the
full path.

What you need to do is define $PATH to include the location of the
*login scripts (/usr/libexec/rancid apparently) in the login shell of
the user rancid runs as.

Incidentally, you are doing your tests as root. You should not run
rancid as root, rather run it as a rancid user




-- 
Alan McKinnon
alan.mckinnon at gmail.com



More information about the Rancid-discuss mailing list