Upgraded pi to latest build and cannot connect to nfs shares using autofs

I updated the /auto.master

+auto.master
/- /etc/auto.nfs.shares --timeout 15 browse

I updated /etc/auto.nfs.shares
/mnt/my_movies 192.168.1.100:/my_movies

I restarted autofs
sudo systemctl restart autofs

I went to check to see if the files were there and get the following:

osmc@osmc:/mnt$ ls -lt
ls: cannot access ‘my_movies’: No such file or directory
total 0
d??? ? ? ? ? ? my_movies

I can ping my server at 192.168.1.00
and net share form the server shows:
C:\Users\Tony>net share

Share name Resource Remark


ADMIN$ C:\WINDOWS Remote Admin
C$ C:\ Default share
E$ E:\ Default share
F$ F:\ Default share
O$ O:\ Default share
I$ I:\ Default share
IPC$ Remote IPC
print$ C:\WINDOWS\system32\spool\drivers
Printer Drivers
I I:
my_movies I:\my_movies
The command completed successfully.

I tried the troubleshooting technique that was listed and got the following output:

osmc@osmc:/mnt$ sudo systemctl stop autofs
sudo automount -f -v -d
Starting automounter version 5.1.7, master map /etc/auto.master
using kernel protocol version 5.05
lookup_nss_read_master: reading master file /etc/auto.master
do_init: parse(sun): init gathered global options: (null)
lookup_read_master: lookup(file): read entry +dir:/etc/auto.master.d
lookup_nss_read_master: reading master dir /etc/auto.master.d
lookup_read_master: lookup(dir): scandir: /etc/auto.master.d
lookup_read_master: lookup(file): read entry +auto.master
lookup_nss_read_master: reading master files auto.master
do_init: parse(sun): init gathered global options: (null)
lookup_read_master: lookup(file): read entry /-
master_do_mount: mounting /-
automount_path_to_fifo: fifo name /var/run/autofs.fifo–
lookup_nss_read_map: reading map file /etc/auto.nfs.shares
do_init: parse(sun): init gathered global options: (null)
mounted direct on /mnt/my_movies with timeout 15, freq 4 seconds
do_mount_autofs_direct: mounted trigger /mnt/my_movies
st_ready: st_ready(): state = 0 path /-
handle_packet: type = 5
handle_packet_missing_direct: token 20, name /mnt/my_movies, request pid 982
attempting to mount entry /mnt/my_movies
lookup_mount: lookup(file): looking up /mnt/my_movies
lookup_mount: lookup(file): /mnt/my_movies → 192.168.1.100:/my_movies
parse_mount: parse(sun): expanded entry: 192.168.1.100:/my_movies
parse_mount: parse(sun): gathered options:
parse_mount: parse(sun): dequote(“192.168.1.100:/my_movies”) → 192.168.1.100:/my_movies
parse_mount: parse(sun): core of entry: options=, loc=192.168.1.100:/my_movies
sun_mount: parse(sun): mounting root /mnt/my_movies, mountpoint /mnt/my_movies, what 192.168.1.100:/my_movies, fstype nfs, options (null)
mount(nfs): root=/mnt/my_movies name=/mnt/my_movies what=192.168.1.100:/my_movies, fstype=nfs, options=(null)
get_nfs_info: called with host 192.168.1.100(192.168.1.100) proto 6 version 0x20
get_nfs_info: error 0x0 getting getting portmap client
get_nfs_info: called with host 192.168.1.100(192.168.1.100) proto 17 version 0x20
get_nfs_info: host not reachable or timed out getting service port
mount(nfs): no hosts available
dev_ioctl_send_fail: token = 20
failed to mount /mnt/my_movies

Any idea on what my issue is?

So you are trying to connect to your Windows (Samba) shares using NFS?

Are you saying that I should be using smb shares instead?

He is questioning whether your host is running a nfs server since it is running Windows.

1 Like

Ok got it. No I’m not running an NFS Server on my Windows PC. My bad.
I switched over to smb shares and all is well.
Thanks for the help

1 Like