Install NET-SNMP - B3?
Posted: 18 Apr 2012, 17:08
Hi,
How do I install NET-SNMP, to be able to read ifInOctets and ifOutOctets?
How do I install NET-SNMP, to be able to read ifInOctets and ifOutOctets?
Code: Select all
aptitude install libsnmp-base libsnmp15 snmp snmpd
If you do an.texan wrote:Munin can't draw any graphs if I can't install IF-MIB/NET-SNMP.
Code: Select all
apt-get install munin
Code: Select all
apt-cache search snmp
Ok, to my humble knowledge net-snmp is snmpd.texan wrote:Actually I don't want Munin at all. Read the thread again.
I know how to search the repository. I still can't find the right
package though.
Code: Select all
apt-get install snmpd
jallee wrote:Ok, to my humble knowledge net-snmp is snmpd.texan wrote:Actually I don't want Munin at all. Read the thread again.
I know how to search the repository. I still can't find the right
package though.Code: Select all
apt-get install snmpd
Sure it can. I do it every day. And as all you seem to need is network usage then munin will be a solution. Of course if you prefer whining about not being able to use your preferred solution insteD of being practical and just getting the job done, i cant be of any more help. Even after being commanded to read the thread againtexan wrote:Munin can't draw any graphs if I can't install IF-MIB/NET-SNMP.
Code: Select all
niklas@b3:~$ sudo apt-get install snmpd snmp snmp-mibs-downloader
Code: Select all
rocommunity public localhost
Code: Select all
niklas@b3:~$ sudo /etc/init.d/snmpd restart
Code: Select all
niklas@b3:~$ export MIBS=IF-MIB
niklas@b3:~$ snmpwalk -v 2c -c public 127.0.0.1 | grep -E 'if(In|Out)Octets'
IF-MIB::ifInOctets.1 = Counter32: 6813559
IF-MIB::ifInOctets.2 = Counter32: 2367243795
IF-MIB::ifInOctets.3 = Counter32: 2517069826
IF-MIB::ifInOctets.4 = Counter32: 2436125601
IF-MIB::ifInOctets.5 = Counter32: 4069041910
IF-MIB::ifInOctets.7 = Counter32: 0
IF-MIB::ifInOctets.14 = Counter32: 245148007
IF-MIB::ifOutOctets.1 = Counter32: 6830111
IF-MIB::ifOutOctets.2 = Counter32: 96100640
IF-MIB::ifOutOctets.3 = Counter32: 4200563557
IF-MIB::ifOutOctets.4 = Counter32: 2258954014
IF-MIB::ifOutOctets.5 = Counter32: 220062692
IF-MIB::ifOutOctets.7 = Counter32: 0
IF-MIB::ifOutOctets.14 = Counter32: 0
Hi CheeseboyCheeseboy wrote:Hi texan,
You need to install the MIBS as well, in the snmp-mibs-downloader package:(I think that if you already have a /etc/snmp/snmp.conf file, you have to get rid of the line 'mibs :' or it will not work. I think I just deleted the file...)Code: Select all
niklas@b3:~$ sudo apt-get install snmpd snmp snmp-mibs-downloader
Edit /etc/snmp/snmpd.conf and uncomment this line:Restart snmpd:Code: Select all
rocommunity public localhost
Set the MIBS variable to IF-MIB that you are interested in, or you will have to wait all day:Code: Select all
niklas@b3:~$ sudo /etc/init.d/snmpd restart
Cheers,Code: Select all
niklas@b3:~$ export MIBS=IF-MIB niklas@b3:~$ snmpwalk -v 2c -c public 127.0.0.1 | grep -E 'if(In|Out)Octets' IF-MIB::ifInOctets.1 = Counter32: 6813559 IF-MIB::ifInOctets.2 = Counter32: 2367243795 IF-MIB::ifInOctets.3 = Counter32: 2517069826 IF-MIB::ifInOctets.4 = Counter32: 2436125601 IF-MIB::ifInOctets.5 = Counter32: 4069041910 IF-MIB::ifInOctets.7 = Counter32: 0 IF-MIB::ifInOctets.14 = Counter32: 245148007 IF-MIB::ifOutOctets.1 = Counter32: 6830111 IF-MIB::ifOutOctets.2 = Counter32: 96100640 IF-MIB::ifOutOctets.3 = Counter32: 4200563557 IF-MIB::ifOutOctets.4 = Counter32: 2258954014 IF-MIB::ifOutOctets.5 = Counter32: 220062692 IF-MIB::ifOutOctets.7 = Counter32: 0 IF-MIB::ifOutOctets.14 = Counter32: 0
Cheeseboy