Re: Guest Image File Size

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Sadique Puthen wrote:


Basically it if you don't pre-allocate the entire image, virt-manager creates a sparse file to store the guest data which only occupies disk blocks while you write contents to that sparse file . When checking the size of the pre-allocated and sparse images, you should use "du", not "ls -lh".


Thank you for your insight.  You are correct.

I have a guest image stored in a file called "subversion".

"du" shows the actual size being used is smaller than what "ls" thinks.

du -a subversion
2158768 subversion

ls -ld subversion
-rwxr-xr-x 1 root root 64424509441 2007-11-27 18:16 subversion


I have a follow up question though. How do you cleanly backup and restore these files using the smaller amount of space? Any simplistic program that I try (e.g. "tar") also thinks my file is 60 Gig not 2 Gig and creates a real file that uses 60 Gig of actual disk space.

Can anyone share the simple steps with "dd" or other programs that let you cleanly store a backup of the guest image which uses the smaller amount of space and also correctly restores from that backup in a way that preserves the orginal idea of a 60 Gig max guest disk size?

I am sorry if these are just basic Xen or even just basic Unix questions that you all already know the answers to as opposed to "fedora-xen" questions but I'm sure I'm not the only one who will run into such things while trying to virtualize their existing infrastructure using Fedora and Xen. This low traffic list has been a wonderful asset in helping with my conversion to Fedora Virtualization. I appreciate all the help I have received.

--
Thanks,
Aaron



--
Fedora-xen mailing list
Fedora-xen@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/fedora-xen

[Index of Archives]     [Fedora General]     [Fedora Music]     [Linux Kernel]     [Fedora Desktop]     [Fedora Directory]     [PAM]     [Big List of Linux Books]     [Gimp]     [Yosemite News]

  Powered by Linux