Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1105441

Summary: Segmentation fault when starting libvirt snmp agent daemon after executing "yum update"
Product: Red Hat Enterprise Linux 6 Reporter: Hu Jianwei <jiahu>
Component: libvirt-snmpAssignee: Michal Privoznik <mprivozn>
Status: CLOSED WONTFIX QA Contact: Virtualization Bugs <virt-bugs>
Severity: high Docs Contact:
Priority: high    
Version: 6.6CC: dyuan, honzhang, jsuchane, mzhan, rbalakri
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-11-26 14:28:39 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
yum update log none

Description Hu Jianwei 2014-06-06 06:52:43 UTC
Created attachment 902780 [details]
yum update log

Description of problem:
Segmentation fault when starting libvirt snmp agent daemon after executing "yum update"

Version-Release number of selected component (if applicable):
libvirt-snmp-0.0.2-4.el6.x86_64
libvirt-0.10.2-37.el6.x86_64

net-snmp-libs-5.5-49.el6_5.1.x86_64
net-snmp-5.5-49.el6_5.1.x86_64
libvirt-snmp-0.0.2-4.el6.x86_64
libvirt-snmp-debuginfo-0.0.2-4.el6.x86_64
net-snmp-utils-5.5-49.el6_5.1.x86_64

Steps to Reproduce:
1. yum install net-snmp net-snmp-libs net-snmp-utils libvirt-snmp libvirt-snmp-debuginfo

2.[root@rhel6 net-snmp]# cat /etc/snmp/snmpd.conf
rwcommunity public
master agentx
trapcommunity public
trap2sink  localhost

3.[root@rhel6 net-snmp]# cat /etc/snmp/snmptrapd.conf
# Example configuration file for snmptrapd
#
# No traps are handled by default, you must edit this file!
#
# authCommunity   log,execute,net public
# traphandle SNMPv2-MIB::coldStart    /usr/bin/bin/my_great_script cold
authCommunity log,execute,net public
logOption f /var/log/snmptraps.log

4.Upgrade all packages using "yum update"(This is key step!)

5.[root@rhel6 net-snmp]# service snmpd restart
Stopping snmpd:                                            [  OK  ]
Starting snmpd:                                            [  OK  ]
[root@rhel6 net-snmp]# service snmptrapd restart
Stopping snmptrapd:                                        [  OK  ]
Starting snmptrapd:                                        [  OK  ]

6.[root@rhel6 net-snmp]# LIBVIRT_DEFAULT_URI="qemu:///system" libvirtMib_subagent -f -L
Segmentation fault (core dumped)

Actual results:
As shown above steps, libvirt snmp daemon core dumped.

(gdb) info threads
* 1 Thread 0x7fa6f391f800 (LWP 8142)  __libc_free (mem=0x71) at malloc.c:3714
(gdb) bt
#0  __libc_free (mem=0x71) at malloc.c:3714
#1  0x00000033368598e9 in virFree (ptrptr=0x1dc2058) at util/memory.c:419
#2  0x000000333687144b in virResetError (err=0x1dc2030) at util/virterror.c:324
#3  0x0000003336850ce2 in virEventRegisterDefaultImpl () at util/event.c:206
#4  0x0000000000406125 in libvirtSnmpInit () at libvirtSnmp.c:324
#5  0x0000000000405584 in libvirtGuestTable_container_init (container_ptr_ptr=0x610060, cache=0x1dca8c0) at libvirtGuestTable_data_access.c:138
#6  0x0000000000409c7b in _libvirtGuestTable_container_init (reg_ptr=0x1dca3f0, flags=<value optimized out>) at libvirtGuestTable_interface.c:1644
#7  _libvirtGuestTable_initialize_interface (reg_ptr=0x1dca3f0, flags=<value optimized out>) at libvirtGuestTable_interface.c:202
#8  0x0000000000406ec8 in main (argc=3, argv=<value optimized out>) at libvirtMib_subagent.c:158
(gdb)

[root@amd-5200-4-2 ~]# cat /var/log/messages
Jun  6 14:37:42 amd-5200-4-2 kernel: libvirtMib_suba[4600]: segfault at 69 ip 00007f202d11382c sp 00007fff9d69f278 error 4 in libc-2.12.so[7f202d098000+18b000]
Jun  6 14:37:43 amd-5200-4-2 abrtd: Directory 'ccpp-2014-06-06-14:37:42-4600' creation detected
Jun  6 14:37:43 amd-5200-4-2 abrt[4602]: Saved core dump of pid 4600 (/usr/bin/libvirtMib_subagent) to /var/spool/abrt/ccpp-2014-06-06-14:37:42-4600 (2179072 bytes)

Expected results:
The libvirt snmp daemon should be started successfully.

Comment 3 Jaroslav Suchanek 2015-11-26 14:28:39 UTC
Please retest it with current release and reopen this bug if the crash is still reproducible. Thanks.