migrate exec ignores exit status

Bug #391879 reported by Nathan Baum
12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
QEMU
Fix Released
Wishlist
Unassigned
qemu-kvm (Ubuntu)
Won't Fix
Wishlist
Unassigned

Bug Description

Binary package hint: kvm

Using

  migrate "exec:cat > foo; false"

in the monitor results in the state of the VM being written to foo, as expected, and the VM then being stopped. This is surprising, as I think it stands to reason that in case of a failed migrate-exec process, which is what a non-zero exit status implies to me, the VM should continue.

== Version information

$ lsb_release -rd
Description: Ubuntu 9.04
Release: 9.04

$ apt-cache policy kvm
kvm:
  Installed: 1:84+dfsg-0ubuntu11
  Candidate: 1:84+dfsg-0ubuntu11
  Version table:
 *** 1:84+dfsg-0ubuntu11 0
        500 http://gb.archive.ubuntu.com jaunty/main Packages
        100 /var/lib/dpkg/status

Changed in kvm (Ubuntu):
importance: Undecided → Wishlist
Changed in qemu:
importance: Undecided → Wishlist
affects: kvm (Ubuntu) → qemu-kvm (Ubuntu)
Chuck Short (zulcss)
Changed in qemu-kvm (Ubuntu):
status: New → Confirmed
Revision history for this message
Dustin Kirkland  (kirkland) wrote :

Well, I have reproduced this behavior in Lucid's qemu-kvm 0.12.3, so the report is still accurate.

I don't have a strong opinion on the desired behavior, though I can certainly see the bug reporter's point.

This bug is filed against the upstream QEMU project, so we'll defer to Upstream's decision on this feature. Thanks for the report.

Revision history for this message
Dave Walker (davewalker) wrote :

This is a bug and has been reported upstream, it is unlikely to be fixed at the distribution level and therefore anyone interested in working on this bug should contribute a patch to the upstream project. This will then filter down to Ubuntu when it is merged mainline. Marking "Won't Fix" against the Ubuntu package.

Thanks for reporting this bug.

Changed in qemu-kvm (Ubuntu):
status: Confirmed → Won't Fix
Changed in qemu:
status: New → Confirmed
Revision history for this message
Anthony Liguori (anthony-codemonkey) wrote :

The attached patch works for me with the posted test case.

Changed in qemu:
status: Confirmed → In Progress
Revision history for this message
Thomas Huth (th-huth) wrote :

Patch has been included here:
http://git.qemu.org/?p=qemu.git;a=commitdiff;h=41ef56e61153d7bd27d34a63463
So I assume this should be working now.

Changed in qemu:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.