Red Hat Bugzilla – Bug 845893
Double close of FD when failing to connect to a remote hypervisor
Last modified: 2013-02-21 02:21:04 EST
Description of problem: When can't access to remote libvirtd which start by a non-root user Version-Release number of selected component (if applicable): How reproducible: libvirt-0.10.0-0rc0.el6.x86_64 Steps to Reproduce: 1. On one host A, stop libvirtd service and start it by a non-root user #service libvirtd stop #su tester $libvirtd -d 2. On another host B, try to connect that libvirtd #virsh -c qemu+ssh://tester@${hostA_ip}/session or #virsh -c qemu+ssh://tester@${hostA_ip}/system or #virsh -c qemu+ssh://tester@${hostA_ip}/aaaaaa Actual results: Step2: error: End of file while reading data: 2012-08-06 02:41:17.381+0000: 7888: info : libvirt version: 0.10.0, package: 0rc0.el6 (Red Hat, Inc. <http://bugzilla.redhat.com/bugzilla>, 2012-08-02-03:44:27, x86-007.build.bos.redhat.com) 2012-08-06 02:41:17.381+0000: 7888: warning : virFileClose:65 : Tried to close invalid fd 7: Input/output error error: failed to connect to the hypervisor Expected results: No such error message. Additional info: BTW, if the host B is rhel6.3(libvirt-0.9.10-21.el6_3.3.x86_64), then the errro message is: error: End of file while reading data: : Input/output error error: failed to connect to the hypervisor
Upstream patch proposed: https://www.redhat.com/archives/libvir-list/2012-August/msg01422.html
Fixed by commit 8211c677a36609c8d861f23ef21ec2c2e5645ece command: avoid double close in virExecWithHook
Verify this bug with : libvirt-0.10.0-0rc1.el6.x86_64 qemu-kvm-rhev-0.12.1.2-2.303.el6.x86_64 step as comment 0: # virsh -c qemu+ssh://whuang@10.66.82.251/session whuang@10.66.82.251's password: error: End of file while reading data: : Input/output error error: failed to connect to the hypervisor there is not message like : "warning : virFileClose:65 : Tried to close invalid fd 7: Input/output error"
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. http://rhn.redhat.com/errata/RHSA-2013-0276.html