Install autofs
$ sudo apt install autofs
$ sudo systemctl enable autofs
$ sudo systemctl start autofs
Edit /etc/auto.master
$ sudo vi /etc/auto.master
/misc /etc/auto.misc <-comment in this line.
#+auto.master <-comment out this line.
Search External HDD
$ sudo blkid /dev/sda1
Copy the UUID
Edit auto.misc
$ sudo vi /etc/auto.misc
In this file,
hdd -fstype=ext4, rw :/dev/disk/by-uuid/xxx-xxx-xxxx
Enable Autofs
$ sudo systemctl enable autofs --now
Debug Configuration
$ sudo systemctl stop autofs
$ sudo automount -fv
Last Updated on July 9, 2021 by lama-admin
Leave a Reply