This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
Home Products Support Community News


Re: [Xen-users] Backup domU

Greg Woods wrote:

So after reading this (and taking a vacation), I did some more reading
and discovered that using "xm sysrq name-of-guest s" will cause the
guest to sync, assuming that the guest has been set up to allow this
(kernel.sysrq = 16 in the sysctl.conf file). So I tried syncing the
guest this way and then immediately taking a snapshot:

xm sysrq name-of-guest s; vm snap

("vm" is a script I wrote that sets up and mounts the snapshot, among
many other possible operations). This is going to create the snapshot as
soon after the sync as is realistically possible.

The /var/log/messages file on the guest shows that the sync did occur.
But if I run 'file' on the guest image from the snapshot, it still says
that the ext3 file system "needs journal recovery". So I am concerned
that I may still be getting a semi-corrupted image. Is there a way to be
certain that the image is clean? Is there a way to force the guest to
run the journal as well as syncing?

The only way to get a truly clean filesystem would be to close all files and unmount the volume (or at least remount it read only). As long as it's mounted r/w, then it's going to be dirty as far as any image/snapshot taken of it is concerned.

And as Javier Guerra Giraldez says, you still have the issue of what any applications might not have actually written to disk - if it's still in the application cache then it's not going to be written by an OS level sync.

Simon Hobson

Visit http://www.magpiesnestpublishing.co.uk/ for books by acclaimed
author Gladys Hobson. Novels - poetry - short stories - ideal as
Christmas stocking fillers. Some available as e-books.

Xen-users mailing list

<Prev in Thread] Current Thread [Next in Thread>