Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Partitioning woes
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
Edaph
n00b
n00b


Joined: 15 Nov 2004
Posts: 22

PostPosted: Mon Nov 22, 2004 2:51 pm    Post subject: Partitioning woes Reply with quote

Is it possible to split one primary partition in two (or more) partitions, without destroying the data on the 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. /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:

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
Back to top
View user's profile Send private message
blibbleage
Tux's lil' helper
Tux's lil' helper


Joined: 19 Aug 2004
Posts: 84
Location: Cambridge, UK

PostPosted: Mon Nov 22, 2004 3:05 pm    Post subject: Reply with quote

Disclaimer: I'm no expert. Read the relevant manpages first.

I think GNU PartEd is what you want (emerge sys-apps/parted). Assuming your /boot directory is small and you have some free space on the root partition, you can do what you want.

- rename the /boot directory to (eg.) /oldboot

- Resize the root partition to be a bit smaller (leaving, say, 32MB for the new /boot partition).

- Create the new partition, format it and mount it at /boot

- move everything over from /oldboot to /boot.
Back to top
View user's profile Send private message
Edaph
n00b
n00b


Joined: 15 Nov 2004
Posts: 22

PostPosted: Mon Nov 22, 2004 3:16 pm    Post subject: Reply with quote

Thanks for the tip!

But I think it wouldn't be that straightforward (I'm not sure as I haven't tried). You can have only 4 primary partitions, of which one has to be an extended partition if you need more than 4 partitions. I my case, I've already used my 4 partitions, so I can't just split /dev/hda1 in two. I think need to move /home on the extended partition (as /dev/hda5 and shift /stuff to /dev/hda6). The contents of root partition are completely useless, as it's being occupied by the old Linux distro, which I'm going to replace with Gentoo installed on /dev/hdd1. Destroying the contents of /dev/hda1 won't do any harm. Only partitions that need to live through the change are /home and /stuff.

Regards,
Edaph
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum