GNU bug report logs - #31365
libvirt/virt-manager: Embeds full path to qemu-system in saved .xml files

Previous Next

Package: guix;

Reported by: Vagrant Cascadian <vagrant <at> debian.org>

Date: Sat, 5 May 2018 00:02:02 UTC

Severity: normal

Merged with 47570

Done: Pierre Langlois <pierre.langlois <at> gmx.com>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 31365 in the body.
You can then email your comments to 31365 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guix <at> gnu.org:
bug#31365; Package guix. (Sat, 05 May 2018 00:02:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Vagrant Cascadian <vagrant <at> debian.org>:
New bug report received and forwarded. Copy sent to bug-guix <at> gnu.org. (Sat, 05 May 2018 00:02:03 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Vagrant Cascadian <vagrant <at> debian.org>
To: bug-guix <at> gnu.org
Subject: libvirt/virt-manager: Embeds full path to qemu-system in saved .xml
 files
Date: Fri, 04 May 2018 17:01:03 -0700
[Message part 1 (text/plain, inline)]
When i create a new libvirt instance with virt-manager, it embeds the
full path to the qemu binary used at the time. For the machine named
"networkboot":

  # grep qemu-system /etc/libvirt/qemu/networkboot.xml
  <emulator>/gnu/store/0rzb7rjri2kb258j58asndw2pnp0xv9p-qemu-2.11.1/bin/qemu-system-x86_64:</emulator>

If I later run "guix gc" and it happens to remove this particular qemu
version, the system no longer runs, of course:

  # virsh start networkboot
  error: Failed to start domain networkboot
  error: Cannot check QEMU binary
      /gnu/store/0rzb7rjri2kb258j58asndw2pnp0xv9p-qemu-2.11.1/bin/qemu-system-x86_64:
      No such file or directory

It also means each virtual machine may be running on an older version of
qemu, for better or worse.

Manaully replacing the emulator entry in the .xml file with
/run/current-system/profie/bin/qemu-system-x86_64 works around the
issue, and might be the easiest fix.

It wouldn't take advantage of a qemu install done in the user's
profile. I'm not sure if libvirtd can be run as a user-installed
profile, so maybe it has to use the system path anyways. I believe
libvirtd is normally run as it's own user, with it's own PATH.

live well,
  vagrant
[signature.asc (application/pgp-signature, inline)]

Information forwarded to bug-guix <at> gnu.org:
bug#31365; Package guix. (Sat, 05 May 2018 01:26:01 GMT) Full text and rfc822 format available.

Message #8 received at 31365 <at> debbugs.gnu.org (full text, mbox):

From: Mike Gerwitz <mtg <at> gnu.org>
To: Vagrant Cascadian <vagrant <at> debian.org>
Cc: 31365 <at> debbugs.gnu.org
Subject: Re: bug#31365: libvirt/virt-manager: Embeds full path to qemu-system
 in saved .xml files
Date: Fri, 04 May 2018 21:24:59 -0400
[Message part 1 (text/plain, inline)]
On Fri, May 04, 2018 at 17:01:03 -0700, Vagrant Cascadian wrote:
> When i create a new libvirt instance with virt-manager, it embeds the
> full path to the qemu binary used at the time. For the machine named
> "networkboot":
>
>   # grep qemu-system /etc/libvirt/qemu/networkboot.xml
>   <emulator>/gnu/store/0rzb7rjri2kb258j58asndw2pnp0xv9p-qemu-2.11.1/bin/qemu-system-x86_64:</emulator>
>
> If I later run "guix gc" and it happens to remove this particular qemu
> version, the system no longer runs, of course:
>
>   # virsh start networkboot
>   error: Failed to start domain networkboot
>   error: Cannot check QEMU binary
>       /gnu/store/0rzb7rjri2kb258j58asndw2pnp0xv9p-qemu-2.11.1/bin/qemu-system-x86_64:
>       No such file or directory

Thanks for looking into this; I hit this problem last night but hadn't
had the time to research.

I encountered this issue the same way (after a `guix gc').

> It also means each virtual machine may be running on an older version of
> qemu, for better or worse.

Yes, I was concerned by that as well. :X  VMs would not benefit from
security fixes, which is to me is the more important issue here.

-- 
Mike Gerwitz
Free Software Hacker+Activist | GNU Maintainer & Volunteer
GPG: D6E9 B930 028A 6C38 F43B  2388 FEF6 3574 5E6F 6D05
https://mikegerwitz.com
[signature.asc (application/pgp-signature, inline)]

Reply sent to iyzsong <at> member.fsf.org (宋文武):
You have taken responsibility. (Wed, 11 Sep 2019 11:22:01 GMT) Full text and rfc822 format available.

Notification sent to Vagrant Cascadian <vagrant <at> debian.org>:
bug acknowledged by developer. (Wed, 11 Sep 2019 11:22:02 GMT) Full text and rfc822 format available.

Message #13 received at 31365-done <at> debbugs.gnu.org (full text, mbox):

From: iyzsong <at> member.fsf.org (宋文武)
To: Vagrant Cascadian <vagrant <at> debian.org>
Cc: 31365-done <at> debbugs.gnu.org
Subject: Re: bug#31365: libvirt/virt-manager: Embeds full path to qemu-system
 in saved .xml files
Date: Wed, 11 Sep 2019 19:21:18 +0800
Vagrant Cascadian <vagrant <at> debian.org> writes:

> When i create a new libvirt instance with virt-manager, it embeds the
> full path to the qemu binary used at the time. For the machine named
> "networkboot":
>
>   # grep qemu-system /etc/libvirt/qemu/networkboot.xml
>   <emulator>/gnu/store/0rzb7rjri2kb258j58asndw2pnp0xv9p-qemu-2.11.1/bin/qemu-system-x86_64:</emulator>
>
> If I later run "guix gc" and it happens to remove this particular qemu
> version, the system no longer runs, of course:
>
>   # virsh start networkboot
>   error: Failed to start domain networkboot
>   error: Cannot check QEMU binary
>       /gnu/store/0rzb7rjri2kb258j58asndw2pnp0xv9p-qemu-2.11.1/bin/qemu-system-x86_64:
>       No such file or directory
>
> It also means each virtual machine may be running on an older version of
> qemu, for better or worse.
>
> Manaully replacing the emulator entry in the .xml file with
> /run/current-system/profie/bin/qemu-system-x86_64 works around the
> issue, and might be the easiest fix.
>

Hello, I believe my commit 'ef640db2f509f51ebfe3a6a66ba837ef3103bbb7'
fix this, now it use '/run/current-system/profie/bin/qemu-system-x86_64'
in the xml files.  Close now..  Thank you!




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 09 Oct 2019 11:24:05 GMT) Full text and rfc822 format available.

bug unarchived. Request was from Leo Famulari <leo <at> famulari.name> to control <at> debbugs.gnu.org. (Sat, 03 Apr 2021 19:28:02 GMT) Full text and rfc822 format available.

Did not alter fixed versions and reopened. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sat, 03 Apr 2021 19:28:02 GMT) Full text and rfc822 format available.

Merged 31365 47570. Request was from Leo Famulari <leo <at> famulari.name> to control <at> debbugs.gnu.org. (Sat, 03 Apr 2021 19:28:02 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 05 May 2021 11:24:05 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 328 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.