| 1 |
README - cisco_ip_acc_collect.pl |
| 2 |
|
| 3 |
This is cisco_ip_acc_collect.pl V0.9 |
| 4 |
|
| 5 |
This Script gets IP-accounting data from a Cisco Router and generates output |
| 6 |
that can be fed into MRTG. |
| 7 |
|
| 8 |
Configzration: |
| 9 |
-------------- |
| 10 |
|
| 11 |
First of all, I sugest you make a backup of your router config, before |
| 12 |
you configure IP accounting and run this script... If something happens, |
| 13 |
I've told you ... |
| 14 |
|
| 15 |
In the networks you can enter the networks you like to analyse in the |
| 16 |
following form: |
| 17 |
|
| 18 |
xxx.xxx.xxx.xxx/CDIR Name |
| 19 |
|
| 20 |
xxx.xxx.xxx.xxx is the IP Adress of the Network |
| 21 |
|
| 22 |
CDIR is the CDIR Bitmask |
| 23 |
/32 = 255.255.255.255 |
| 24 |
/24 = 255.255.255.0 |
| 25 |
/16 = 255.255.0.0 etc. |
| 26 |
|
| 27 |
Name Is the name of the network. |
| 28 |
This name can apear more than once. |
| 29 |
The traffic of all networks that have same |
| 30 |
name will be added into one output. |
| 31 |
|
| 32 |
In the .pl file you have to change some variables. See the .pl file for more |
| 33 |
informations. |
| 34 |
|
| 35 |
In the mrtg config file you can enter something like this: |
| 36 |
|
| 37 |
Target[tagretname]: `cat /usr/local/mrtg/cisco_ipaccounting/log_test` |
| 38 |
|
| 39 |
Running this script: |
| 40 |
-------------------- |
| 41 |
|
| 42 |
I start this script with cron, yost before mrtg like this: |
| 43 |
|
| 44 |
*/5 * * * * cramer /usr/local/mrtg/cisco_ipaccounting/collect.pl ; /usr/local/mrtg/mrtg /usr/local/mrtg/accounting.conf |
| 45 |
|
| 46 |
Where to get updates: |
| 47 |
--------------------- |
| 48 |
|
| 49 |
You can download new versions from ftp://ftp.dolphins.ch/pub/Dolphins/mrtg |
| 50 |
|
| 51 |
|
| 52 |
Copyrigth & Warranty: |
| 53 |
--------------------- |
| 54 |
|
| 55 |
This script is |
| 56 |
(c) 1999 by Dolphins Network Systems, Matthias Cramer |
| 57 |
|
| 58 |
This program is free software; you can redistribute it and/or modify it |
| 59 |
under the terms of the GNU General Public License as published by the Free |
| 60 |
Software Foundation; either version 2 of the License, or (at your option) |
| 61 |
any later version. |
| 62 |
|
| 63 |
This program is distributed in the hope that it will be useful, but WITHOUT |
| 64 |
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
| 65 |
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for |
| 66 |
more details. |
| 67 |
|
| 68 |
You should have received a copy of the GNU General Public License along |
| 69 |
with this program; if not, write to the Free Software Foundation, Inc., 675 |
| 70 |
Mass Ave, Cambridge, MA 02139, USA. |