Bug 386611

Summary: snmpd segfaults on xen network interfaces
Product: [Fedora] Fedora Reporter: Erik Logtenberg <erik>
Component: net-snmpAssignee: Jan Safranek <jsafrane>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: low    
Version: 8   
Target Milestone: ---   
Target Release: ---   
Hardware: ia64   
OS: Linux   
Whiteboard:
Fixed In Version: 5.4.1-5.fc8 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-11-26 18:54:34 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Erik Logtenberg 2007-11-16 10:40:15 UTC
Description of problem:

snmpd segfaults on startup when it detects the network interfaces that are
configured by the XEN initscripts. There seems to be a patch available already,
found here:
http://sourceforge.net/tracker/index.php?func=detail&aid=1794532&group_id=12694&atid=112694

Would it be possible to apply this patch to the net-snmp package shipped with
Fedora 8?

Version-Release number of selected component (if applicable):
net-snmp-5.4.1-4.fc8

How reproducible:
Always.

Steps to Reproduce:
1. Install XEN and net-snmp
2. Start them both
  
Actual results:
Nov 16 11:11:59 xen2 kernel: sky2 eth0: disabling interface
Nov 16 11:11:59 xen2 kernel: sky2 peth0: enabling interface
Nov 16 11:11:59 xen2 kernel: sky2 peth0: ram buffer 48K
Nov 16 11:11:59 xen2 kernel: ADDRCONF(NETDEV_UP): peth0: link is not ready
Nov 16 11:12:00 xen2 kernel: sky2 peth0: Link is up at 100 Mbps, full duplex,
flow control both
Nov 16 11:12:00 xen2 kernel: ADDRCONF(NETDEV_CHANGE): peth0: link becomes ready
Nov 16 11:12:01 xen2 kernel: device peth0 entered promiscuous mode
Nov 16 11:12:01 xen2 kernel: eth0: port 1(peth0) entering learning state
Nov 16 11:12:01 xen2 kernel: eth0: topology change detected, propagating
Nov 16 11:12:01 xen2 kernel: eth0: port 1(peth0) entering forwarding state
Nov 16 11:12:09 xen2 snmpd[1741]: error scanning interface data (expected 10, got 0)
Nov 16 11:12:09 xen2 snmpd[1741]: netsnmp_assert index == tmp failed
if-mib/data_access/interface.c:469 _access_interface_entry_save_name()
Nov 16 11:12:09 xen2 snmpd[1741]: netsnmp_assert rc == 0 failed
if-mib/ifTable/ifTable_data_access.c:210 _check_interface_entry_for_updates()
Nov 16 11:12:11 xen2 apcupsd[1785]: apcupsd 3.14.2 (15 September 2007) redhat
startup succeeded
Nov 16 11:12:24 xen2 snmpd[1741]: error scanning interface data (expected 10, got 0)
Nov 16 11:12:24 xen2 snmpd[1741]: netsnmp_assert index == tmp failed
if-mib/data_access/interface.c:469 _access_interface_entry_save_name()
Nov 16 11:12:24 xen2 snmpd[1741]: netsnmp_assert rc == 0 failed
if-mib/ifTable/ifTable_data_access.c:210 _check_interface_entry_for_updates()
Nov 16 11:12:24 xen2 snmpd[1741]: Duplicate IP address detected, some interfaces
may not be visible in IP-MIB
Nov 16 11:12:24 xen2 kernel: snmpd[1741]: segfault at 0000000000000098 rip
00002aaaab18c979 rsp 00007fff810bd7a0 error 4

Expected results:
No segfault :)

Additional info:
In the original bugreport on net-snmp's sourceforge page, only 32bits
architecture is mentioned to be affected. I'm using 64bits architecture however,
but I run into what seems to be the same problem.

Comment 1 Jan Safranek 2007-11-16 11:48:25 UTC
I do not have XEN with F8 available, so I need your help. I added the patch,
could you please test, if it works for you?

You can find the build at
http://koji.fedoraproject.org/scratch/jsafrane/task_244712/. Be sure to update
both net-snmp and net-snmp-libs.

Comment 2 Erik Logtenberg 2007-11-16 13:21:24 UTC
Thank you very much for your swift reply. I'll try to test it this night.


Comment 3 Erik Logtenberg 2007-11-17 10:09:46 UTC
I'm happy to confirm that the patch fixed this issue. snmpd is running fine now.
Thanks.


Comment 4 Szombathelyi György 2007-11-17 11:21:41 UTC
The same problem was here, and the test packages work!

Comment 5 Fedora Update System 2007-11-20 17:49:46 UTC
net-snmp-5.4.1-5.fc8 has been pushed to the Fedora 8 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update net-snmp'

Comment 6 Daniel Chen 2007-11-20 23:11:07 UTC
This did happen all the time. However, it just has below errors after I bounded 
MAC to two NICs and restarted the server.

snmpd[1772]: Received TERM or STOP signal...  shutting down...
snmpd[2624]: netsnmp_assert !"registration != duplicate" failed 
agent_registry.c:535 netsnmp_subtree_load()
snmpd[2624]:last message repeated 2 times
snmpd[2624]: Duplicate IP address detected, some interfaces may not be visible 
in IP-MIB
snmpd[2624]: NET-SNMP version 5.4.1

Comment 7 Jan Safranek 2007-11-23 13:30:30 UTC
forgot to set the modified state...

Comment 8 Fedora Update System 2007-11-26 18:54:32 UTC
net-snmp-5.4.1-5.fc8 has been pushed to the Fedora 8 stable repository.  If problems still persist, please make note of it in this bug report.