Network is unreachable when systemctl mounts cifs smb folder

  • Hi. I'm using Leia 18.1, on Pi 3B+, with TVHeadend. My recordings folder is mapped to a folder in my NAS.

    All is working OK when I mount the share manually, using systemctl start xx-xx.mount.

    Code
    storage-grabaciones.mount - cifs mount script
    Loaded: loaded (/storage/.config/system.d/storage-grabaciones.mount; enabled; vendor preset: disabled)
    Active: active (mounted) since Fri 2019-08-02 09:54:15 CEST; 21s ago
    Where: /storage/grabaciones
    What: //192.168.0.3/grabaciones
    CGroup: /system.slice/storage-grabaciones.mount
    
    Aug 02 09:54:15 LibreELEC systemd[1]: Mounting cifs mount script...
    Aug 02 09:54:15 LibreELEC systemd[1]: Mounted cifs mount script.

    However, when libreelec reboots, it does not automount the folder. Error message is as follows:

    I'm using samba vers=2.1,_netdev and these other settings:

    The problem is really annoying, because my SD card is only 16GB and recording will fill it soon if the NAS share does not automount.

    Can someone help me? Thanks! :)

  • After the upgrade to 9.0.2 I have the same issue with NFS.

    Most of the times after a reboot auto mount does not work but it works always after a manual restart of the systemd service.

    Code
       Loaded: loaded (/storage/.config/system.d/storage-videos.mount; enabled; vendor preset: disabled)
       Active: failed (Result: exit-code) since Thu 2019-04-11 19:28:42 EEST; 4 months 11 days ago
        Where: /storage/videos
         What: 192.168.1.10:/srv/nfs4/videos
    
    Apr 11 19:28:42 MainHTPC systemd[1]: Mounting nfs mount script for videos...
    Apr 11 19:28:42 MainHTPC mount[315]: mount: mounting 192.168.1.10:/srv/nfs4/videos on /storage/videos failed: Network is unreachable
    Apr 11 19:28:42 MainHTPC systemd[1]: storage-videos.mount: Mount process exited, code=exited, status=255/EXCEPTION
    Apr 11 19:28:42 MainHTPC systemd[1]: storage-videos.mount: Failed with result 'exit-code'.
    Apr 11 19:28:42 MainHTPC systemd[1]: Failed to mount nfs mount script for videos.
  • After the upgrade to 9.0.2 I have the same issue with NFS.

    Most of the times after a reboot auto mount does not work but it works always after a manual restart of the systemd service.

    Code
       Loaded: loaded (/storage/.config/system.d/storage-videos.mount; enabled; vendor preset: disabled)
       Active: failed (Result: exit-code) since Thu 2019-04-11 19:28:42 EEST; 4 months 11 days ago
        Where: /storage/videos
         What: 192.168.1.10:/srv/nfs4/videos
    
    Apr 11 19:28:42 MainHTPC systemd[1]: Mounting nfs mount script for videos...
    Apr 11 19:28:42 MainHTPC mount[315]: mount: mounting 192.168.1.10:/srv/nfs4/videos on /storage/videos failed: Network is unreachable
    Apr 11 19:28:42 MainHTPC systemd[1]: storage-videos.mount: Mount process exited, code=exited, status=255/EXCEPTION
    Apr 11 19:28:42 MainHTPC systemd[1]: storage-videos.mount: Failed with result 'exit-code'.
    Apr 11 19:28:42 MainHTPC systemd[1]: Failed to mount nfs mount script for videos.

    For me the issue seems to be caused by the firewall.

    Since I disabled it auto mounts works on every boot.