[rancid] Re: "End of run not found" troubleshooting

Aaron Smith smitha at byui.edu
Thu Oct 18 21:27:10 UTC 2007


On Thu, 2007-10-18 at 15:47 -0500, Sam Munzani wrote:
> Any suggestions on how should I start my troubleshooting? Any debug 
> flags etc.

I had a similar problem when grabbing configs off Catalyst 4006 devices
running CatOS.  If you look at the last lines in cat5rancid (or rancid),
you see:

# check for completeness
if (scalar(%commands) || !$clean_run || !$found_end) {
    if (scalar(%commands)) {
        printf(STDOUT "$host: missed cmd(s): %s\n", join(',', keys(%
commands)));
        printf(STDERR "$host: missed cmd(s): %s\n", join(',', keys(%
commands))) if ($debug);
    }
    if (!$clean_run || !$found_end) {
        print STDOUT "$host: End of run not found\n";
        print STDERR "$host: End of run not found\n" if ($debug);
        system("/usr/bin/tail -1 $host.new");
    }
    unlink "$host.new" if (! $debug);
}

I recommend you print out the value of $clean_run and $found_end.  That
tells you which is causing the problem.  In my case, it was $clean_run.
For some reason it wasn't seeing the completed "exit" command, and thus
wouldn't back up the config.  Until I get time to dig in further and
find the root cause, I inserted these lines before the code block above:

# I don't care if it sees "exit"
$clean_run = 1;

Works for now, maybe forever.

-- 
@@ron Smith
IT Infrastructure
BYU Idaho


More information about the Rancid-discuss mailing list