Qemu scripts are not disabled when using "script=no"

Bug #898234 reported by Christophe Besson
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
qemu-kvm (Ubuntu)
Fix Released
High
Serge Hallyn
Oneiric
Fix Released
High
Unassigned

Bug Description

==========================================================
SRU Justification:
1. Impact: default qemu-ifdown script is bad
2. Development fix: remove hardcoded bad paths in /etc/qemu-ifdown
3. Stable fix: same as development fix
4. Test case: run qemu (as root) as shown in description:
     a. qemu-img create x.img 1G
     b. kvm -vnc :1 -hda x.img -net tap,ifname=tap0,script=no
     c. kill it with ctrl-c
   At shutdown, it will fail due to a bad path in the tap down script.
5. Regression potential: if users are running kvm with a bad path they might not find the executables. However as brctl's path is bad (has been changed) it can't really regress.
==========================================================
I used kvm with args which looks like this:
kvm -hda disk.img -net nic,macaddr=0:1:2:a:a:1 -net tap,ifname=tap0,script=no

I created myself a tap0, enslaved in my own bridge br0.
After a shutdown, I got this message (which corresponds to the bug #833475):
/etc/qemu-ifdown: 8: /usr/sbin/brctl: not found

The issue in my case, is the fact I use "script=no" to avoid these scripts, in order to use my own scripts. I didn't try, but I can suppose "downscript=no" is also impacted.

Regards

ProblemType: Bug
ApportVersion: 1.23-0ubuntu4
Architecture: amd64
BootDmesg:
CurrentDmesg:
Date: Wed Nov 30 17:12:21 2011
Dependencies:
DistroRelease: Ubuntu 11.10
InstallationMedia: Ubuntu 11.10 "Oneiric Ocelot" - Release amd64 (20111012)
KvmCmdLine:
Lspci:
Lsusb:
MachineType: Dell Inc. Precision WorkStation T3400
NonfreeKernelModules: nvidia
Package: qemu-kvm 0.14.1+noroms-0ubuntu6
PackageArchitecture: amd64
ProcCpuinfo:
ProcEnviron:
ProcInterrupts:
ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.0.0-12-generic root=UUID=fa2e6fc4-5251-4da0-86cd-1e3e0559181b ro quiet splash vt.handoff=7
ProcModules:
ProcVersionSignature: Ubuntu 3.0.0-12.20-generic 3.0.4
RelatedPackageVersions:
SourcePackage: qemu-kvm
Tags: oneiric
UdevDb:
UdevLog:
Uname: Linux 3.0.0-12-generic x86_64
UpgradeStatus: No upgrade log present (probably fresh install)
dmi.bios.date: 08/14/2008
dmi.bios.vendor: Dell Inc.
dmi.bios.version: A08
dmi.board.name: 0TP412
dmi.board.vendor: Dell Inc.
dmi.chassis.asset.tag: B015127
dmi.chassis.type: 7
dmi.chassis.vendor: Dell Inc.
dmi.modalias: dmi:bvnDellInc.:bvrA08:bd08/14/2008:svnDellInc.:pnPrecisionWorkStationT3400:pvr:rvnDellInc.:rn0TP412:rvr:cvnDellInc.:ct7:cvr:
dmi.product.name: Precision WorkStation T3400
dmi.sys.vendor: Dell Inc.

Related branches

Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

Thanks for submitting this bug. I see, qemu-ifup was fixed, but the fix for qemu-ifdown isn't there.

Changed in qemu-kvm (Ubuntu):
importance: Undecided → High
status: New → Confirmed
assignee: nobody → Serge Hallyn (serge-hallyn)
Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

As we are currently in soft freeze, I will wait until monday and then upload this fix.

Thanks again for reporting this bug.

Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

(once the fix is pushed, this should be SRUd for oneiric)

Changed in qemu-kvm (Ubuntu):
status: Confirmed → Triaged
Changed in qemu-kvm (Ubuntu Oneiric):
status: New → Triaged
importance: Undecided → High
tags: added: patch
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package qemu-kvm - 0.15.0+noroms-0ubuntu7

---------------
qemu-kvm (0.15.0+noroms-0ubuntu7) precise; urgency=low

  * debian/qemu-ifdown: don't use full paths for sbin/ifconfig, especially
    as those paths are wrong. (LP: #898234)
  * debian/qemu-kvm.default and debian/qemu-kvm.upstart: optionally load
    the vhost_net module.
  * debian/patches/dont-try-to-hotplug-cpu.patch: trying to hotplug a cpu
    crashes qemu. So just don't do it! (LP: #878422)
 -- Serge Hallyn <email address hidden> Wed, 30 Nov 2011 11:37:28 -0600

Changed in qemu-kvm (Ubuntu):
status: Triaged → Fix Released
description: updated
description: updated
Revision history for this message
Martin Pitt (pitti) wrote : Please test proposed package

Hello Christophe, or anyone else affected,

Accepted qemu-kvm into oneiric-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Changed in qemu-kvm (Ubuntu Oneiric):
status: Triaged → Fix Committed
tags: added: verification-needed
Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

Verified on oneiric.

tags: added: verification-done
removed: verification-needed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package qemu-kvm - 0.14.1+noroms-0ubuntu6.1

---------------
qemu-kvm (0.14.1+noroms-0ubuntu6.1) oneiric-proposed; urgency=low

  * debian/qemu-ifdown: don't use full paths for sbin/ifconfig, especially
    as those paths are wrong. (LP: #898234)
  * debian/patches/dont-try-to-hotplug-cpu.patch: trying to hotplug a cpu
    crashes qemu. So just don't do it! (LP: #878422)
 -- Serge Hallyn <email address hidden> Tue, 06 Dec 2011 14:57:13 -0600

Changed in qemu-kvm (Ubuntu Oneiric):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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