You are not logged in.
Pages: 1
Hi,
I am using a vagrant box that mounts a share which is by default mounted via NFSv4. However, the root path of the share is in my home directory. This gives a permission denied error, and I can fix this by placing my content in /srv.
The documentation says: "NFS shares have to reside in /srv" (https://wiki.archlinux.org/index.php/NF … e_mounting) but is there no setting to change this behaviour?
This is the vagrant machine I am working with: https://github.com/Elao/symfony-standard
Last edited by Hmail (2016-01-03 20:04:58)
Offline
What have you put into your exports file?
The documentation says: "NFS shares have to reside in /srv" (https://wiki.archlinux.org/index.php/NF … e_mounting)
Well, the wiki is not the documentation.
Offline
^ this. I share directories not in /srv, and it works. Post your /etc/exports file.
The nfs wiki page says this:
NFS needs to see the list of shares (referred to as "exports" from here on out), which are defined in /etc/exports in order to serve-up the content. This can be any directory on the file system.
Offline
This is the exports line that does work:
"/srv/documents/documents" 172.28.128.5(rw,no_subtree_check,all_squash,anonuid=1000,anongid=100,fsid=1568133506)
And this is the one that gives a permission denied error:
"/home/henk/documents2" 172.28.128.6(rw,no_subtree_check,all_squash,anonuid=1000,anongid=100,fsid=755860892)
As far as I can see, nothing different except the path. The client executes this command:
mount -o 'nolock,actimeo=1,fsc' 172.28.128.3:'/home/henk/documents2' /srv/app/symfony
And when I run it in verbose mode I get this:
documents2# mount -vvvv -o 'nolock,actimeo=1,fsc' 172.28.128.3:'/home/henk/documents2' /srv/app/symfony
mount: fstab path: "/etc/fstab"
mount: mtab path: "/etc/mtab"
mount: lock path: "/etc/mtab~"
mount: temp path: "/etc/mtab.tmp"
mount: UID: 0
mount: eUID: 0
mount: no type was given - I'll assume nfs because of the colon
mount: spec: "172.28.128.3:/home/henk/documents2"
mount: node: "/srv/app/symfony"
mount: types: "nfs"
mount: opts: "nolock,actimeo=1,fsc"
mount: external mount: argv[0] = "/sbin/mount.nfs"
mount: external mount: argv[1] = "172.28.128.3:/home/henk/documents2"
mount: external mount: argv[2] = "/srv/app/symfony"
mount: external mount: argv[3] = "-v"
mount: external mount: argv[4] = "-o"
mount: external mount: argv[5] = "rw,nolock,actimeo=1,fsc"
mount.nfs: timeout set for Sun Jan 3 21:22:16 2016
mount.nfs: trying text-based options 'nolock,actimeo=1,fsc,vers=4,addr=172.28.128.3,clientaddr=172.28.128.6'
mount.nfs: mount(2): Permission denied
mount.nfs: access denied by server while mounting 172.28.128.3:/home/henk/documents2
I can mount it with:
documents2# mount -vvvv -o 'vers=3,nolock,actimeo=1,fsc' 172.28.128.3:'/home/henk/documents2' /srv/app/symfony
Or, when the nfs directory is in /srv, I can mount it without specifing version 3. I don't really care which version this is, it is a virtual box that corresponds with my machine, so as long as it works I don't care, but the commands and files are created by scripts. The Archlinux wiki ( ) is the only source I found that says that nfsv4 needs to be mounted from /srv, so that's why I came to this conclusion.
Offline
You specified userid and groupid and that would be permissions that would require matching arguments on the mount side. Otherwise, root would be able to mount it. Normally, if it doesn't have permission, it just acts normally. But when you specify it on the mount or in exports, it changes the behaviour.
I may have to CONSOLE you about your usage of ridiculously easy graphical interfaces...
Look ma, no mouse.
Offline
Pages: 1