This is a discussion on How to configure NET-SNMP for multiple different Networks within the Networking, Firewalls and Security forums, part of the Mastering Servers category; Hi Well I want to configure Net-snmp for MRTG. But I wana know how to configure com2sec rule in snmpd.conf ...
|
|||||||
| Register | FAQ | Members List | Calendar | Forgotten your password? | Mark Forums Read |
|
|||
|
Hi Well I want to configure Net-snmp for MRTG. But I wana know how to configure com2sec rule in snmpd.conf file for so many different Networks which are configured on routers switches and nodes with the different ranges of network classes.Like /24, /30, /26 ,/28 with the different ranges.And also wana know how to configure MRTG for cpu , disk and memory usage.
|
| Sponsored Links | ||
|
|
|
||||
|
Quote:
Create directory for mrtg grap in Apache webroot: Code:
mkdir /var/www/mrtg Code:
cfgmaker \ --output=/etc/mrtg/traffic.cfg \ --ifdesc=ip \ --ifref=descr \ --global "WorkDir: /var/www/mrtg" \ --global "Options[_]: bits,growright" \ public@localhost Code:
WorkDir: /var/www/mrtg LoadMIBs: /usr/share/snmp/mibs/UCD-SNMP-MIB.txt Target[localhost.cpu]:ssCpuRawUser.0&ssCpuRawUser.0:public@127.0.0.1+ ssCpuRawSystem.0&ssCpuRawSystem.0:public@127.0.0.1+ ssCpuRawNice.0&ssCpuRawNice.0:public@127.0.0.1 RouterUptime[localhost.cpu]: public@127.0.0.1 MaxBytes[localhost.cpu]: 100 Title[localhost.cpu]: CPU Load PageTop[localhost.cpu]: <H1>Active CPU Load %</H1> Unscaled[localhost.cpu]: ymwd ShortLegend[localhost.cpu]: % YLegend[localhost.cpu]: CPU Utilization Legend1[localhost.cpu]: Active CPU in % (Load) Legend2[localhost.cpu]: Legend3[localhost.cpu]: Legend4[localhost.cpu]: LegendI[localhost.cpu]: Active LegendO[localhost.cpu]: Options[localhost.cpu]: growright,nopercent Code:
LoadMIBs: /usr/share/snmp/mibs/HOST-RESOURCES-MIB.txt Target[localhost.mem]: .1.3.6.1.4.1.2021.4.6.0&.1.3.6.1.4.1.2021.4.6.0:public@localhost PageTop[localhost.mem]: <H1>Free Memory</H1> WorkDir: /var/www/mrtg Options[localhost.mem]: nopercent,growright,gauge,noinfo Title[localhost.mem]: Free Memory MaxBytes[localhost.mem]: 1000000 kMG[localhost.mem]: k,M,G,T,P,X YLegend[localhost.mem]: bytes ShortLegend[localhost.mem]: bytes LegendI[localhost.mem]: Free Memory: LegendO[localhost.mem]: Legend1[localhost.mem]: Free memory, not including swap, in bytes Code:
env LANG=C /usr/bin/mrtg /etc/mrtg/cpu.cfg env LANG=C /usr/bin/mrtg /etc/mrtg/memory.cfg env LANG=C /usr/bin/mrtg /etc/mrtg/traffic.cfg Code:
indexmaker --output=/var/www/mrtg \ --title="Server.Domain.Com MRTG" \ --sort=name \ --enumerate \ /etc/mrtg/traffic.cfg \ /etc/mrtg/cpu.cfg \ /etc/mrtg/memory.cfg Code:
crontab -e Code:
*/5 * * * * env LANG=C /usr/bin/mrtg /etc/mrtg/cpu.cfg */5 * * * * env LANG=C /usr/bin/mrtg /etc/mrtg/memory.cfg */5 * * * * env LANG=C /usr/bin/mrtg /etc/mrtg/traffic.cfg |
|
|||
|
Well I ran cfgmaker to create mrtg.cfg file but it gives me an SNMP Error: no response received.The command is as below #cfgmaker --global "workdir: usr/local/www/mrtg/node-01" -ifref=ip --output /usr/local /www/mrtg/node-01/node-01-mrtg.cfg --global 'options[_]: growright,bits' public@node-01 ERROR is as below SNMP Error: no response received SNMPv1_Session (remote host: "node-01" [192.168.10.8].161) community: "endai-snmp" request ID: -736885146 PDU bufsize: 8000 bytes timeout: 2s retries: 5 backoff: 1) at /usr/local/lib/perl5/site_perl/5.8.8/SNMP_util.pm line 627 SNMPWALK Problem for 1.3.6.1.2.1.1 on public@node-01::::::v4only at /usr/local/bin/cfgmaker line 918 WARNING: Skipping public@node-01: as no info could be retrieved ################################################## ### So where could be the problem with this setup and I have also got so many ranges of subnets and network so how to define com2sec source in snmpd.conf file.
Last edited by manish_2479; 06-13-2007 at 01:14 AM.. |
|
||||
|
Configure snmpd as i described eariler
__________________
Rocky Jr. You may have my body & soul, but you will never touch my pride! If you have knowledge, let others light their candles at it. Certified to work on HP-UX / Sun Solaris / RedHat |
![]() |
| Bookmarks |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) |
|
| Thread Tools | |
| Display Modes | |
|
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Problems with perl module Net::SNMP | Jason | Linux software | 1 | 12-28-2007 03:09 AM |
| 1 Router - 3 Networks - Big Help | phatlix | Networking, Firewalls and Security | 0 | 09-06-2007 03:26 PM |
| Python with SNMP Supportq | rcordeiro | Shell scripting | 2 | 12-16-2006 11:48 PM |
| Net-snmp header file | puppen | Linux software | 2 | 05-23-2006 06:45 PM |
| SNMP error CODE | MRTG Mediocre | Linux software | 3 | 03-18-2005 02:05 PM |