Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

This workstation is running Fedora 11. It has 4 HDDs raided into 4 partitions:

/ (31 gig)
/boot (134 meg)
/data (140 gig)
/FC12 (31 gig)

The previous employee that used my current workstation set it up this way. He apparently created the FC12 partition to test a Fedora 12 installation. I don't need Fedora 12 so I wiped that partition and now I'm wondering if its possible for me to combine the /FC12 partition into the / partition, so that the / partition will now be 62 gigs.

Is this possible? If so, how? Can it be done w/o reinstalling the OS?

I've toyed with Fedora's LVM admin interface but it seems very basic and there doesn't seem to be anything about combining partitions. I've also messed with other HDD utilities that are in Fedora (Palimpsest Disk Utlity) but all it seems to be able to do is mount and umount partitions.

share|improve this question
    
btw doing an fdisk -l would give us a much better picture of actual partition order. and df -h for what they are used for and how much is used. –  xenoterracide Apr 27 '10 at 19:55
1  
There are suggestions below on how to do this, but the easiest solution is just to mount the 31GB partition somewhere you need the space, perhaps as a subfolder of /data, or on /home –  Dentrasi Apr 27 '10 at 20:51
add comment

2 Answers

up vote 4 down vote accepted

You can't directly merge partitions, but what you can do is just delete the partition and resize the other partition into the new free space. This however requires that the deleted partitions comes directly after the one into which it should be merged. You can list partitions with fdisk -l and manipulate them with cfdisk, fdisk or gparted.

If LVM is used, then there is no such restriction, you can just lvremove the logical volume and the free storage will automatically returned into the pool of free space in the volume group, which can then be used to resize the existing partition (lvextend). To see if LVM is used look at the output of:

vgdisplay -C
lvdisplay -C

Once you have resized the partition you also have to grow the filesystem to fit the partition, this can be done with one of (depending on the file system you use):

resize2fs (ext2, ext3)
xfs_growfs (xfs)
resize_reiserfs (reiserfs)
share|improve this answer
1  
But he can move the other two partitions into the freespace, allowing him to merge the freespace to the first partition. –  Bobby Apr 27 '10 at 21:02
add comment

No you can't combine partitions... That said. What you can do is whip out gparted (and I hope that the fs supports this operation) delete the FC12 partition this is after data right? and then resize the data partition to use the rest of the space.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.