[rancid] How to extend Rancid. Basics.
jm+rancid at roth.lu
Sat Aug 1 16:46:04 UTC 2015
Alan McKinnon <alan.mckinnon <at> gmail.com> writes:
> On 01/08/2015 13:30, Alex DEKKER wrote:
> > On 01/08/15 10:48, jm+rancid <at> roth.lu wrote:
> >> Hi there,
> >> I wanted to extend Rancid with a script to monitor some Checkpoint
> >> Gaia firewalls.
> It's not that simple, there is no "master reference device type" so to
> Here's how rancid works:
Ok, as I thought, you just give rancid some text to store.
For non-perl gurus, the modern modular method is complicated. In fact, the
regexes you are talking about are specific to that I believe. As are
variables like $found_end and $clean_run that seem to be important to talk
to the main process. (Or is it just the return codes?)
Nothing will however prevent me from using the "old" method, give it a
"script" and a "login" (in the types file).
"login" can be, well, expect the login prompt, send the username, etc. you
get it. The "script" can be a stupid expect script running "show
configuration" and capturing the output. Maybe with some wrapper in a
language one is fluent in around it to carry out additional checks.
Don't get me wrong. It's great that the "modern method" to use rancid is
more modular (also less code duplication like with copying scripts etc.). It
could however be interesting to have some abstract configuration file where
you just tell it what to do, what to expect as a return, what to treat as
error. Much like "expect" in itself, but simpler, because in that case you'd
need to be a TCL guru. I'm thinking more along the lines of an INI file or
More information about the Rancid-discuss