UTM icon indicating copy to clipboard operation
UTM copied to clipboard

UTM VM's not backed up by Time Machine

Open romlu2024 opened this issue 1 year ago • 2 comments

Describe the issue
I rely on Apple's built-in Time Machine for my backups and recently noticed due to a VM corruption that I was not able to recover the VM from the backups. Instead of having a recent backup, I only had the backup of the initial VM setup. In fact, when running a VM in UTM and closing it, UTM does not modify the time stamp and therefore Time machine does not backup the changed VM.

This happens for VM's stored in the default location and for VM's moved in a custom location.

Configuration

  • UTM Version: 4.5.3
  • macOS Version: macOS Sonoma 14.5
  • Mac Chip (Intel, M1, ...): Apple Silicon M1

romlu2024 avatar Jul 13 '24 16:07 romlu2024

I think this is an issue with Time Machine. Did you exclude ~/Library or anything by chance?

osy avatar Jul 14 '24 10:07 osy

No, nothing is excluded.

As I mentioned in the initial post, even the VM's that are moved through the "Move" feature in UTM to a custom location are not backed up.

When I modify files and folders in the VM and then shutdown Wndows and stop UTM, the date of the VM bundle is not changed and the modification date of the qcow2 files are not changed as well.

image

romlu2024 avatar Jul 14 '24 11:07 romlu2024

I just tested this and indeed the bundle modified date did not change but the qcow2 file did change modified date. Can you post the output of https://eclecticlight.co/2018/05/31/new-version-of-the-time-machine-mechanic-t2m2/

osy avatar Aug 21 '24 22:08 osy

Hi osy, please find attached the log files.

I think I was confused about the time stamp of the bundle while creating the bug report. I now took a test VM, backup the VM with TM and restored the whole VM.

In fact, it gets restored but the time stamp of the bundle is still showing a very old date (date of creation of VM). When you browse the TM history, you always see the same date (when the VM was created). You never see an updated date and time.

Maybe this confused me.

In TM history, the date should change each time the VM gets backup'ed up when powered on previously.

TM-Logs.txt

romlu2024 avatar Aug 22 '24 07:08 romlu2024

I think the bundle timestamp doesn't change but the files inside of it does. And that does get backed up right?

osy avatar Aug 22 '24 08:08 osy

Yes, during my latest test, the modified files inside the bundle got backup'ed and I could restore the changed VM. As I mentioned in my previous post, the VM date shown in the TM history does not change and shows always the date of the VM creation. This is something that you should fix so that the bundle date is the date of the last powered on date and time (VMware Fusion does the same)

romlu2024 avatar Aug 22 '24 08:08 romlu2024