1

When setting up my system, I created a partition and mounted it as "/home", so I assumed my documents would land there, but they do not. When I open and select my user name, Levde, I get a standard user file system.

enter image description here

When I select "Documents", because I have used it, I find the directory I called "machine&software". Then I go to "home", listed as a device, and what I find there is the "lost & found" file, but not my "machine&software" directory. So I know that my effort to define this device as the location for my "/Home" directory failed. Here is an image of Gparted showing mount point information and how much space I allocated to each partition.

enter image description here

I don't know how to assign "/home" status to my "/home" partition, and at this point, how to move the standard document template from the root directory to a new mount point. As of now, the folder "Levde" is found in the root directory under "home", where it should be (root home levde). Here is an image that shows where my "/home" partition is mounted:

enter image description here

Across the top you will see Ubuntu Studio's path rendering "[root icon] media levde Home." Obviously when I set up my partitioning and instructed the installer to mount this partition as "/home", that was not sufficient for it to BE /home. I don't think I installed it as "root media levde home", but that is where it landed.

Considering these thoughts, I thought "perhaps I need to change its mount point!" I unmounted it in gparted, but gparted would not allow me to mount it again, anywhere, so that strategy didn't work, this time.

In comments I was asked to report "cat /etc/fstab". I report this as an image file:

enter image description here

  • 3
    Please add the outputs of cat /etc/fstab in your post. It is very likely just a matter of adjusting the mount point. Home directories always go to /home/$username, you cannot just mount them anywhere and expect the system to find them. – Sebastian Jun 16 at 19:21
  • Installer does not automatically use a partition, you create in advance. You have to use Something Else and either choose(change) the partition as /home or create a new partition as /home. Default install is only / (root). And an ESP if UEFI. You may want to copy any data you have saved to the internal /home and then mount separate /home as /home. Detailed procedure: To move /home uses rsync- Be sure to use parameters to preserve ownership & permissions help.ubuntu.com/community/Partitioning/Home/Moving – oldfred Jun 16 at 21:08
  • On the Ubuntu Community help wiki, I found a page called "Home/Moving". It is detailed and yet thoughtful. – Levde Jun 17 at 10:10
  • On the Ubuntu Community help wiki, I found a page called "Home/Moving". It is detailed and yet thoughtful. Oldfred - I guess this is the page you referred to. Sebastian, thank you for your input. I crashed my previous system trying to follow instructions in linked web page above when I was denied permission to alter fstab, I changed permissions, which then left my system incapable of booting. I couldn't figure out how to restore native permissions. My fault but that is where these instructions got derailed. – Levde Jun 17 at 10:18
  • Serafim - I guess "bragging" is too strong a word but having a separate partition for /home is tauted as a possible advantage. Ever since I started using Windows 35 years ago and had to reinstall my system every few days, I have preferred to have my user files on a separate partition - have seen it as good computer hygiene. – Levde Jun 17 at 10:23
2

Ok, so if I understand you problem correctly, you have a separate partition on /dev/sda4 that you want to be Home, and which is now mounted on /media instead. You will have to tell the system to mount it in the right place, but before that copy everything you have right now in your current Home directory into your new Home partition so you can switch seamlessly afterwards without losing any configurations you may have made already.

Step 1 - Copy Home directory

It seems that your new Home partition on /media/levde/Home is empty right now. Copy all files, including hidden files and subdirectories, from /home/levde to /media/levde/Home.

Step 2 - Add Home partition to fstab

Next you need to tell the system which partition to mount to /home. To do that, open /etc/fstab in an editor of your choice (gedit, nedit, kate...) as superuser, e.g. via sudo gedit /etc/fstab.

In another terminal, enter lsblk -f /dev/sda4 to get the UUID of your new Home partition.

In the fstab you're editing, add a line at the end like this:

UUID=$UUID_you_just_found_out /home/levde ext4 defaults 0 2

and replace $UUID_you_just_found_out with the UUID that lsblk gave you.

Save the file and exit the editor.

Step 3 - Reboot

Now all you need to do is reboot, and the new partition should be mounted under /home/levde. To verify, do a lsblk in a terminal and check where /dev/sda4is mounted.

Notes

Note 1: It is worth mentioning that the content in the original /home/levde directory is not gone, it is just "covered" by the mounted new partition. If the partition is unmounted again, the original home partition will reappear.

Note 2: This procedure only copies your current user's home directory to the new partition. Any additional new user would end up on your system's root partition again.

| improve this answer | |
  • 1
    perhaps you could add a command to the first step in your answer like the one given in oldfred's link sudo rsync -aXS --exclude='/*/.gvfs' /home/. /media/home/. – db429 Jun 18 at 20:16
  • You may want to make sure that the whole levde from inside /home/ is copied to the destination /media/levde/Home. So that after copying you have /media/levde/Home/levde. One way of doing it is as shown by @db429 above. – user68186 Jun 18 at 20:16
  • Since I recommend mounting it to /home/levde in the end, you don't want to have a subdirectory /levde on your partition, or you end up with /home/levde/levde. – Sebastian Jun 18 at 20:22
  • I am going to do my best to study and use these instructions. Please be patient as I am easily confused by the numerous details. At this moment my system is busy copying files. (about 20 hours so far.) I will try to sort out what it all means and comment when I have done so. I am grateful for the time you have given to give me help. – Levde Jun 19 at 20:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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