solus_user
Posts: 18
Joined: Sun Feb 04, 2018 1:28 pm

Mounting a second hard drive for videos, pictures, and music

Wed Jul 11, 2018 4:01 pm

I installed solus (LUKS, encrypted) on a 256 GiB SSD. I have a second hard drive that is 1 TiB that is mounted to /run/media/user/Data . However, I would like the pictures, music, and videos links in my file folder to be directed to that drive. So I created a video, pictures and music folder as subfolders of a 'home2' folder on that second drive. I managed to bind the music folders by:

Code: Select all

sudo mount --bind /run/media/user/Data/home2/Musik /home/user/Musik

Great! But now I'd like to know, how to make this permanent, so I don't have to do this after each reboot.

Any help is greatly appreciated!

Software: Solus Budgie | NVidia proprietary drivers
Hardware: Asus N552VW | intel Core i7 6700HQ | NVIDIA GM107M [GeForce GTX 960M] | Intel HD Graphics 530 | Intel Corporation Wireless 7265 | Realtek RTL8111/8168/8411 PCI-E Gigabit Ethernet

solus_user
Posts: 18
Joined: Sun Feb 04, 2018 1:28 pm

Re: Mounting a second hard drive for videos, pictures, and music

Thu Jul 12, 2018 1:11 pm

I found something here: https://serverfault.com/questions/14150 ... ver-reboot

I edited the /etc/fstab accordingly and added:

Code: Select all

/run/media/user/Data/home2/Musik	/home/user/Musik	none	bind	0	0
But sadly that didn't work. After reboot the music folder in my home directory is still empty while the music folder in home2 contains files.

Edit:
Ok, I realized I had to include the UUID at the beginning of that line, so:

Code: Select all

UUID=f4dr4487-8b23-26b1-1e89-c37672224g09	/run/media/user/Data/home2/Musik	/home/user/Musik	none	bind	0	0
System wouldn't boot after adding this. It starts in 'emergency mode'. I removed the line from /etc/fstab and it boots just fine.

I'm close... I can feel it! ;)

Software: Solus Budgie | NVidia proprietary drivers
Hardware: Asus N552VW | intel Core i7 6700HQ | NVIDIA GM107M [GeForce GTX 960M] | Intel HD Graphics 530 | Intel Corporation Wireless 7265 | Realtek RTL8111/8168/8411 PCI-E Gigabit Ethernet

solus_user
Posts: 18
Joined: Sun Feb 04, 2018 1:28 pm

Re: Mounting a second hard drive for videos, pictures, and music

Fri Jul 13, 2018 7:20 pm

Talking to myself here but nevertheless I wanted you guys to know how I solved this.

I had to mount the second drive first and then add the bindings.

So I added at the end:

Code: Select all

UUID=f4dr4487-8b23-26b1-1e89-c37672224g09	/run/media/user/Data    ext4    defaults,noatime    0   2
/run/media/user/Data/home2/Bilder    /home/user/Bilder    none    bind    0   0
/run/media/user/Data/home2/Musik    /home/user/Musik    none    bind    0   0
/run/media/user/Data/home2/Videos    /home/user/Videos    none    bind    0   0

Now it works! :D

Software: Solus Budgie | NVidia proprietary drivers
Hardware: Asus N552VW | intel Core i7 6700HQ | NVIDIA GM107M [GeForce GTX 960M] | Intel HD Graphics 530 | Intel Corporation Wireless 7265 | Realtek RTL8111/8168/8411 PCI-E Gigabit Ethernet

Return to “Other Questions”