Another NFS share already exports this dataset for some network

balanga

Patron
Joined
Jul 10, 2014
Messages
271
I'm trying to setup a new NFS share and get the following error msg:-

Another NFS share already exports this dataset for some network

I already have NFS shares for

/mnt/nas/dir1
/mnt/nas/dir2
/mnt/nas/dir3
/mnt/nas/dir4

When I try to add /mnt/nas/dir5 I get this problem. Can anyone tell me why I'm getting this error and what I can do about it?
 
Joined
Jan 4, 2014
Messages
1,644
You'll get a better response from forum members if you provide a context such as the version of FreeNAS/TrueNAS you're using. Consider including your h/w specs as well. For hints, refer to Forum Rules in the header above this thread. :wink:

Can anyone tell me why I'm getting this error and what I can do about it?

There are some key points to bear in mind when creating NFS shares. The section of the FreeNAS documentation on Unix (NFS) Shares will clue you in.
 

balanga

Patron
Joined
Jul 10, 2014
Messages
271
I'm using TrueNAS-12.0-U3.1 on a Lenove ThinkCenter with a 4TB disk and 12GB ram.

I have read the docs, but don't claim to understand everything that is written....

As I said I successfully created four NFS shares but can't add a fifth. I guess it must have something to do with:-
  1. Each pool or dataset is considered to be a unique filesystem. Individual NFS shares cannot cross filesystem boundaries. Adding paths to share more directories only works if those directories are within the same filesystem.
But I can't figure it out how. Here is my export list:-

Code:
root@truenas[/mnt/nas]# showmount -e 192.168.1.3
Exports list on 192.168.1.3:
/mnt/nas/nfsroot                   Everyone
/mnt/nas/tftproot                  Everyone
/mnt/nas/iso                       Everyone
/mnt/nas/backup                    Everyone


I would like to add /mnt/nas/pkg-repo but am unable to. Also when creating a new share, can you create a new directory through the GUI, because I couldn't see such an option. I resort to running mkdir via ssh. Doesn't seem like that is the correct way to do it.
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,700
have a look at zfs list | grep nas/

See what's a dataset, then compare that to what must be a directory and see if it all makes sense in the context of the quote you showed and the fact that you can't share the same dataset (or any path within it) more than once either.
 

balanga

Patron
Joined
Jul 10, 2014
Messages
271
Thanks for the pointer. Looks like I must have made a mistake trying to create the share originally since I have a /mnt/nas/iocage/dir5 whereas I wanted a /mnt/nas/dir5. After various attempts I did manage to delete the directory under iocage but when trying create the /mnt/nas/dir5 share I continue to get the error msg in my original post.

Maybe a reboot is required...
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,700
Maybe a reboot is required...
Maybe restarting the NFS service would do something if a reboot would help.

I'm not convinced.

You are certain that nas/dir5 is a dataset that appears when you do zfs list? (and are all the other "dir"s also datasets?)

If any one of those isn't, then you've shared the parent nas/ dataset already, which would explain the message.
 

balanga

Patron
Joined
Jul 10, 2014
Messages
271
Let's say I want create a new share - nas/dir6 ...what exactly is the procedure? It looks like some problem has occurred and I can forget about nas/dir5 until I understand exactly what is going on. It doesn't show up when I run zfs list | grep nas/

Is there a way of listing pools from the command line? I'm more comfortable with the command line than the GUI
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,700
zpool list will list your pools, but I guess you really want to see datasets.

zfs list will do that.

You can use zfs create nas/dir6 to make a new dataset and then share it with NFS.
 
Top