CiscoTools Installation Guide

User "root" Installation

CiscoTools Installation Steps

The following commands are based on the assumption that

If your apache uses different directories, the easiest way to get this resolved is to create symbolic links pointing to the actual directories.


htdocs directory is /var/www and cgi-bin directory is /usr/lib/cgi-bin

if [ ! -d /srv ] ; then mkdir /srv ; fi
if [ ! -d /srv/www ; then mkdir /srv/www ; fi
ln -s /var/www /srv/www/htdocs
ln -s /usr/lib/cgi-bin /srv/www/cgi-bin

Now we can go on.

# create user cisco with home directory /home/cisco before doing this
cd / ; tar xfvz CiscoTools-yyyy-mm-dd-vvv.tgz

# correct owner and permission on files
chown -R cisco /home/cisco
chmod 700 /home/cisco

chown -R cisco /srv/www/htdocs/cisco
chown -R cisco /srv/www/cgi-bin/cisco
yyyy-mm-dd-vvv means yyyy (year), mm (month), dd (day), vvv (version)

apache Configuration

apache may need some configuration, too.
If cgi-bin scripts don't work right away insert the following lines:

/etc/httpd/conf/httpd.conf (hopefully)

<Directory "/srv/www/cgi-bin/cisco">
AllowOverride All
Options None
Order allow,deny
Allow from all
If you change apache configuration files please restart apache to let those changes take effect. Depending on your operating system and distributor this may look something like this:
/etc/init.d/apache2 restart

User "cisco" Installation

CiscoTools Configuration

For this example we assume location HQ to be the first location.

# make working copies of configuration files
cd /home/cisco/access
cp cisco-routers-LOCATION cisco-routers-HQ
chmod 600 cisco-routers-HQ
cp cisco-switches-LOCATION cisco-switches-HQ
chmod 600 cisco-switches-HQ

# edit list of routers
vi cisco-routers-HQ

# edit list of switches
vi cisco-switches-HQ

# this is mandatory - create location for cgi scripts
cd /srv/www/cgi-bin/cisco
mkdir HQ
chmod 755 HQ

cp portmaps-EXAMPLE.txt HQ/portmaps.txt
chmod 644 HQ/portmaps.txt

# document all switch interconnections
vi HQ/portmaps.txt

# this is optional
cp ignorearp-EXAMPLE.txt HQ/ignorearp.txt
chmod 644 HQ/ignorearp.txt
vi HQ/ignorearp.txt

# this is optional
cp ignoremac-EXAMPLE.txt HQ/ignoremac.txt
chmod 644 HQ/ignoremac.txt
vi HQ/ignoremac.txt

# this is optional
cp ipblocks-EXAMPLE.txt HQ/ipblocks.txt
chmod 644 HQ/ipblocks.txt
vi HQ/ipblocks.txt

If the apache root directory is not "/srv/www" and you don't want to use symbolic links as described above you may modify the following configuration files/scripts:

Document those changes for they have to be reapplied after each CiscoTools update. This is not recommended.

crontab entries for user "cisco" should look like this:

*/5 * * * * /home/cisco/bin/arplog-all HQ >/dev/null 2>/dev/null
*/5 * * * * /home/cisco/bin/maclog-all HQ >/dev/null 2>/dev/null
You may use crontab -e to edit your crontab entries.