0

Looking at this post I ran the following commands to remove a VM:

sudo rm /var/lib/libvirt/images/centos01.qcow2
sudo virsh undefine centos01 --managed-save --snapshots-metadata

But it looks like I still have some files pertaining to this image present:

find /var -name centos*
/var/log/libvirt/qemu/centos01.log
/var/lib/libvirt/qemu/centos01.monitor

Should I just delete these files? Will I run into a problem if I create a new VM with the same name?

Also, what is a .monitor file? I haven't been able to find much info about what they do.

red888
  • 4,069
  • 16
  • 58
  • 104

1 Answers1

1

These files are safe to delete as long as the corresponding VM is not running.

The log files are never deleted automatically when you undefine a VM; you can rotate or delete them yourself.

And the monitor is a socket by which you can connect to the VM's internal qemu monitor. Not somehting you need if the VM no longer exists, and you don't normally use it anyway.

Michael Hampton
  • 237,123
  • 42
  • 477
  • 940