Ubuntu – Import/Export VMs from Multipass

multipassvirtualization

I assume there's a way (but maybe not?) to import/export a vms from multipass. For the life of me I can't find documentation on this. Basically, I'm planning to do a clean install of 19.10 and I would like to backup a couple of my vms in multipass to carry them over. Any ideas?

Best Answer

We currently have no "easy" way to export and import Multipass instances. But it's just data, so it should be possible to manually do it:)

If you'd like everything back to the way it was, I would just save the whole of /var/snap/multipass/common/data/multipassd/ and after doing the clean 19.10 install and installing the Multipass snap, just copy that back to the same location and do a snap restart multipass for the daemon to pick up the changes.

If you want to pick and choose, that'll be a bit more difficult as you'd need to selectively pick the instances in /var/snap/multipass/common/data/multipassd/vault/instances and then modify both /var/snap/multipass/common/data/multipassd/vault/multipassd-instance-image-records.json and /var/snap/multipass/common/data/multipassd/multipassd-vm-instances.json accordingly.

I hope this helps and good luck!

Related Question