Skip to content

Backing Up a TrueNAS Virtual Machine

About 177 wordsLess than 1 minute

NASvirtual machinesbackupsTrueNAS

...

2024-08-04

TrueNAS virtual-machine backup

Exporting a virtual machine

TrueNAS SCALE virtualization stores virtual machines in ZVOLs. Their device paths are under:

/dev/zvol

Open Virtualization → Devices → Disk → Edit to view the path used by a particular virtual machine.

Example of backing up a TrueNAS virtual machine

Example of backing up a TrueNAS virtual machine

Example of backing up a TrueNAS virtual machine

Use dd to export the virtual machine as a raw .img file:

dd if=/dev/zvol/main/winserver-93x9q3 of=/mnt/main/backup/winserver.img

Here, if is the source—the ZVOL device—and of is the destination file.

Importing a virtual machine

After creating a new ZVOL, use dd to restore the image into it:

dd if=/mnt/main/backup/winserver.img of=/dev/zvol/main/winserver-93x9q3