D&C GLug - Home Page

[ Date Index ] [ Thread Index ] [ <= Previous by date / thread ] [ Next by date / thread => ]

Re: [LUG] Linux Mint 20 and autofs [trying to mount NFS shares on NAS]

 

On 15/07/2020 19:38, comrade meowski wrote:
On 15/07/2020 15:28, Julian Hall wrote:
Hi All,

The little so-n-so is not working, despite following various instructions online to the letter regarding editing auto.master and creating a second file; mine is called auto.nfsdb. Mint is Ubuntu based btw. It doesn't help that for some reason advice varies on how to set it up. That includes how to start the autofs service in the first place. To my mind there should be /one/ way to set it up not variants.

nfs-common and autofs are installed.

Host is 192.168.1.3 [or is named Zeus] and has three shares on /volume1

DEMETER, HESTIA and PERSEPHONE

Thoughts appreciated.

DEJA VU!

Indeed.. for some reason the exact same steps (and OS version) I use on my desktop to mount the NAS shares do not work on my Lenovo x201 laptop. As it wasn't working /anyway/, and the laptop is rarely used except for testing I wiped it clean and installed Mint 20. I then saw that autofs seemed to be the 'proper' way to mount the shares as desired, so I did some research on how, and did the following:

apt-get install autofs
sudo vi /etc/auto.master

From here on the forums / websites vary, and this is where my braincell starts to itch..

One source says to add this line '/media/julian/nfs /etc/auto.nfsdb --timeout=30 --ghost' and let autofs create the mount points, but another says to put the actual mount point which in my case is /media/julian/DEMETER (etc)

At the moment my /etc/nfsdb file reads as follows:

DEMETER -fstype=nfs4,rw Zeus:/volume1/DEMETER
HESTIA -fstype=nfs4,rw Zeus:/volume1/HESTIA
PERSEPHONE -fstype=nfs4,rw Zeus:/volume1/PERSEPHONE

[I have also tried 192.168.1.3 as host, and Zeus:/DEMETER with no change in result. The Synology NAS does have v4 enabled for NFS.]

I am then supposed to restart the autofs service and it will work. So I enter 'sudo systemctl restart autofs.service'. Sure enough the mount point appears on the desktop, but on opening it - even after a reboot - it's empty. Also even with all three mount points in /etc/nfsdb only one ever appears on the desktop.

As usual I am scratching my head so thought I ought to ask the experts for advice.

Kind regards,

Julian

--
“The great tragedy of Science — the slaying of a beautiful hypothesis by an ugly 
fact.”

― Thomas Henry Huxley


--
The Mailing List for the Devon & Cornwall LUG
https://mailman.dcglug.org.uk/listinfo/list
FAQ: http://www.dcglug.org.uk/listfaq