12/04/2019

ZYXEL NSA 325v2 - nfs-shares

I added nfs shares via the Web-GUI and realized the nfs-shares show up but there are no folders or files at all though the free space is recognized.

so i did:
$ showmount -e 192.168.0.53 (#that's my NAS-Server IP-Adress)
/i-data/9e799388/nfs/photo  *
/i-data/9e799388/nfs/music  *
/i-data/9e799388/nfs/admin  *
/i-data/9e799388/nfs/public *
So the shared folders are in a nfs folder newly created and they are all empty. I wanted to share already existing folders.

so i did:
$ ssh admin@192.168.0.53
moved to:
$ cd /etc/idata/9e799388
There are all the folders where data is stored on the NAS and the newly created nfs-folder with my nfs-shares.
$ ls
admin        lost+found   nfs          photo        sysvol
aquota.user  music        opt          public       video
I want to share the folders admin, music, photo and pulic.
So via ssh i open:
$ export TERM=xterm
$ sudo nano /etc/exports

/i-data/9e799388/nfs/photo  *
/i-data/9e799388/nfs/music  *
/i-data/9e799388/nfs/admin  *
/i-data/9e799388/nfs/public *
 Just cut the /nfs, save the file wth strg+o and exit with strg+x.
 Then do:
$ sudo exportfs -ra
Exit the ssh-session and do again:
$ showmount -e 192.168.0.53
/i-data/9e799388/photo  *
/i-data/9e799388/music  *
/i-data/9e799388/admin  *
/i-data/9e799388/public *

After that all the stored files show up after do something like:
$ sudo mount -t nfs 192.168.0.53:/i-data/9e799388/photo /folder/where/you/want/to/mount