OSMC NFS WinNFSd mounting issues

Hai Guys,

i’m using OSMC in Raspberry Pi:
here are my versions:

osmc@osmc:~$ grep Kodi .kodi/temp/kodi.log | head -3
2022-04-11 22:04:51.788 T:901      INFO <general>: Starting Kodi (19.4). Platform: Linux ARM (Thumb) 32-bit
2022-04-11 22:04:51.788 T:901      INFO <general>: Using Release Kodi x32
2022-04-11 22:04:51.788 T:901      INFO <general>: Kodi compiled 2022-03-08 by GCC 8.3.0 for Linux ARM (Thumb) 32-bit version 5.10.78 (330318)
osmc@osmc:~$ grep VERSION_ID /etc/os-release
VERSION_ID="2022.03-1"

I updated the OSMC OTA few days ago.
and my Movies collection are in windows 10 & uses WinNFSd as the NFS server for OSMC to connect.

I noticed that the updated one is using nfs4 by default, while the older one isn’t. CMIIW. since when uses the old one i didn’t have to use nfsvers=3 in fstab to mount from winnfsd to osmc.

my fstab:
192.168.2.2:/Video /home/osmc/Movies nfs ro,async,nolock,noauto,x-systemd.automount,nfsvers=3 0 0

but now when updated eventhough the connection was successful, it hangs sometimes. so i need to manually remount the nfs shares again and sometimes need to reboot the raspberry pi or the winnfsd server.

when hangs i can’t ls the mount dir but after remount i can do ls to mount dir:

osmc@osmc:~$ ls Movies
^C
osmc@osmc:~$ sudo umount Movies
osmc@osmc:~$ sudo mount -v Movies
mount.nfs: timeout set for Mon Apr 11 22:23:24 2022
mount.nfs: trying text-based options 'nolock,nfsvers=3,addr=192.168.2.2'
mount.nfs: prog 100003, trying vers=3, prot=6
mount.nfs: trying 192.168.2.2 prog 100003 vers 3 prot TCP port 2049
mount.nfs: prog 100005, trying vers=3, prot=17
mount.nfs: trying 192.168.2.2 prog 100005 vers 3 prot UDP port 1058
osmc@osmc:~$ ls Movies
'(6) Guitar Backing Track Rock Ballad - C# minor - YouTube.MP4'
 AnyDesk
'Apex.2021.HDRip.XviD.AC3-EVO[TGx]'
 CamStudio
 Captures

the mount always hangs after 1h time more or less.

any idea or anyone has the same issue as mine?

Thanks in advances

Try autonfs, I have found it’s the most reliable.

1 Like

Hai,

Thanks for the recommendation,

I noticed that autofs will unmount the mounted folders when inactive, this is like remounting the nfs shares.

I modified the mount_nfs_default_protocol = 3 in autofs.conf

and add /- /etc/auto.nfs.shares --timeout 15 browse in auto.master file

and add fstype=nfs & vers=3 in the auto.nfs.shares file.

/home/osmc/Movies -fstype=nfs,vers=3.0 192.168.2.2:/Video
/home/osmc/Music -fstype=nfs,vers=3.0 192.168.2.2:/Music

It seems working without hangs now.

Thanks @thechrisgregory.

1 Like