Hide Forgot
Description of Problem: This is a regression problem since RHEL6.0. When a guest OS connected to a serial console by "virsh console" is shut down, the serial console is not disconnected automatically. After a message "Power down." appears in the serial console, it is disconnected by pressing any key (e.g. space key), but then the following error message appears there. -------------------------------- <snip> Power down. error: Failed to disconnect from the hypervisor, 1 leaked reference(s) # -------------------------------- Version-Release number of selected component: Red Hat Enterprise Linux Version Number: Red Hat Enterprise Linux 6.1 Release Number: Beta Architecture: x86_64 Kernel Version: kernel-2.6.32-122.el6.x86_64 Related Package Version: libvirt-0.8.7-11.el6.x86_64 and libvirt-client-0.8.7-11.el6.x86_64 How reproducible: always. Step to Reproduce: 1. Start a guest OS. # virsh start <domain-name> 2. Append "console=tty0 console=ttyS0,115200" into the "kernel" directive in /boot/grub/grub.conf so as to configure a serial console. # cat /boot/grub/grub.conf 3. Stop the guest OS. # virsh shutdown <domain-name> 4. Start the guest OS. # virsh start <domain-name> 5. Connect the serial console with the guest OS. # virsh connect <domain-name> 6. Login to the guest OS with the serial console. <snip> Escape character is ^] <snip> test01 login: Password: 7. Stop the guest OS with the serial console. guest # shutdown -h now 8. Confirm that a message "Power down" appears in the serial console. 9. Press any key to continue. Actual Results: The serial console is not disconnected automatically then, but is done by pressing any key. Expected Results: The serial console is disconnected automatically.
I see this behavior as well.
I'm surprised that this BZ actually says the same problem with BZ: https://bugzilla.redhat.com/show_bug.cgi?id=682741, and it's got fixed and verified.
<quote> Related Package Version: libvirt-0.8.7-11.el6.x86_64 and libvirt-client-0.8.7-11.el6.x86_64 </quote> <quote> Verified with the following builds. Move to VERIFIED, since it's already fixed. libvirt-0.8.7-12.el6.x86_64 qemu-kvm-0.12.1.2-2.150.el6.x86_64 python-virtinst-0.500.5-2.el6.noarch kernel-2.6.32-122.el6.x86_64 </quote> Note that it's verified with libvirt-0.8.7-12.el6.x86_64
tested, with the fix for 682741, there is no warning like "Failed to disconnect from the hypervisor, 1 leaked reference", but the console is not disconnected automatically indeed, so this is a valid bug.
verify this bug with #rpm -q libvirt libvirt-0.9.4-1.el6.x86_64 connect it with "virsh console" then "shutdown -h now " it ... Unmounting file systems: [ OK ] init: Re-executing /sbin/init Halting system... Power down. it can disconnect successfully
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/RHBA-2011-1513.html