automating non-config actions?
john heasley
heas at shrubbery.net
Sat Jan 12 22:34:25 UTC 2002
Sat, Jan 12, 2002 at 05:06:33PM -0500, Andrew Partan:
> On Sat, Jan 12, 2002 at 01:05:50PM -0800, Avram Dorfman wrote:
> > Has anyone thought about modifying rancid to make it a batch
> > utility for executing arbitrary actions on lots of routers?
>
> Look at clogin - its already does a lot of what you want.
> --asp
btw, clogin is cisco (more or less) specific at this point. a simple
shell script would whack that for you. eg:
cd /usr/local/rancid
for router in `cat */router.db`
do
oldFS=$IFS
IFS=:
set $router
IFS=$oldFS
if [ "$3" == "up" ] ; then
if [ "$2" != "juniper"] ; then
jlogin -s jnx_script $1
else
clogin -s cisco_script $1
fi
fi
done
More information about the Rancid-discuss
mailing list