-2

there is a 1TB disc drive and a 128GB SSD on a system I am setting up. I'd like to mount parts of it over the $home of the log in user so that the smaller SSD doesn't get used up with files.

Presently I'm stuck at an entry on /etc/fstab like:

/dev/disk/by-uuid/999blahblahblah /home/rod/Storage auto nosuid,nodev,nofail,x-gvfs-show 0 0

this puts the contents of the entire disk mounted in the directory $home/Storage (when logged in as user "rod")

However I'd like a more granular approach and have directories such as Documents, Music, Pictures and Videos on the platter drive and mount these to $home versions (which are presently empty)

Even more ideally I'd like to have this per user.

I'm keen to hear suggestions on this as I'm a little out of my area here.

Oh, the machine will only have two users.

Thanks

1 Answers1

0

However I'd like a more granular approach and have directories such as Documents, Music, Pictures and Videos on the platter drive and mount these to $home versions (which are presently empty)

This is where you can use mount --bind. This way, directories of a mounted file system can be mounted elsewhere in the file system.

However, using symbolic links instead is by far an easier solution, that does even not require you to be root. Move your "Music", "Pictures", etc anywhere on a mounted drive where you like. Then link them back into your home directory using symbolic links. For practical purposes for the regular user, such symbolic links acts and feel like a real directory.

vanadium
  • 88,010
  • thanks, I'm presently having trouble with all of the details of this as things are telling me they aren't present ... probably the nub of the problem is that the drive is mounted strangely – pellicle Dec 25 '22 at 23:02
  • If this answered your specific question, i.e., how to make subdirectories on other volumes available under home, then please consider accepting the question: click the checkmark next to the answer. – vanadium Dec 26 '22 at 09:52