LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Need help on partclone... (https://www.linuxquestions.org/questions/linux-newbie-8/need-help-on-partclone-4175580330/)

mangya 05-21-2016 02:24 AM

Need help on partclone...
 
Hello all,

Following this guide 'Partclone', I cloned root filesystem (lvm) in regular mode and compress mode.

Code:

# partclone.xfs -c -s /dev/sda1 -o /mnt/test/root.img
# partclone.xfs -c -s /dev/sda1 | gzip -c > /mnt/test/root.img.gz

Now, to get info of cloned images, I used

Code:

# partclone.info -s /mnt/test/root.img
Partclone v0.2.88 http://partclone.org
Display image information
File system:  XFS
Device size:  40.2 GB = 9821184 Blocks
Space in use:  1.5 GB = 370117 Blocks
Free Space:    38.7 GB = 9451067 Blocks
Block size:  4096 Byte

But how do i get info like above with compressed image file 'root.img.gz'

Thanks.

pan64 05-21-2016 05:35 AM

I think first you need to unzip the compressed image, probably:
gunzip -c image.gz | partclone.info -s -

mangya 05-21-2016 05:43 AM

Quote:

Originally Posted by pan64 (Post 5548631)
I think first you need to unzip the compressed image, probably:
gunzip -c image.gz | partclone.info -s -

Worked like a charm. :)

Many thanks.


All times are GMT -5. The time now is 04:59 AM.