0

I'm trying to get autofs work with nfs shares with no luck.

I can mount them myself, but autofs do not work.

https://help.ubuntu.com/community/Autofs

Used settings from that help.

1 Answer 1

0

I have autofs mounting nfs shares using /net but not tried any other rules. So my auto.master looks like this:

# auto.master
/net    -hosts
+auto.master

I think autofs.conf and auto.net are default. Check auto.net is executable (chmod 755) as per the comment in that file. Restart the service, then

$ ls /net/<hostname>/

should list the exported areas for the host.

I'm pretty sure /net gets created when autofs starts, if not you can create it yourself with

$ sudo mkdir /net
$ sudo chmod 755  /net

and restart the service again.

4
  • Do you use NFS or NFSv4? I use NFSv4 and I don't understand why it won't work..
    – zjv
    Dec 12, 2017 at 19:40
  • Oh, I am using regular NFS defaults. Not tried v4. What do you have in your exports file on the server?
    – rdanter
    Dec 14, 2017 at 7:50
  • I use freebsd as my nfs server. % cat /etc/exports <br> V4: /shared <br> /shared
    – zjv
    Dec 14, 2017 at 12:27
  • Sorry, not sure what the answer is but if you are using the auto.nfs script then you can check if it sets the right options. I doubt it does though.
    – rdanter
    Dec 22, 2017 at 13:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.