Skip to content

Instantly share code, notes, and snippets.

@killfill
Created August 14, 2017 00:14
Show Gist options
  • Save killfill/9c46e57d3817328239b9296d88b63923 to your computer and use it in GitHub Desktop.
Save killfill/9c46e57d3817328239b9296d88b63923 to your computer and use it in GitHub Desktop.
NFS Share auth
[root@storage1 ~]# NAME="test2"
[root@storage1 ~]# zfs create zones/$NAME
[root@storage1 ~]# zfs set quota=10G zones/$NAME
[root@storage1 ~]# zfs set sharenfs=rw,root=10.10.0.11 zones/$NAME
[root@storage1 ~]# chmod 777 /zones/$NAME
[root@blade1 ~]# ifconfig |grep 'inet 10.10'
inet 10.10.0.11 netmask ffff0000 broadcast 10.10.255.255
[root@blade1 ~]# mount -Fnfs -o rw,intr storage1:/zones/test2 nfs-mount-dir
[root@blade1 ~]# cd nfs-mount-dir; ls -la
total 4
drwxrwxrwx 3 root root 3 Aug 14 00:06 .
drwxr-xr-x 4 root root 512 Aug 13 23:56 ..
drwxr-xr-x 2 nobody nobody 2 Aug 14 00:06 a
[root@blade1 ~/nfs-mount-dir]# chown root a
chown: a: Not owner
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment