2017-07-26 289 views
0

我试图运行vagrant up的第一次,但我得到这个错误:Mount.nfs:连接超时... - 流浪 - 格栅

==> default: Mounting NFS shared folders...

The following SSH command responded with a non-zero exit status. Vagrant assumes that this means the command failed!

mount -o vers=3,udp xxx.xxx.xx.x:/home/erick/... (path)

Stdout from the command:

Stderr from the command:

mount.nfs: Connection timed out

我怎样才能解决这个问题?

谢谢你

回答

1

你的nfs守护进程是否正在运行?您可以使用nfsd status进行检查,这应返回nfsd service is enabled。如果它没有运行,您可以启用并启动它: sudo nfsd enable sudo nfsd start

我最近有同样的问题,并注意到启用默认macOS防火墙将阻止NFS,它只会超时没有任何错误。如果您启用了防火墙,我会先尝试禁用它并重试。如果它工作的话,你可以添加规则来允许nfs流量通过防火墙。

如果仍然不工作:

  • 确保文件/etc/exports存在
  • 检查导出文件使用nfsd checkexports
  • 检查你的系统记录的nfsd的错误

你可以找到这里的nfsd人:https://developer.apple.com/legacy/library/documentation/Darwin/Reference/ManPages/man8/nfsd.8.html