On Sun, 13 Sep 2009 11:55:32 +0200 Damjan Georgievski <gdamjan@gmail.com> wrote:
...
How do I change home partition /dev/sda2 to /dev/sda3?
That's fairly easy but dangerous. With fdisk you first print the partition table, then delete sda2 and sda3, and recreate them with exactly the same begining and end sectors as sda3 and sda4.
Be very carefull
Yes, that's a good way and it works fine, if the partitions created by good tools like fdisk itself or cfdisk. It happend to me that if a partition starts not from a cylinder boundary (I haven't research this issue though, maybe I'm wrong with the actual cause) you simply cannot recreate it at the same place, therefore you will loose your partition. The partition table is just 4 lines of data [0]. You can dd it in a file, change the order of the lines and dd it back. There are some ready-to-use tools too, like (commercial) PartitionMagic's Partition table editor. By the way, in some cases M$ Windows installer rewrites the partition table putting those 4 lines in "acceding" order. [0] http://en.wikipedia.org/wiki/Master_boot_record