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.
Description of problem:
There are memory leaks on libvirt client.
Version-Release number of selected component (if applicable):
# rpm -q libvirt-python python libvirt-sandbox kernel
libvirt-python-1.1.1-3.el7.x86_64
python-2.7.5-7.el7.x86_64
libvirt-sandbox-0.5.0-3.el7.x86_64
kernel-3.10.0-0.rc7.64.el7.x86_64
How reproducible:
always
Steps to Reproduce:
1. # cat test1.py
import sys
import libvirt_qemu
if __name__ == "__main__":
name = sys.argv[1]
con = libvirt_qemu.libvirt.open(None)
dom = con.lookupByName(name)
libvirt_qemu.qemuMonitorCommand(dom, 'info cpus', 1)
2. # cat test1.py
import sys
import libvirt_lxc
if __name__ == "__main__":
name = sys.argv[1]
con = libvirt_lxc.libvirt.open('lxc:///')
dom = con.lookupByName(name)
fd = libvirt_lxc.lxcOpenNamespace(dom, 0)
3. run above test cases
# valgrind -v --leak-check=full python test1.py foo
# valgrind -v --leak-check=full python test1.py bar
Notes, please change 'foo', 'bar' to your running qemu, lxc guests.
Actual results:
==20591== 59 bytes in 1 blocks are definitely lost in loss record 277 of 1,519
==20591== at 0x4A0883C: malloc (vg_replace_malloc.c:270)
==20591== by 0x3E4A886349: strdup (in /usr/lib64/libc-2.17.so)
==20591== by 0xBDF2074: virStrdup (virstring.c:554)
==20591== by 0xBEB3B9C: remoteDomainQemuMonitorCommand (remote_driver.c:5179)
==20591== by 0xBB5BD21: virDomainQemuMonitorCommand (libvirt-qemu.c:100)
==20591== by 0xB94D564: libvirt_qemu_virDomainQemuMonitorCommand (libvirt-qemu-override.c:75)
==20591== by 0x3EF4ADDCED: PyEval_EvalFrameEx (in /usr/lib64/libpython2.7.so.1.0)
==20591== by 0x3EF4ADD80B: PyEval_EvalFrameEx (in /usr/lib64/libpython2.7.so.1.0)
==20591== by 0x3EF4ADEC7C: PyEval_EvalCodeEx (in /usr/lib64/libpython2.7.so.1.0)
==20591== by 0x3EF4ADED81: PyEval_EvalCode (in /usr/lib64/libpython2.7.so.1.0)
==20591== by 0x3EF4AF78AE: ??? (in /usr/lib64/libpython2.7.so.1.0)
==20591== by 0x3EF4AF89CD: PyRun_FileExFlags (in /usr/lib64/libpython2.7.so.1.0)
==20257== 20 bytes in 1 blocks are definitely lost in loss record 70 of 2,269
==20257== at 0x4A06B2F: calloc (vg_replace_malloc.c:593)
==20257== by 0xBDB357C: virAllocN (viralloc.c:183)
==20257== by 0xBECAC74: virNetClientProgramCall (virnetclientprogram.c:357)
==20257== by 0xBEA6311: callFull.isra.2 (remote_driver.c:5708)
==20257== by 0xBEA83C5: remoteDomainLxcOpenNamespace (remote_driver.c:6035)
==20257== by 0xBB5C164: virDomainLxcOpenNamespace (libvirt-lxc.c:94)
==20257== by 0xB94D3BE: libvirt_lxc_virDomainLxcOpenNamespace (libvirt-lxc-override.c:77)
==20257== by 0x3EF4ADDCED: PyEval_EvalFrameEx (in /usr/lib64/libpython2.7.so.1.0)
==20257== by 0x3EF4ADD80B: PyEval_EvalFrameEx (in /usr/lib64/libpython2.7.so.1.0)
==20257== by 0x3EF4ADEC7C: PyEval_EvalCodeEx (in /usr/lib64/libpython2.7.so.1.0)
==20257== by 0x3EF4ADED81: PyEval_EvalCode (in /usr/lib64/libpython2.7.so.1.0)
==20257== by 0x3EF4AF78AE: ??? (in /usr/lib64/libpython2.7.so.1.0)
Expected results:
Fix memory leaks.
Additional info:
This request was resolved in Red Hat Enterprise Linux 7.0.
Contact your manager or support representative in case you have further questions about the request.
Description of problem: There are memory leaks on libvirt client. Version-Release number of selected component (if applicable): # rpm -q libvirt-python python libvirt-sandbox kernel libvirt-python-1.1.1-3.el7.x86_64 python-2.7.5-7.el7.x86_64 libvirt-sandbox-0.5.0-3.el7.x86_64 kernel-3.10.0-0.rc7.64.el7.x86_64 How reproducible: always Steps to Reproduce: 1. # cat test1.py import sys import libvirt_qemu if __name__ == "__main__": name = sys.argv[1] con = libvirt_qemu.libvirt.open(None) dom = con.lookupByName(name) libvirt_qemu.qemuMonitorCommand(dom, 'info cpus', 1) 2. # cat test1.py import sys import libvirt_lxc if __name__ == "__main__": name = sys.argv[1] con = libvirt_lxc.libvirt.open('lxc:///') dom = con.lookupByName(name) fd = libvirt_lxc.lxcOpenNamespace(dom, 0) 3. run above test cases # valgrind -v --leak-check=full python test1.py foo # valgrind -v --leak-check=full python test1.py bar Notes, please change 'foo', 'bar' to your running qemu, lxc guests. Actual results: ==20591== 59 bytes in 1 blocks are definitely lost in loss record 277 of 1,519 ==20591== at 0x4A0883C: malloc (vg_replace_malloc.c:270) ==20591== by 0x3E4A886349: strdup (in /usr/lib64/libc-2.17.so) ==20591== by 0xBDF2074: virStrdup (virstring.c:554) ==20591== by 0xBEB3B9C: remoteDomainQemuMonitorCommand (remote_driver.c:5179) ==20591== by 0xBB5BD21: virDomainQemuMonitorCommand (libvirt-qemu.c:100) ==20591== by 0xB94D564: libvirt_qemu_virDomainQemuMonitorCommand (libvirt-qemu-override.c:75) ==20591== by 0x3EF4ADDCED: PyEval_EvalFrameEx (in /usr/lib64/libpython2.7.so.1.0) ==20591== by 0x3EF4ADD80B: PyEval_EvalFrameEx (in /usr/lib64/libpython2.7.so.1.0) ==20591== by 0x3EF4ADEC7C: PyEval_EvalCodeEx (in /usr/lib64/libpython2.7.so.1.0) ==20591== by 0x3EF4ADED81: PyEval_EvalCode (in /usr/lib64/libpython2.7.so.1.0) ==20591== by 0x3EF4AF78AE: ??? (in /usr/lib64/libpython2.7.so.1.0) ==20591== by 0x3EF4AF89CD: PyRun_FileExFlags (in /usr/lib64/libpython2.7.so.1.0) ==20257== 20 bytes in 1 blocks are definitely lost in loss record 70 of 2,269 ==20257== at 0x4A06B2F: calloc (vg_replace_malloc.c:593) ==20257== by 0xBDB357C: virAllocN (viralloc.c:183) ==20257== by 0xBECAC74: virNetClientProgramCall (virnetclientprogram.c:357) ==20257== by 0xBEA6311: callFull.isra.2 (remote_driver.c:5708) ==20257== by 0xBEA83C5: remoteDomainLxcOpenNamespace (remote_driver.c:6035) ==20257== by 0xBB5C164: virDomainLxcOpenNamespace (libvirt-lxc.c:94) ==20257== by 0xB94D3BE: libvirt_lxc_virDomainLxcOpenNamespace (libvirt-lxc-override.c:77) ==20257== by 0x3EF4ADDCED: PyEval_EvalFrameEx (in /usr/lib64/libpython2.7.so.1.0) ==20257== by 0x3EF4ADD80B: PyEval_EvalFrameEx (in /usr/lib64/libpython2.7.so.1.0) ==20257== by 0x3EF4ADEC7C: PyEval_EvalCodeEx (in /usr/lib64/libpython2.7.so.1.0) ==20257== by 0x3EF4ADED81: PyEval_EvalCode (in /usr/lib64/libpython2.7.so.1.0) ==20257== by 0x3EF4AF78AE: ??? (in /usr/lib64/libpython2.7.so.1.0) Expected results: Fix memory leaks. Additional info: