+++ This bug was initially created as a clone of Bug #507304 +++ Description of problem: Destroying a transient domain after libvirt restart leaves the domain defined. Version-Release number of selected component (if applicable): libvirt-0.6.4 + "Fix re-detection of transient VMs after libvirtd restart" patch. Ref: http://git.et.redhat.com/?p=libvirt.git;a=commit;h=524188b221f5e8dc66a7f203e1633dab3aa8dcf2 (I searched for other related fix which might affect my tests but I didn't find any). Steps to Reproduce: 1. Start a transient vm. 2. Restart libvirtd. 3. List all the domains (virsh list --all). Actual results: The transient vm is still defined. Expected results: The transient vm should be completely removed. Additional info: [root@node1 ~]# virsh list --all Id Name State ---------------------------------- [root@node1 ~]# virsh create test1.xml Domain test1 created from test1.xml [root@node1 ~]# virsh list --all Id Name State ---------------------------------- 1 test1 running [root@node1 ~]# service libvirtd restart Stopping libvirtd daemon: [ OK ] Starting libvirtd daemon: [ OK ] [root@node1 ~]# virsh list --all Id Name State ---------------------------------- 1 test1 running [root@node1 ~]# virsh destroy test1 Domain test1 destroyed [root@node1 ~]# virsh list --all Id Name State ---------------------------------- - test1 shut off [root@node1 ~]# service libvirtd restart Stopping libvirtd daemon: [ OK ] Starting libvirtd daemon: [ OK ] [root@node1 ~]# virsh list --all Id Name State ----------------------------------
Reminder to myself of where the problem is.... (09:52:11 AM) danpb: simon3z: i think that that is a bug in (09:52:17 AM) danpb: virDomainLoadAllConfigs (09:52:34 AM) danpb: it is always setting (09:52:35 AM) danpb: dom->persistent = 1; (09:52:46 AM) danpb: when it should be actually doing that conditionally (09:53:06 AM) danpb: if (!liveStatus) (09:53:06 AM) danpb: dom->persistent = 1;
Created attachment 349065 [details] libvirt-0.6.5-fix-destroy-after-restart.patch Proposed patch. (Thanks to Daniel P. Berrange)
That was commited upstream, so that will be in 0.6.5 next week, thanks ! Daniel