[rancid] missed cmds, but only when run from cron

Paul Gear paul at gear.dyndns.org
Wed Aug 14 04:05:28 UTC 2013


On 08/14/2013 10:22 AM, Brent Wiese wrote:
> This is boggling my mind.
>
> I slightly modified the f5rancid script to work with their version 11
> TMOS. Basically, all it does is “show running-config” and then runs
> “quit” instead of “exit” when it finds the prompt.
>
> This has been working just fine for our existing load balancers. But we
> recently added a new set. The first run appears to work. Then I start
> getting this in the logs:
>
> starting: Tue Aug 13 17:02:11 MST 2013
>
> cvs add: lb01.my.domain already exists, with version number 1.4
>
> Added lb01.my.domain
>
> Trying to get all of the configs.
>
> lb01.my.domain: (v11) missed cmd(s): show running-config
>
> lb01.my.domain: (v11) End of run not found
>
> #
>
> I don’t get it – if I run f5rancid_v11 (my modified copy), it runs just
> fine and the “.new” file is there with all the info I need. It’s only
> when it’s run from cron that it throws any kind of error. F5login runs
> fine too (or f5rancid_v11 would fail). I added the “(v11)” in the log
> line area to confirm it’s running the correct script when it does
> rancid-run.
>
> Since it’s logging errors, I don’t think it’s any kind of permissions
> error. But I am running as the same user as the cron job.
>
> All my other configs are coming in and diff’ing just fine, so I don’t
> think it’s a CVS issue (or the ability to write temp files for example).

I'm seeing something very similar with one Mikrotik device out of 17 on 
our network.  If run from the command line, it works fine.  If run from 
cron, one router in the group fails, giving the following error log:

> starting: Tue Aug 13 00:01:32 EST 2013
>
>
>
> Trying to get all of the configs.
> failing-router-name: missed cmd(s): system package print detail without-paging
> =====================================
> Getting missed routers: round 1.
> failing-router-name: missed cmd(s): system package print detail without-paging
> =====================================
> Getting missed routers: round 2.
> failing-router-name: missed cmd(s): system package print detail without-paging
> =====================================
> Getting missed routers: round 3.
> failing-router-name: missed cmd(s): system package print detail without-paging
> =====================================
> Getting missed routers: round 4.
> failing-router-name: missed cmd(s): system package print detail without-paging
>
>
> ending: Tue Aug 13 00:02:30 EST 2013


Here's the successful run's log:
>
> starting: Tue Aug 13 16:48:37 EST 2013
>
>
>
> Trying to get all of the configs.
> All routers sucessfully completed.
>
>
> ending: Tue Aug 13 16:48:46 EST 2013

Looks like there might be some type of logic bug that is present in more 
than one place.

Paul




More information about the Rancid-discuss mailing list