Bug 477025 - autostart vm doesn't work
Summary: autostart vm doesn't work
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: libvirt
Version: 10
Hardware: All
OS: Linux
low
high
Target Milestone: ---
Assignee: Daniel Veillard
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-12-18 18:32 UTC by Michael J. Chudobiak
Modified: 2009-03-11 18:11 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-03-11 18:11:41 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Michael J. Chudobiak 2008-12-18 18:32:33 UTC
My libvirtd service starts fine, but my VM does not auto-start, even though the "autostart" option is enabled.

It used to work.

Starting it manually gives this:

[root@xena ~]# libvirtd /etc/libvirt/qemu/MikeWindows.xml
libvir: error : invalid connection pointer in virNetworkLookupByName
libvir: QEMU error : internal error Network 'default' not found
Failed to autostart VM 'MikeWindows': internal error Network 'default' not found

I am using the default network setup.

This was also reported to the libvirt mailing list by someone else:

http://www.mail-archive.com/libvir-list@redhat.com/msg09937.html

The VM starts up fine once libvirtd is up and you use the Virtual Machine Manager to start the VM, manually.

This is crippling for my users, since root access is required to start the VMs manually.


- Mike

Comment 1 Michael J. Chudobiak 2008-12-19 16:21:36 UTC
My workaround for now is to do this:

chkconfig --level 0123456 libvirtd off

and add this to root's crontab:

@reboot /sbin/service libvirtd start; /bin/sleep 10; /usr/bin/virsh start MikeWindows

- Mike

Comment 2 Gerd v. Egidy 2008-12-20 21:07:26 UTC
To fix this you need
- either the two patches that were posted by me in the thread mentioned above
or
- current libvirt cvs (which contains my patches with some documentation etc. added)

Comment 3 Mark McLoughlin 2009-01-21 09:39:32 UTC
Here's the fix committed to CVS:

  http://git.et.redhat.com/?p=libvirt.git;a=commitdiff;h=4e64546fa7

This was in 0.5.1, so closing the bug

Comment 4 Michael J. Chudobiak 2009-01-21 14:51:46 UTC
Re-opening bug, because it still doesn't work:

[root@xena ~]# rpm -qa | grep libvirt
libvirt-0.5.1-2.fc10.x86_64
libvirt-python-0.5.1-2.fc10.x86_64

[root@xena ~]# libvirtd /etc/libvirt/qemu/MikeWindows.xml
libvir: error : invalid connection pointer in virNetworkLookupByName
libvir: QEMU error : internal error Network 'default' not found
Failed to autostart VM 'MikeWindows': internal error Network 'default' not found

Comment 5 Cole Robinson 2009-01-23 20:49:33 UTC
I think this cset is the needed fix:

http://git.et.redhat.com/?p=libvirt.git;a=commit;h=b6e3cbc6656a0487d7662ca7cd4cbf80e5e88eaf

This landed shortly after 0.5.1, so it wouldn't be in f10 yet. It affects autostarting VMs which use virtual networking.

Comment 6 Cole Robinson 2009-02-16 14:34:11 UTC
Pretty certain this is fixed in 0.6.0, so moving to POST.

Comment 7 Daniel Berrangé 2009-03-10 12:33:02 UTC
This is available in F10 updates-testing now, 0.6.1 release

Comment 8 Fedora Update System 2009-03-11 17:59:14 UTC
libvirt-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 libvirt'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F10/FEDORA-2009-2396

Comment 9 Michael J. Chudobiak 2009-03-11 18:11:41 UTC
Confirmed OK with libvirt-0.6.1-1.fc10.x86_64.

Thanks!

Closing bug.


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