On 04/12/11 - 08:40:17AM, Eric Blake wrote: > On 04/12/2011 08:18 AM, Richard W.M. Jones wrote: > >> Is it possible to "pause" a machine with a simple command, rsync the > >> machine's HD image in other computer and then safelly resume the machine? > >> Is > >> it necessary to shut down the virtual machine, in order to make this > >> backup? > > > > You are best to install some backup software into the virtual machine. > > Treat the virtual machine like it was a physical machine and back it > > up with some software which is aware of what's going on inside. > > That is indeed the safest advice. > > But in answer to the question, yes, it is possible to pause a guest, > save the state of its memory and disks (saving just one or the other is > insufficient - you need to save both, otherwise, in-flight data in > memory that has not been flushed to disk will be corrupted). That is, > use the sequence:
Actually, this isn't right. Think about the case where you lose power to your computer; you don't get corrupted disks, you get "crash-consistent" disks (this is what journaling filesystems are for). So if you know what you are doing, it is sufficient just to pause the guest (virsh suspend <guest>), take the backup, and then resume the guest (virsh resume <guest>). True, you won't get all of the data that might have been in-flight in memory, but it should be a valid state of the disk. That all being said, installing backup software in the guest is the best course of action. -- Chris Lalancette _______________________________________________ virt-tools-list mailing list [email protected] https://www.redhat.com/mailman/listinfo/virt-tools-list
