I have what appears to be a bit of a strange problem. I have recently re-organised a couple of partitions by deleting the old partitions and creating two new formatted partitions of different sizes (larger than the originals). I then used partimage on SystemRescueCD 1.1.4 to restore my openSUSE11.0 image taken from a small partition of size 4.88Gb with 3.65Gb used and 1.23Gb free into one of the new partitions that is 10.37 Gb in size. Everything appeared to be OK and 11.0 runs quite happily in the new partition. However, when I was next taking an image copy, I noticed that partimage reported that the partition was 10.37Gb as expected with 3.65Gb used, but only 1.23Gb free as on the original partition. I then looked at the partition in gparted which reported a size of 10.37Gb, but 9.14Gb used and 1.23 unused. Something doesn’t appear quite right here, as I was expecting to see 3.65Gb used and 6.72Gb, or so, free/unused (whatever the correct terminology is). What have I done wrong, and what do I need to correct it? I done many a search on the Internet and can find nothing similar to this problem (I’m probably using the wrong search criteria/terminology).
Many thanks in advance and sorry to be so long winded.
PS - partimage gives an option to write zeros to the free portion of the partition when carrying out a restore and I’ve tried answering both yes and no to this, but the same problem exists regardless.
As I do not know *partimage *this is a bit of a guess. I suppose *partimage *just copies the partition block by block, that is including all of its organisation (including its knowledge of its size). That would mean you now have the old filesystem at the beginning of the new partition. A bit like dd (or maybe it uses dd). Please try to find out by reading *partimage *documentation.
IMHO you need a copy that is based on directories/files. That will restore directories/files to the new created filesystemon the new partition. Tools like *tar *and *rsync *come to my mind.
You might want to run a file system check (fsck) on the system to clean up any missing files. To force a file system check when the machine boots next time, enter the command
touch /forcefsck
(as root) before the reboot.
The df command is another way to examine a partitions usage. Finally, the du command can be used to examine disk usage on individual files and directories. For example,
kdf can show you freespace and total size.
konqueror file browse mode also will show free space.
livecd /dvd also can show you partition sizes
cfdisk can be used to find partitions and sizes.
Henk, you are absolutely correct. I had a 4.8Gb file system on a 10.37Gb partition!
On reflection, I don’t know why I expected anything else, after all partimage is a partition <imaging> tool, absolutely excellent at doing what it was intended to do, but not perhaps not ideal when restoring into a partition of a different size. However running the GParted check option on the partition has sorted matters. It is, however, showing 3.81Gb used and 6.58Gb unused. This is slightly different to what I was expecting, but what the hell. If anyone has any suggestions as to why I went from 3.65Gb used to 3.81Gb after the check, I would appreciate knowing, but I don’t think it really matters. Could it be something like the inode table growing in size to take into account the larger partition size?
Many thanks again.
PS fsck refused to see a problem with the partition, let alone fix it (and yes, I tried -f).
fsck did not see any problems brcause it checks file systems, not partitions.
The size differences in general are due to indeed including or not of the inodes, etc. Calculating with 1000 or 1024 for k (between different tools) also sometimes spoils the insight.
And it was a quess of me that partimage does just that (I could nt find documention in a shor notice), but I am glad that it was an intellligent (ahum) guess.
Partimage is quite good, i only use this as my backup tool, the increased size hmm have You ever considered that ext3 takes up lot of free space when creating partition:)??
Partimage is different than dd as it saves only the bits that are used on the partition. Consider fsarchiver from system rescue cd. It’s a file based backup (it’s a bit slower but file based backup means you can restore to smaller partition:). I don’t know about tinkring with files in that image but i do know it checks every file with md5 so it’s fairly safe.
I’d made a note to look at fsarchiver, but hadn’t got round to it yet. Considering my paranoia about losing data, I’ll probably end up using both partimage and fsarchiver, with ad-hoc archiving in Konqueror, copying onto another PC and to DVD as well.rotfl!