0

/home is somewhat of a system directory but sub directories within it probably contain the bulk of user data. If I wish to move non system material to a recently added drive, it can be done with various cp commands and a few mv commands to perform the substitution in the end. (mv /important /oldimportant; mv /newimportant /important).

Would there be anything different when attempting to mv /home /oldhome;mv /newhome /home In order to perform such a move, you've got to be using an ID on the system. All IDs on the system have a directory within /home from which configurations unique to each ID are referenced. That material is going to be in use when the move takes place.

Zeye
  • 85

1 Answers1

1

/home is somewhat of a system directory

No, it IS,

but sub directories within it probably contain the bulk of user data.

so put those on a 2nd disk and not /home/

Benefits:

  • /home contains hidden directories that benefit from a quick boot
  • if /home is on the same disk as the system it will not break boot. In the old days a hdd with /home might not have been ready for the system to reach /etc/fstab so it could not find /home... it will the create a new one with empty settings. root on a quick sdd, and /home on a 5400rpm can be bad (maybe that was pre-systemd though :) )
  • your data on a different partition can be exFAT or NTFS so you can use it with windows.
  • you can also share this partition with other users, or segment the data for different users.

The system is already set up to be able to do this: see ./config/users-dirs.dirs.

Would there be anything different when attempting to mv /home /oldhome;mv /newhome /home In order to perform such a move

create a new partition using gparted from a live session and then shrink / to something like 40Gb (is enough for /, /home and snaps) or 20Gb-ish if no snaps used. Then make a 2nd partition with the remainder. Name it something, Could be /data if you want.

sudo chmod 775 /data 
sudo chown zeye:zeye data

and you own that partition

mv the directories in /home/zeye/ to this new partition.

Then open your filemanager, remove the dirs from /home and add the new ones on /data/

Rinzwind
  • 309,379