Restoring a file or directory from a Cloudmin VM backup (CentOS on LVM)

4 posts / 0 new
Last post
#1 Wed, 03/14/2012 - 17:18
chriswik

Restoring a file or directory from a Cloudmin VM backup (CentOS on LVM)

Does anyone have instructions on how to restore one or more files from a Cloudmin backup of a CentOS VM?

The backup file appears to be a compressed copy of the entire virtual disk. 'file' reports that the uncompressed file is a: x86 boot sector; partition 1: ID=0x83, active, starthead 1, startsector 63, 208782 sectors; partition 2: ID=0x8e, starthead 0, startsector 208845, 41720805 sectors, code offset 0x48

Wed, 03/14/2012 - 18:44
andreychek

Howdy,

So just to clarify -- you're looking not to restore the entire VM, but instead to restore some select files from it?

The Cloudmin backups are more designed to allow you to restore the entire VM -- and for file-based backups, you'd want tools such as Virtualmin running on the VM for generating backups.

That said, I suspect it's possible to do what you want, and I'll see if Jamie has any thoughts on how you might do that :-)

-Eric

Wed, 03/14/2012 - 20:06
andreychek

Okay, the answer depends on whether you're using Xen or KVM.

With Xen, you can mount the disk image using this:

mount -o loop /path/to/backup_file /mnt/backup

KVM is a little trickier... there's some details on that here:

https://www.virtualmin.com/node/21542

Thu, 03/15/2012 - 02:45
chriswik

We are using Citrix XenServer and it looks like we also will need guestfish, as the root filesystem is stored on an LVM on partition #2 of the disk image file, so it's not possible to simply mount this partition on the backup server. guestfish looks like it will do the job in our case, we will try it out.

Topic locked