5

Thanks to this thread I know now that I should've done this during the installation part. But I didn't.

So I'm left with my system partition and a old home partition that acts as an extra drive. I would like to know or it still possible to mount the old home partition back. I rather keep my data on that partition but if that is not option I still want to move my home folder. My system partition is just too small to host the home directory.

2 Answers 2

3

You can do 2 things:

  • boot live CD, find what drive is current home and your old home (you can use nautilus) then open fstab on disk (not live CD) that is on /media/<your-roots-UUID>/etc/fstab (you can find UUIDs with df -h ) and switch the mount points

  • you can copy old home to the new location and vice versa (in that case make sure you copy also the hidden files so you get configs too and encrypted folder if you have one)

good luck!

2

I cannot test this, but I think it's worth a try. Without logging into X, switch to a console CTRLALTF1. Log in, make a directory to store your current home directory, and then modify the account to move the current home directory.

sudo mkdir /mnt/tmp
sudo usermod -d /mnt/tmp/$USER -m $USER
logout

Login again without X. Define your home partition in /etc/fstab.

sudo vim /etc/fstab

It might look like this: /dev/sdb1 /home ext4 defaults 0 2. When correctly defined, mount it, make sure permissions are ok, modify the home directory again, and then move the files from the old home to the new home.

sudo mount /home
sudo chown -R $USER: /home/$USER
usermod -d /home/$USER $USER
logout

Log in again with X.

sudo mv /mnt/tmp ~
sudo chown -R $USER: /home/$USER/tmp

Does this work as intended?

OR

You can create a new directory, like /users. Mount the disk inside users. Change permissions on /users/$USER to match your username, and then change your home directory path with usermod.

You must log in to answer this question.

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