On Wed, Nov 07, 2018 at 15:32:27 +0000, Andy Gibbs wrote:
Hi,
I have a CentOS-7 server running KVM but also oVirt.
Recently, following updates, VMs not handled by oVirt have been deleting themselves after
they shut down. Previously to this, I have not had any problems of this nature. I cannot
say whether the problem is coming from oVirt updates or not.
I am creating a VM using "virsh define myvm.xml" on the server, starting it
through virt-manager on my local PC, performing work inside the VM and then closing down
the operating system inside the VM, and then once it has completed shutting down it shows
"Shutoff" as the status in virt-manager and then maybe 5 seconds later it
disappears from the list entirely and has been deleted. To start the VM again, requires
"virsh define myvm.xml" to be run again.
What I cannot determine is **why** the VM is deleted. I am using "virsh
define" which I understand should create a persistent VM, and I have enabled
"audit_level=2" and "audit_logging=1" in libvirtd.conf but can't
see anything helpful in the log output (although maybe I don't know what I'm
looking for).
You should enable debug logging to see which connection deletes your
vms.
Is anyone, please, able to help me work out what is deleting my VMs
once they shut down ... and, if possible, why?!
AFAIK this change comes from oVirt. They recently started to use
persistently defined VMs for their actions, but they define them before
use. And undefine them after done.
I presume that they delete all inactive persistent VMs they find as
a way to "clean up" after themselves rather than just those they've
created.
I presume their rationale is that oVirt is the only thing that should
deal with libvirt on the oVirt hypervisor node, but that sounds flawed.