【发布时间】:2017-03-01 03:08:23
【问题描述】:
我在 Ubuntu Server 16.04LTS 上设置 ZFS 和 NFS,遇到了一个让我发疯的奇怪问题。我已经按照https://pthree.org/2012/12/31/zfs-administration-part-xv-iscsi-nfs-and-samba/ 中的描述使用 ZFS 共享设置了 ZFS 和 NFS。正如您在下面的日志中看到的,虽然我已将 zfs-share 设置为在引导期间运行 zfs share -a,但共享仍然没有导出。更奇怪的是,zfs share -a 在我手动运行时仍然没有。如果我重置其中一个共享的sharenfs 属性然后重新运行zfs share -a,我只能让zfs 共享工作。见下文
$ showmount -e
Export list for apu:
/mnt localhost
$ sudo zfs share -a
$ showmount -e
Export list for apu:
/mnt localhost
$ sudo zfs share pool1
cannot share 'pool1': filesystem already shared
$ sudo zfs get sharenfs pool1
NAME PROPERTY VALUE SOURCE
pool1 sharenfs on local
$ sudo zfs set sharenfs=on pool1
$ showmount -e
Export list for apu:
/s/apu/a/homes *
/s/apu/a *
/s/apu/a/sys *
/mnt localhost
$ sudo zfs share -a
$ showmount -e
Export list for apu:
/s/apu/b *
/s/apu/a/homes *
/s/apu/a *
/s/apu/a/sys *
/s/apu/b/cwc *
/mnt localhost
【问题讨论】:
标签: ubuntu ubuntu-16.04 nfs zfs