Hi. I have an external drive which I want to permanently mount to my osmc. The readme in media folder is saying:
This directory is for automounted drives. Empty directories here are purged on reboot.
If you wish to configure an /etc/fstab mount for a drive that is attached permanently, you should do so in the /mnt directory
Can anyone guide me on how to do the second part in details, because I have limited knowledge of this.
The drive is normaly detected with media folder, but sometimes when we have power outage it does not mount until I restart osmc itself, so I want to make the attach permanent if possible.
Thanks a lot!
Decide on a name you want to mount the drive as (we’ll call it media
for this example), then log in over SSH or on the console and run the following with the drive attached:
sudo -s
blkid
(take a note of the UUID and “TYPE” of the drive you want to mount)
mkdir /mnt/media
nano /etc/fstab
add the following line at the end
UUID="<insert uuid here from earlier>" /mnt/data exfat defaults,relatime 0 0
(you might need to change exfat
depending on what “TYPE” blkid
showed earlier)
Ctrl+O Ctrl+X to save and exit.
reboot
Your drive will be mounted permamently at /mnt/media
1 Like
I just want to highlight that this process works very well. There is a minor error on this statement for anyone trying it .
The line
UUID="<insert uuid here from earlier>" /mnt/data exfat defaults,relatime 0 0
should say
UUID="<insert uuid here from earlier>" /mnt/media exfat defaults,relatime 0 0
Note that the right statement has /mnt/media instead of /mnt/data
Minor issue. Rest works well.
1 Like
May I suggest to also remove the filesystem option relatime
since it is the Debian default since kernel 2.6.30.