Hey @GrillerMiller!
Are you looking to turn the entire drive into your home folder? If so, there is good way for doing it.
First, copy your user’s folder (from the home directory) into your 1TB SSD.
Second, create a backup of that same folder to your 4TB drive for safety reasons.
Note
If you want, you can use a backup/sync utility called FreeFileSync and select your entire home folder (your username, like /home/user). You can install it as a flatpak via the following command:
flatpak install org.freefilesync.FreeFileSync
If you go that way, make sure that you tell it to copy hidden files. If you can’t find that option, when the copy is complete, simply open up your 1TB drive with your file manager and hit CTRL+H to make sure that the hidden files were copied. If they were not, then the settings will not transfer and you’ll end up in a login loop.
No matter the path you choose for the copy, make sure that your copied home folder has the hidden files.
Once done, your 1TB drive should only have the folder with your username in it. This is extremely important!
End Note
PROCESS
Now starts the sensitive work, so make sure you double-check every step of the way.
Disconnect the 4TB drive from your system and keep your main SSD and the 1TB one.
Reboot your system and enter the GRUB menu.
Highlight the first load option and press the E key.
Go to the end of the linux line, where you can see the quiet splash options and add the number 3.
Press F10 to boot with this temporary change.
It will drop you to terminal only. Login normally and then execute:
sudo su -
Keep the hyphen in, so that it automatically pulls you out of your home folder.
The next step is to check your drives’ structure and naming by executing:
lsblk
This will display the hardware level naming of all your physical drives and their partitions.
For the sake of demonstration, I shall assume your 500GB drive is the sda (with sda1, sda2, etc.) and your 1TB drive is the sdb (if it’s single partition, it will have the sdb1).
Keep in mind that if - for example - your main drive is an NVMe, it will appear as nvme0n1p1, nvme0n1p2, etc.
To know exactly which is which - in terms of capacity, you can execute:
fdisk -l
This will tell you which drive/partition has what capacity. Jot the names of the devices down.
Now, install the script utilities that will secure the auto-mount of your 1TB drive:
apt install arch-install-scripts
Now, you will need to free the space on your 500GB drive by deleting the home folder.
First, make sure that the command will give you the correct location of your user’s home directory:
echo /home/$(ls /home)
If the path looks correct, then execute:
rm -R /home/$(ls /home)
Next step is to mount your 1TB drive where the old home folder was supposed to be.
Remember the naming convention we used above (i.e. your 1TB is the sdb1 or the name that is given to you via the lsblk and the fdisk -l).
mount /dev/sdb1 /home
Now check that the mount was correct, by executing:
ls -l /home
It should have a folder with your username in it.
The reason I placed the -l
flag on it is to check that your user is the owner of the folder. If it’s not, execute:
chown -R $(ls /home):$(ls /home) /home/$(ls /home)
What the above command does is pull the folder name from the /home directory (which is your username) and apply it automatically, without you having to type it.
If inside the /home folder is just another folder with your username and it has the correct ownership permissions, then we are on a good path.
Now, to make it permanent:
Next, we’ll need to backup the current fstab file, that secures the system mounts.
cp /etc/fstab /etc/fstab.backup
If you have a SWAP partition, i.e. in sda2, now it’s the time to activate it, so that it registers in the auto-mount
swapon /dev/sda2
Now, we’ll use a utility from the Arch scripts we installed earlier:
genfstab -U / > /etc/fstab
This will generate a new mapping for the auto-mounts, which will include the SWAP.
Now you can safely reboot your system and enjoy your expanded space - plus the extra space on your 500GB drive.