#!/usr/bin/perl -w #============================================================================= # # really crappy script to generate a mrtg targets file for pix or fwsm firewall contexts # # Copyright 2006 The University of Wisconsin Board of Regents # Licensed and distributed under the terms of the Perl Artistic # License, see http://net.doit.wisc.edu/~dwcarder/scripts/ for # details. # # Written by: Dale W. Carder, dwcarder@doit.wisc.edu # Network Services Group # Division of Information Technology # University of Wisconsin at Madison # # For more about this and other tools, see # http://net.doit.wisc.edu/~dwcarder/scripts/ # #============================================================================= my @devices = ( 'router-1.example.com', 'router-2.example.com', 'router-3.example.com', 'router-4.example.com', 'router-5.example.com', 'router-6.example.com', ); my $community='public'; my $snmp_fw_conns = '.1.3.6.1.4.1.9.9.147.1.2.2.2.1.5.40.6'; my $snmp_fw_mem = '.1.3.6.1.4.1.9.9.48.1.1.1.5.1'; my $snmp_fw_cpu1m = '.1.3.6.1.4.1.9.9.109.1.1.1.1.4.1'; my $snmp_inoctets = '.1.3.6.1.2.1.2.2.1.10'; my $snmp_outoctets = '.1.3.6.1.2.1.2.2.1.16'; my $snmp_inucastpkts = '.1.3.6.1.2.1.2.2.1.11'; my $snmp_outucastpkts = '.1.3.6.1.2.1.2.2.1.17'; my $head=<$descTarget Name:$target EOM print $paragraph; if ($options) { print "Options[$target]: $options\n"; } print "\n"; };