Hi all,
I have a system with a nios2 and a network interface (Altera Triple speed Ethernet MAC).
I use 2.6.30 kernel on my board and net-snmp 5.2.1.
I can see my network interfaces using ifconfig :
--- Quote Start ---
/# ifconfig
eth0 Link encap:Ethernet HWaddr 00:15:12:00:15:88
inet addr:192.168.0.110 Bcast:192.168.0.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:1400 errors:0 dropped:681 overruns:0 frame:0
TX packets:400 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:205531 (200.7 KiB) TX bytes:33239 (32.4 KiB)
Base address:0x400
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
--- Quote End ---
So the systems know interface statistics.
But I wonder why net-snmp is not able to handle these statistics automatically.
I have the following :
--- Quote Start ---
/# snmpwalk -v 1 -c public 192.168.0.110 1
iso.3.6.1.2.1.1.1.0 = STRING: "XXX"
iso.3.6.1.2.1.1.2.0 = OID: ccitt.1
iso.3.6.1.2.1.1.3.0 = Timeticks: (115) 0:00:01.15
iso.3.6.1.2.1.1.4.0 = STRING: "System Contact (configurable)"
iso.3.6.1.2.1.1.5.0 = STRING: "System Name (configurable)"
iso.3.6.1.2.1.1.6.0 = STRING: "System Location (configurable)"
iso.3.6.1.2.1.1.7.0 = INTEGER: 2
iso.3.6.1.2.1.1.8.0 = Timeticks: (7) 0:00:00.07
iso.3.6.1.2.1.1.9.1.2.1 = OID: iso.3.6.1.6.3.1
iso.3.6.1.2.1.1.9.1.2.2 = OID: iso.3.6.1.6.3.16.2.2.1
iso.3.6.1.2.1.1.9.1.2.3 = OID: iso.3.6.1.6.3.10.3.1.1
iso.3.6.1.2.1.1.9.1.2.4 = OID: iso.3.6.1.6.3.11.3.1.1
iso.3.6.1.2.1.1.9.1.2.5 = OID: iso.3.6.1.6.3.15.2.1.1
iso.3.6.1.2.1.1.9.1.3.1 = STRING: "The MIB module for SNMPv2 entities"
iso.3.6.1.2.1.1.9.1.3.2 = STRING: "View-based Access Control Model for SNMP."
iso.3.6.1.2.1.1.9.1.3.3 = STRING: "The SNMP Management Architecture MIB."
iso.3.6.1.2.1.1.9.1.3.4 = STRING: "The MIB for Message Processing and Dispatching."
iso.3.6.1.2.1.1.9.1.3.5 = STRING: "The management information definitions for the SNMP User-based Security Model."
iso.3.6.1.2.1.1.9.1.4.1 = Timeticks: (5) 0:00:00.05
iso.3.6.1.2.1.1.9.1.4.2 = Timeticks: (6) 0:00:00.06
iso.3.6.1.2.1.1.9.1.4.3 = Timeticks: (6) 0:00:00.06
iso.3.6.1.2.1.1.9.1.4.4 = Timeticks: (6) 0:00:00.06
iso.3.6.1.2.1.1.9.1.4.5 = Timeticks: (7) 0:00:00.07
iso.3.6.1.2.1.11.1.0 = Counter32: 24
iso.3.6.1.2.1.11.2.0 = Counter32: 25
iso.3.6.1.2.1.11.3.0 = Counter32: 0
iso.3.6.1.2.1.11.4.0 = Counter32: 0
iso.3.6.1.2.1.11.5.0 = Counter32: 0
iso.3.6.1.2.1.11.6.0 = Counter32: 0
iso.3.6.1.2.1.11.8.0 = Counter32: 0
iso.3.6.1.2.1.11.9.0 = Counter32: 0
iso.3.6.1.2.1.11.10.0 = Counter32: 0
iso.3.6.1.2.1.11.11.0 = Counter32: 0
iso.3.6.1.2.1.11.12.0 = Counter32: 0
iso.3.6.1.2.1.11.13.0 = Counter32: 34
iso.3.6.1.2.1.11.14.0 = Counter32: 0
iso.3.6.1.2.1.11.15.0 = Counter32: 0
iso.3.6.1.2.1.11.16.0 = Counter32: 38
iso.3.6.1.2.1.11.17.0 = Counter32: 0
iso.3.6.1.2.1.11.18.0 = Counter32: 0
iso.3.6.1.2.1.11.19.0 = Counter32: 0
iso.3.6.1.2.1.11.20.0 = Counter32: 0
iso.3.6.1.2.1.11.21.0 = Counter32: 0
iso.3.6.1.2.1.11.22.0 = Counter32: 0
iso.3.6.1.2.1.11.24.0 = Counter32: 0
iso.3.6.1.2.1.11.25.0 = Counter32: 0
iso.3.6.1.2.1.11.26.0 = Counter32: 0
iso.3.6.1.2.1.11.27.0 = Counter32: 0
iso.3.6.1.2.1.11.28.0 = Counter32: 48
iso.3.6.1.2.1.11.29.0 = Counter32: 1
iso.3.6.1.2.1.11.30.0 = INTEGER: 2
iso.3.6.1.2.1.11.31.0 = Counter32: 0
iso.3.6.1.2.1.11.32.0 = Counter32: 0
iso.3.6.1.4.1.8072.2.1.1.0 = INTEGER: 43
iso.3.6.1.6.3.10.2.1.1.0 = Hex-STRING: 80 00 1F 88 80 28 B8 EF 53 96 13 43 38
iso.3.6.1.6.3.10.2.1.2.0 = INTEGER: 6
iso.3.6.1.6.3.10.2.1.3.0 = INTEGER: 1
iso.3.6.1.6.3.10.2.1.4.0 = INTEGER: 1500
iso.3.6.1.6.3.11.2.1.1.0 = Counter32: 0
iso.3.6.1.6.3.11.2.1.2.0 = Counter32: 0
iso.3.6.1.6.3.11.2.1.3.0 = Counter32: 0
iso.3.6.1.6.3.15.1.1.1.0 = Counter32: 0
iso.3.6.1.6.3.15.1.1.2.0 = Counter32: 0
iso.3.6.1.6.3.15.1.1.3.0 = Counter32: 0
iso.3.6.1.6.3.15.1.1.4.0 = Counter32: 0
iso.3.6.1.6.3.15.1.1.5.0 = Counter32: 0
iso.3.6.1.6.3.15.1.1.6.0 = Counter32: 0
iso.3.6.1.6.3.15.1.2.1.0 = INTEGER: 0
iso.3.6.1.6.3.16.1.1.1.1.0 = ""
[...]
--- Quote End ---
So it is ok for the system mibs and some other infos, but nothing about my network interface (eth0)...
My (simple) config :
--- Quote Start ---
rwcommunity private
rocommunity public
sysServices 2
sysDescr XXX
interface eth0 6 100000000
--- Quote End ---
As you can see I tried to add "interface eth0 6 100000000" to my conf file but it is not recognized by this version of net-snmp
I can't figure out if net-snmp is able to "automatically" retrieve network interface, or if my issue is related to the nios2 linux environment I use. I googled a lot for nothing.
Do I need to add a MIB in menuconfig (I tried mibII/ifTable mibII/interface mibII Rmon if-mib...) ?
Do you have any idea ?
Thanks