Closed
Description
Hi there,
I'm trying to use NFS with FreeBDS yet every time I run vagrant up
it hangs at the "Mounting NFS shared folders".
Output:
==> default: Attempting graceful shutdown of VM...
==> default: Clearing any previously set forwarded ports...
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
default: Adapter 1: nat
default: Adapter 2: hostonly
==> default: Forwarding ports...
default: 22 => 2222 (adapter 1)
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
default: SSH address: 127.0.0.1:2222
default: SSH username: vagrant
default: SSH auth method: private key
default: Warning: Connection timeout. Retrying...
==> default: Machine booted and ready!
==> default: Checking for guest additions in VM...
==> default: Configuring and enabling network interfaces...
==> default: Exporting NFS shared folders...
==> default: Preparing to edit /etc/exports. Administrator privileges will be required...
Password:
==> default: Mounting NFS shared folders...
Vagrantfile:
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure(2) do |config|
config.vm.guest = :freebsd
config.vm.box = "dev-freebsd"
config.vm.box_check_update = false
config.vm.network "private_network", ip: "192.168.1.2"
config.vm.synced_folder ".", "/vagrant", create: true, :nfs => true, :mount_options => ['nolock,vers=3,tcp,noatime,clientaddr=192.168.1.2'], id: "vagrant-root"
end
/etc/exports (host):
# VAGRANT-BEGIN: 501 XXX-XXX-XXX
"/Users/mypath/myrepo" 192.168.1.2 -alldirs -mapall=501:20
# VAGRANT-END: 501 XXX-XXX-XXX
Host: OS X 10.9.5
Guest: FreeBSD 10.1-p10
Actually, the problems seems in the way vagrant runs the mount command in the guest box. While vagrant up hangs I can access the box with vagrant ssh
and check the blocking commands:
ps -afxu | grep nfs
mount -t nfs -o nfsv3 192.168.1.1:/Users/mypath/myrepo /vagrant
mount_nfs -o nfsv3 192.168.1.1:/Users/mypath/myrepo
Then if I kill them and re-execute, everything works fine:
sudo killall mount mount_nfs
sudo mount -t nfs -o nfsv3 192.168.1.1:/Users/mypath/myrepo /vagrant
I'm unable to understand why the command issued by vagrant get stuck. Could you please investigate?
Thank you for your help!
Regards,
Nicholas
Further reference: wunki/vagrant-freebsd#4
Metadata
Metadata
Assignees
Labels
No labels