Cant mount NAS from Rasbian

I have a RasberryPi 4b running rasbian, (not my first Rpi and have had many other linux machines). My NAS is a D’Link 320L which i’ve been using for some time for plex via windows laptop but wanted to leave a raspberry pi on for streaming plex rather than needing my laptop on.

I’ve followed all instuctions i can find on this site from ChuckPa with the tips on how to mount and have tried with both CIFS & NFS as the NAS has settings for both. have tried altering fstab in as many possible ways i can think of but i either get connection refused or host is down when try to mount. I can access it through the GUI but that’s no good for plex to read it.

Anyone got any tips to get it working?

Daniel,

Show me your fstab entry and/or mount command line(s) that you’ve tried. Also include IP addresses

When you get ‘connection refused’ using CIFS it’s usually because the auth is wrong (It’s a pain and why I stay with NFS – haha)

When trying with NFS:

fstab
192.168.1.84:/mnt/HD/HD_b2/Movies /nas/Movies nfs auto,default,nofail 0 0

the address is given by my NAS when click on the nfs settings, typically accessed through the following address which i’ve also tried.
192.168.1.84:/volume_2/Movies /nas/Movies nfs auto,default,nofail 0 0

when mounting have done:
sudo sh
mount -avt nfs

On Synology, I know they require the full path for mounting the share (which is non-standard. QNAP does it correctly.

Are you required to mount /mnt/HD/HD_b2/Movies or /Movies ?

e.g. As a command line mount test: mount 192.168.1.84:/Movies /mnt

If you have an automounter which can get it mount | grep nfs will let you see the paths and options. I find that’s a quick way to get the info for preparing fstab

Don’t know how needs to be mounted, guess its why im struggling but have tried it in every possible way
the HDD in my nas is at Volume_2, Movies is a folder in it. When using the nas web GUI and click the NFS icon it sates ‘real path: /mnt/HD/HD_b2’
the folder i created on my server computer are /nas/Movies (also another folder for tvshows but trying to get one working first).

Can you get into the NAS and look at the exports file? The path names there will guide you.

I would run the tree until you get a hit.

sudo sh
mount 192.168.1.84:/mnt/HD/HD_b2/Movies
mount 192.168.1.84:/HD/HD_b2/Movies
mount 192.168.1.84:/HD_b2/Movies
mount 192.168.1.84:/Movies

Which NAS ?

cant get a hit on any of those and been through the web gui for the nas and cant find any form of exports file. It’s a D-Link 320L

http://forums.dlink.com/index.php?topic=51686.0

I think this is what you’re seeing? The “export IP” address needs setting.
I have ZERO idea why .

Look at the 323’s settings and subsequent discussion

Thank you so much for your help, i’m making lots of progress now. using the following was able to mount it and all the files are now adding into plex. I did however break the system with what i thought was correct for fstab and have to follow some guides online to get it back after a restart.

sudo mount -t nfs 192.168.1.84:/mnt/HD/HD_b2 /nas

Could you advise on the correct entry into fstab so that i don’t have to manually mount each time?

Using the above as the foundation:

192.168.1.84:/mnt/HD/HD_b2   /nas     nfs   defaults,auto,nofail,bg  0 0

These options:

defaults – Assume defaults for anything not specified
auto – automatically mount at boot
nofail – don’t fail system startup if the mount can’t complete in time (NAS offline)
bg – If the mount does fail, push to the background and let it complete there.

after making the entry, with plex not using the drive, we test it.

  1. sudo umount /nas
  2. sudo mount /nas <-- mount based on target directory name.

If no errors then you know /etc/fstab is right.

Thanks, mounting works fine but for some reason doesnt mount after reboot still. I can survive with mounting each time though as it’ll stay on most the time. Thanks

Then you’re having the same problem I do, which everyone else does now.

Ubuntu is super aggressive when mounting.
They are so aggressive that the adapter isn’t ready. ( network-online.targ is meaningless)
It’s a known problem. They don’t seen to want to / or are capable of fixing.

The work around

[chuck@lizum system.504]$ cat chuck-nfs.service 
#  Chuck's fix for broken Ubuntu NFS mounts

[Unit]
Description=Mount NFS partitions after system boot
After=network-online.target

[Install]
WantedBy=multi-user.target


[Service]

Type=oneshot
ExecStart=/bin/sh -c 'sleep 15 ; mount -a ; exit 0'
User=root
Group=root
[chuck@lizum system.505]$

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.