Hi all,

I have spent quite a lot of time trying to get nfs working with Vagrant, 
without much success so far.

When trying to enable nfs-mounting, for example with this line in the 
Vagrant file:

config.vm.synced_folder "/home/chris/MyFolder", "/home/vagrant/myfolder", 
create: true, :nfs => true, :mount_options => ['nolock']



On Vagrant up, the system hangs and timeout with this error message
*mount.nfs: access denied by server while mounting 
10.11.12.1:/home/chris/MyFolder*

For info:
1. The permissions of MyFolder are:




*[chris@localhost ~]$ ls -la /home/chris/MyFolder/total 40drwxrwxr-x   2 
chris chris  4096 Feb 26 12:51 .drwx------. 72 chris chris 36864 Feb 26 
12:51 ..-rw-rw-r--   1 chris chris     0 Feb 26 12:51 myfile*

2. I disabled firewalld (internet says somewhere that fedora firewalld and 
Vagrant don't play well together):






*[root@localhost chris]# systemctl status firewalld● firewalld.service - 
firewalld - dynamic firewall daemon   Loaded: loaded 
(/usr/lib/systemd/system/firewalld.service; enabled)   Active: inactive 
(dead) since Thu 2015-02-26 12:57:21 AEDT; 3s ago  Process: 5856 
ExecStart=/usr/sbin/firewalld --nofork --nopid $FIREWALLD_ARGS 
(code=exited, status=0/SUCCESS) Main PID: 5856 (code=exited, 
status=0/SUCCESS)*

3. I created some exportfs symlink (again, the internet advised me to do so)
*ll /usr/bin/exportfs *
*lrwxrwxrwx 1 root root 18 Feb 26 10:52 /usr/bin/exportfs -> 
/usr/sbin/exportfs*

4. The content of /etc/exports is:
*[root@localhost chris]# cat /etc/exports*
*# VAGRANT-BEGIN: 1000 9e05560d-b335-4bd7-8c29-8d48f005873f*
*"/home/chris/MyFolder" 
10.11.12.13(rw,no_subtree_check,all_squash,anonuid=1000,anongid=1000,fsid=1914143178)*
*# VAGRANT-END: 1000 9e05560d-b335-4bd7-8c29-8d48f005873f*

Now, the things that drives me insane is that I can nfs-mount /home/chris:
config.vm.synced_folder "/home/chris/", "/home/vagrant/home-chris", create: 
true, :nfs => true, :mount_options => ['nolock']

I have repeated this process carrefully several times, checked 
/etc/exports, make sure firewalld was disabled, destroy the VM.


Can someone help me with this issue?

Thanks,

Christophe

-- 
You received this message because you are subscribed to the Google Groups 
"Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to