Red Hat Bugzilla – Bug 195963
Let xm save and xm restore work "anywhere" when called by the user
Last modified: 2007-11-30 17:11:35 EST
Description of problem:
xend isn't allowed to search all directories or write files anywhere, thus "xm
save X Y" can fail depending on where you are (as Y isn't accessible to xend).
Steps to Reproduce:
1. xm create foo
2. cd /home/james
3. xm save foo abcd
I've got a patch that does two things:
1. Creates any directories needed, so "xm save foo bar/baz" works if bar needs
to be created.
2. Asks xend to save/restore all files into /var/lib/xen/tmp, and then
moves/copies them to whever the user wants them (and the same for restore).
...one minor nit is that currently always copies the file on restore, which
might be slightly slower if you have a large save file. linking might be enough
Created attachment 131161 [details]
DO local file IO as the calling user for save/restore and have xen just access it's own directories
Really, it makes far more sense to send things like this upstream so that we're
not carrying local patches. Can you propose to xen-devel with the appropriate
In upstream XenD there are now two ways to do save & restore
a) Old style where user specifies a path. In this case it must be under
b) New style, user just specifies a domain name & XenD decides where best to
If you need extra disk space on /var/lib/xen then just --bind mount extra space
in there, or mount another volume. We're not intending to support saving of VMs
to arbitrary locations.