[rancid] Re: rancid running from cron fails for some devices that canbe manually run

Mike Ashcraft mashcraft at omniture.com
Tue Oct 28 19:09:58 UTC 2008


I had this problem when developing the rancid scripts for F5 that have been posted to this list previously. 

The problem was related to the environment differences between running from the command line and from cron and effects any device that uses a BSD or Linux based OS.  

Look for the differences in the environment between your command line and cron.  TERM is the most likely as this is passed when negotiating the ssh connection to the device.  

In more recent versions of my F5rancid script, I forced the term to 'vt100' before running any commands to resolve this without having to tweak the environment cron uses.

Good luck,

Mike

-----Original Message-----
From: rancid-discuss-bounces at shrubbery.net [mailto:rancid-discuss-bounces at shrubbery.net] On Behalf Of Peter
Sent: Tuesday, October 28, 2008 11:48 AM
To: rancid-discuss at shrubbery.net
Subject: [rancid] rancid running from cron fails for some devices that canbe manually run

HI All,
	I was wondering if anyone has seen an issue like this before. I have  
rancid setup at my work to nightly backup a bunch of cisco routers ,  
switches and 2 F5 load balancers.  I have it set so it's a cron job  
that runs at midnight. Every night when Rancid runs it fails for the  
F5's and succeeds for everything else. What is weird is that if I  
manually run rancid against these devices individually or as the full  
group they succeed. I have tried moving the cron job to a different  
time and also verified that connectivity has not been lost during the  
time it runs. The only constant I have found it that if rancid runs  
from cron it fails for these 2 devices and it succeeds if I run it  
manually.
Has anyone ever seen similar behavior or have any thoughts ?

thanks,

Peter
_______________________________________________
Rancid-discuss mailing list
Rancid-discuss at shrubbery.net
http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss


More information about the Rancid-discuss mailing list