LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Solaris / OpenSolaris (https://www.linuxquestions.org/questions/solaris-opensolaris-20/)
-   -   Cannot share via NFS a ZFS filesystem (https://www.linuxquestions.org/questions/solaris-opensolaris-20/cannot-share-via-nfs-a-zfs-filesystem-601942/)

crisostomo_enrico 11-23-2007 01:26 PM

Cannot share via NFS a ZFS filesystem
 
It was difficult to title this thread...

The long story. In the global zone I once had the following file systems:
Code:

root@suncarol:~$ zfs list
NAME            USED  AVAIL  REFER  MOUNTPOINT
tank            372G  210G  30.6K  /tank
tank/backup    24.5G  210G  24.5G  /tank/backup
tank/music    61.8G  210G  61.8G  /tank/music
tank/software  28.3G  210G  28.3G  /tank/software
tank/video      258G  210G  258G  /tank/video
root@suncarol:~$ zfs get sharenfs
NAME          PROPERTY  VALUE          SOURCE
tank          sharenfs  off            default
tank/backup    sharenfs  on            local
tank/music    sharenfs  on            local
tank/software  sharenfs  on            local
tank/video    sharenfs  on            local

and I had no problem mounting them from a remote host.

I then created a zone and assigned datasets tank/music and tank/video to that zone. Even after running netservices open, I couldn't mount those shares from a host, and the error was:
Quote:

slacklap:~# mount ssh-zone:/tank/music /mnt/tank/music/
mount.nfs: ssh-zone:/tank/music failed, reason given by server: Permission denied
I decided to solve _that_ problem later, so I removed those datasets from the zone, I cleared the zoned flag and remounted them in the global zone. After doing this, I cannot mount them from the same client from which, 10 minutes earlies, I could. The error is the same:
Quote:

slacklap:~# mount suncarol:/tank/music /mnt/tank/music/
mount.nfs: suncarol:/tank/music failed, reason given by server: Permission denied
What may have passed? And why couldn't I share those datasets from the zone?

Thanks,
Enrico.

crisostomo_enrico 11-23-2007 02:55 PM

Resolved.

I thought that having sharenfs=on would be sufficient to share the file system. A
Code:

# zfs share -a
solved the issue.

An I think that this, from opensolaris.org zones community FAQ solves the other question:
Quote:

Q: Can a zone be an NFS server?
A: A global zone can be an NFS server. A non-global zone cannot be an NFS server. This issue may be addressed in the future. See RFE 5102011. [August 2005]
Bye,
Enrico.


All times are GMT -5. The time now is 09:34 PM.