Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am currently using manjaro and I have the following problem.

My root partition is 7gb and my home partition is 100gb big. Now packages always get installed on the root partition.

I tried to resize the root partiton with a linux livecd and gparted but it seems that I can only shrink it.

Is there a way to tell linux that it should reallocate the space from /usr/share to the home partition?

share|improve this question
If your partitions are neighbours, you can resize them to both size. But problem may be in your filesystem: some filesystems don't allow to increase their size. But you always can mount directory from /home to /usr with -o bind. – Eddy_Em Apr 1 '13 at 5:35
I am using ext4. Both are located on the same SSD and they are also neightbors. root is sda3 and home is sda4. But for some reason gparted doesn't allow resizing on root. Could you guve me an example of using -o bind? – Maik Klein Apr 1 '13 at 5:52
You can resize ext4 to both sides. Reboot into live-flash, then shrink /home to its tail and enlarge /. Use resize2fs. Option bind of mount lets you to make something like "hardlink" to directories. In /etc/fstab just add option bind to column <options> – Eddy_Em Apr 1 '13 at 6:01
up vote 2 down vote accepted

As Eddy_Em points out in the comments, there is no reason why you should not be able to resize your partition as desired. I recommend you try as he suggested.

Now, another way would be to make your /usr/ directory point to your /home. You can do that using symlinks:

  1. Move your existing /usr directory to /home (if you don't have sudo set up on your system, switch to root using su):

    sudo mv /usr/ /home/usr
  2. Now, make a link pointing to that directory:

    sudo ln -s /home/usr /usr
  3. Reboot

Using the bind option is probably a better idea. To do that, you would move the /usr directory to /home as shown in step 1 above, then add this line to your /etc/fstab file:

/home/usr  /usr  bind  bind  0  0
share|improve this answer

Use gparted

First shrink and move the partition to the right. Then you can expand the first partition.

Normally if you shrink the partition it create freespace on the right which is not helpful. You can move and shrink in 1 step with gparted. However if you have already shrunk the larger partiton then you need to move it to the right also.

With the resize dialog inside of gparted open grab the right side and drag it left a big 10gb should enough. Then click and hold in the middle of the partition icon and drag it all the way to the left.

After clicking OK you should be able to resize the first partition.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .