Bug 470548 - virt-manager exits on force-poweroff with serial console open
virt-manager exits on force-poweroff with serial console open
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: virt-manager (Show other bugs)
10
All Linux
medium Severity medium
: ---
: ---
Assigned To: Daniel Berrange
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-11-07 11:41 EST by Mark McLoughlin
Modified: 2009-09-18 12:31 EDT (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-09-18 12:31:00 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Mark McLoughlin 2008-11-07 11:41:07 EST
If I:

  1) Open a guest console
  2) Click on Run and shortly after click on Pause
  3) Open the serial console with View->Serial console
  4) Click on Shutdown->force poweroff

then virt-manager exits quite reliably.

Helpfully, this *doesn't* happen if I run with --no-fork.

virt-manager.log doesn't show anything interesting; the last message is "Destroying vm 'Test2'"

If I strace it, then I see this:

stat("/etc/localtime", {st_mode=S_IFREG|0644, st_size=3533, ...}) = 0
write(3, "[Fri, 07 Nov 2008 16:35:00 virt-m"..., 88) = 88
sendto(16, "\0\0\0<"..., 4, 0, NULL, 0) = 4
sendto(16, " \0\200\206\0\0\0\1\0\0\0\f\0\0\0\0\0\0'\241\0\0\0\0\0\0\0\5Test2"..., 56, 0, NULL, 0) = 56
recvfrom(16, 0x7fffb053ce20, 4, 0, 0, 0) = ? ERESTARTSYS (To be restarted)
--- SIGHUP (Hangup) @ 0 (0) ---

and then virt-manager *doesn't* exit.

fd 16 is the libvirtd socket:

[pid  4354] socket(PF_FILE, SOCK_STREAM, 0) = 16
[pid  4354] connect(16, {sa_family=AF_FILE, path="/var/run/libvirt/libvirt-sock"...}, 110 <unfinished ...>

Are we maybe getting a SIGHUP when we have a serial console pty open and the guest exits?
Comment 1 Bug Zapper 2008-11-25 23:59:36 EST
This bug appears to have been reported against 'rawhide' during the Fedora 10 development cycle.
Changing version to '10'.

More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 2 Cole Robinson 2008-12-08 11:34:14 EST
Thanks for debugging this, Mark. I was able to reproduce this. Just blocking SIGHUP if we fork off seems to fix this, with no apparent adverse effects.

http://hg.et.redhat.com/virt/applications/virt-manager--devel?cs=fb3a203a72d7

Moving to POST.
Comment 3 Mark McLoughlin 2009-01-20 13:25:19 EST
Fixed in rawhide with:

* Tue Jan 20 2009 Mark McLoughlin <markmc@redhat.com> - 0.6.0-7
- Add patch to ignore fix crash on force-poweroff with serial console (#470548)

Leaving the bug open until it's fixed in F10.
Comment 4 Fedora Update System 2009-03-04 14:21:09 EST
virt-manager-0.6.1-1.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/virt-manager-0.6.1-1.fc10
Comment 5 Fedora Update System 2009-03-05 11:29:24 EST
virt-manager-0.6.1-1.fc10 has been pushed to the Fedora 10 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 virt-manager'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F10/FEDORA-2009-2390
Comment 6 Cole Robinson 2009-09-18 12:31:00 EDT
Fixed in virt-manager-0.6.1-3.fc10 which is in F10. Closing as CURRENTRELEASE.

Note You need to log in before you can comment on or make changes to this bug.