Thursday, October 27, 2011

Copy partitions and correct partition size and empty space

Copied partition sda 11 (30 gb) to a bigger partition sda15 (43gb), both are ext4

#dd if=/dev/sda11 of=/dev/sda15

You have to be patient because dd soesn't give feedback until finished whict took me nearly 56 minutes.

Using sdd -t if=/dev/sda11 of=/dev/sda15 will report total time and show progress.

The bigger partition sda15 is shown with the size of sda11.

Gparted shows the partition with the right total size.
But used 33.75 gb and unused 9.34 gb which is not correct.
The file managers show wrong total size (that of sda11) and the wrong free space too.

I did this:


After shrinking the partition with gparted with 1 gb and then resizing it to its original size the problem is solved and the right information is there for the filemanagers and gparted: 42.4 gb total size and 20.1 gb free.

But the better and easier solution is :

After using dd to clone smaller partition to larger partition:
Run in root term:

resize2fs /dev/sda15

Thanks Kruppt


No comments:

Blog Archive

About Me

Exclusion of liability Regarding StillStupid: The use you make of the guides, tips and downloads that you listed on this web site or on another website to which I refer is entirely at your own risk. In no way can I be held liable for damage or consequential damages of any kind, which occurs as a result of that use.