LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   Advanced(?) disk partitioning (https://www.linuxquestions.org/questions/linux-hardware-18/advanced-disk-partitioning-258912/)

Edaph 11-24-2004 03:06 PM

Advanced(?) disk partitioning
 
Note: The same post has been posted on Gentoo Forums few days back.

Is it possible to split one primary partition in two (or more) partitions, without destroying the data on the entire hd? What I'd like to do is split the root (/dev/hda1) partition in two and have a separate /boot partition. All the data on /home (/dev/hda3) and /stuff (/dev/hda5) should be left intact, but the contents of the root (and swap) partition are useless so destroying them won't do any harm. /home I guess should be moved on the extended partition... Can this be achieved by merely modifying the partition table, or would it require moving the data around as well?

Here's my current partitioning scheme (all filesystems are reiserfs):

Code:

Disk /dev/hda: 251.0 GB, 251000193024 bytes
255 heads, 63 sectors/track, 30515 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

  Device Boot      Start        End      Blocks  Id  System
/dev/hda1  *          1        2490    20000893+  83  Linux
/dev/hda2            2491        2552      498015  82  Linux swap
/dev/hda3            2553        5043    20008957+  83  Linux
/dev/hda4            5044      30515  204603840    5  Extended
/dev/hda5            5044      30515  204603808+  83  Linux

Mount points:
/dev/hda1    /
/dev/hda2  swap
/dev/hda3  /home
/dev/hda5  /stuff


lopette 11-29-2004 01:40 PM

not too hard :-)

run fdisk /dev/hda, and remove hda1.

then create your boot partition, as /dev/hda1, as small as you'd like it to be (25MB maybe?)

create another partition (will have to be a secondary), which will be called /dev/hda6. use it as your root partition

press "w" and [enter] to save and exit, that's it


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