私は当初、このvagrant-winnfsd
プラグインが Windows 上の NFS ストレージを処理する (つまり、haneWIN を使用する必要がない) と考えていましたが、受け取ったエラーがmount.nfs: requested NFS version or transport protocol is not supported
.
haneWIN を再度有効にすると、次のエラーが表示されますmount.nfs: mounting 172.28.128.1:/D/git-repositories/+vm failed, reason given by server: No such file or directory
。
[URL]:[mount] 形式が正しくないという印象を受けます。これは、別の VM で次のように fstab でマウントを手動で設定したためです192.168.11.2:/websites /home/vagrant/rails nfs nfsvers=3,vers=3,rsize=8192,wsize=8192,timeo=14,auto,intr,udp,nolock,exec,rw,user
。
次の構成では、 Vagrant の試みは172.28.128.1:/websites
次のように見えませんか?
ホスト OS: Windows 7 x64、LAN IP: 192.168.11.2
ゲスト OS: Ubuntu/trusty64
バーチャライザー: Virtualbox 5.0.20 r106931
関連プラグイン: vagrant-winnfsd
ホスト OS NFS サーバー: haneWIN NFS サーバー
NFS サーバーのエクスポート:
D:\git-repositories\+vm -name:websites
Vagrantfileの抜粋:
# Create a private network, which allows host-only access to the machine
# using a specific IP.
config.vm.network :private_network, type: :dhcp, auto_config: false
# Create a public network, which generally matched to bridged network.
# Bridged networks make the machine appear as another physical device on
# your network.
config.vm.network :public_network,
ip: '192.168.11.14',
bridge: 'Realtek PCIe GBE Family Controller'
# Share an additional folder to the guest VM. The first argument is
# the path on the host to the actual folder. The second argument is
# the path on the guest to mount the folder. And the optional third
# argument is a set of non-required options.
#
# Do not share root directory of vagrant
config.vm.synced_folder '.', '/vagrant', disabled: true
# Share ruby repository directories
config.vm.synced_folder 'D:/git-repositories/+vm',
'/home/vagrant/apps',
nfs: true,
mount_options: [
'nfsvers=3',
'vers=3',
'actimeo=1',
'rsize=8192',
'wsize=8192',
'timeo=14',
:nolock,
:udp,
:intr,
:user,
:auto,
:exec,
:rw
]