title
Products            Buy            Support Forum            Professional            About            Codec Central
 

Raspian on Pi2 unable to mount drive using fstab

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • swedelong

    • Dec 2018
    • 4

    Raspian on Pi2 unable to mount drive using fstab

    Hi, I've managed to install and configure Asset UPnP on a Raspberry Pi 2.

    After following the advice on this forum for installing, creating an @reboot cron entry to start on powerup, and mounting a network share....
    I have managed to get it all working apart from the auto mounting of the network share (using the fstab file)

    My knowledge of Linux is pretty limited, but I did manage to manually mount the share to a (chmod 777) folder using the following mount command:*

    sudo mount -t cifs //192.168.0.104/Public /home/pi/nas -o username=admin2,password=password,vers=1.0

    The 'vers' bit apparently is something to do with the Nas device using an older version of the Samba protocol, it was only after adding this that I managed to manually mount the share (as I said, I'm not too familiar with Linux)

    This works, and with UPNP running, everything works just fine, however I just cannot seem to get the mount to work when updating fstab file.

    I tried the advice by Spoon here (final section):
    Asset UPnP is now available on the Raspberry pi, this cheap $25 computer is ideal to run a lightweight UPnP server that is totally silent, pair with a USB flash disk We have tested against Raspbian, on the Model B pi. Installation details Log-in to the pi (login: pi password: raspberry) Create a folder for Asset: cd


    so, I've tried things like
    //192.168.0.4/Public /home/pi/nas cifs username=admin2,password=password,_netdev,sec=ntlm ,vers=1.0 0 0


    ..and various other configurations... nothing I've tried manages to mount the share on reboot...

    Any help of converting my (working) mount command for use in th fstab file would be very appreciated... I'm so close!

    Oh yes, the NAS device is a WD MYBOOKLIVEDUO

    Thanks
  • Spoon
    Administrator
    • Apr 2002
    • 44583

    #2
    Re: Raspian on Pi2 unable to mount drive using fstab

    Add just:

    mount -t cifs //192.168.0.104/Public /home/pi/nas -o username=admin2,password=password,vers=1.0

    with sudo crontab -e
    Spoon
    www.dbpoweramp.com

    Comment

    • swedelong

      • Dec 2018
      • 4

      #3
      Re: Raspian on Pi2 unable to mount drive using fstab

      Hi Spoon.

      Thanks for the advice.

      I did actually try adding the mount command into the crontab file.

      I added the line with an @reboot sudo prefix
      I added the line just before the @reboot to launch AssetUPnP

      After rebooting, I checked the home/pi/nas folder to find it hadn't mounted.

      Should I not have put the @reboot sudo prefix on the line?

      Also, does it matter if the line comes before or after the launch of Asset in the crontab?

      Also, if I use this method to mount the NAS, I guess I don't need the entry in the fstab?

      Thanks for the help

      Comment

      • Spoon
        Administrator
        • Apr 2002
        • 44583

        #4
        Re: Raspian on Pi2 unable to mount drive using fstab

        Yes you would need @reboot
        Spoon
        www.dbpoweramp.com

        Comment

        Working...

        ]]>