Title: 5.2.1(and 5.2.2) + MontaVista 4.0.1 (linux kernel 2.6.10) = kernel Oops

I am seeing a crash on startup trying to run snmpd from net-snmp 5.2.1 on MontaVista 4.0.1 (linux kernel 2.6.10) that *appears* to be in the ioctl calls to get the interface speed.  The end of the output with -V and -DALL is:

trace: netsnmp_access_interface_entry_create(): if-mib/data_access/interface_common.c, 272:
access:interface:entry: create
trace: netsnmp_access_interface_index_find(): if-mib/data_access/interface_common.c, 192:
access:interface:find: index
trace: netsnmp_access_interface_ioctl_ifindex_get(): if-mib/data_access/interface_ioctl.c, 382:
access:interface:ioctl: mtu_get
trace: _ioctl_get(): if-mib/data_access/interface_ioctl.c, 42:
verbose:access:interface:ioctl: ioctl 35123 for eth0
trace: _access_interface_entry_save_name(): if-mib/data_access/interface_common.c, 404:
access:interface:ifIndex: saved ifIndex 2 for eth0
trace: netsnmp_access_interface_ioctl_physaddr_get(): if-mib/data_access/interface_ioctl.c, 97:
access:interface:ioctl: physaddr_get
trace: _ioctl_get(): if-mib/data_access/interface_ioctl.c, 42:
verbose:access:interface:ioctl: ioctl 35111 for eth0
trace: netsnmp_arch_interface_get_if_speed(): if-mib/data_access/interface_linux.c, 416:
mibII/interfaces: SIOCGMIIREG on eth0 failed
Segmentation fault

When run with strace, the following are the last lines that appear before the crash:

socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 10
ioctl(10, SIOCGIFINDEX, {ifr_name="lo", ifr_index=1}) = 0
close(10)                               = 0
ioctl(9, SIOCGIFHWADDR, {ifr_name="lo", ifr_hwaddr=00:00:00:00:00:00}) = 0
ioctl(9, SIOCGIFFLAGS, {ifr_name="lo", ifr_flags=IFF_UP|IFF_LOOPBACK|IFF_RUNNING}) = 0
ioctl(9, SIOCGIFMTU, {ifr_name="lo", ifr_mtu=16436}) = 0
socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 10
ioctl(10, SIOCGIFINDEX, {ifr_name="eth0", ifr_index=2}) = 0
close(10)                               = 0
ioctl(9, SIOCGIFHWADDR, {ifr_name="eth0", ifr_hwaddr=00:15:b1:00:01:82}) = 0
ioctl(9, SIOCGMIIPHY, 0xbfffe900)       = -1 EOPNOTSUPP (Operation not supported)
ioctl(9, SIOCDEVPRIVATE, 0xbfffe900)    = 0
ioctl(9, 0x89f1, 0xbfffe900)            = -1 EOPNOTSUPP (Operation not supported)
ioctl(9, 0x89f1 <unfinished ...>
+++ killed by SIGSEGV +++


When snmpd segfaults, the following Oops message appears on the console:

BUG: Unable to handle kernel paging request at virtual address 0001000c
 printing eip:
d0823715
*pde = 00000000
Oops: 0002 [#1]
PREEMPT
Modules linked in: 8021q bridge aca_prefw ks8842_pci
CPU:    0
EIP:    0060:[<d0823715>]    Not tainted VLI
EFLAGS: 00010206   (2.6.10_mvl401-pc_target)
EIP is at netdev_ioctl+0x45/0x130 [ks8842_pci]
eax: 00000000   ebx: 00010000   ecx: 0000000b   edx: 000089f1
esi: c1295280   edi: c12952e8   ebp: ffffffa1   esp: cd543ec8
ds: 007b   es: 007b   ss: 0068   preempt: 00000001
Process snmpd (pid: 851, threadinfo=cd542000 task=cccf7a00)
Stack: 00000000 c1295000 000089f1 ffffffed cd543f10 c0238656 c1295000 cd543f10
       000089f1 cd543f10 00000001 000089f1 00000000 c02389c2 cd543f10 000089f1
       cd543f10 c02e0c0c 30687465 00000000 00000000 00000000 00010000 b7f90734
Call Trace:
 [<c0238656>] dev_ifsioc+0x116/0x3d0 (24)
 [<c02389c2>] dev_ioctl+0xb2/0x260 (32)
 [<c022e10b>] sock_ioctl+0x5b/0x240 (68)
 [<c015df26>] do_ioctl+0x46/0x70 (20)
 [<c015e113>] vfs_ioctl+0x53/0x1c0 (36)
 [<c015e2ad>] sys_ioctl+0x2d/0x50 (36)
 [<c01023b7>] syscall_call+0x7/0xb (36)
Code: 04 08 00 00 8b 44 24 1c 8d 7e 68 8b 58 10 c7 04 24 00 00 00 00 74 1f 81 f


I noticed the supported operating systems lists 2.4 as the most recent supported linux kernel, so I tried 5.2.2 (which does claim to support 2.6), but this suffered the same problem.  Any idea what might be wrong?

FWIW, here is the command line used to run snmpd:

   /usr/local/sbin/snmpd -V -DALL -f -L -A -C -c /etc/plc.config/snmp/snmpd.conf udp:8161

Thank you,
Mark Little

Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Net-snmp-users mailing list
[email protected]
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Reply via email to