You are not logged in.
Hi,
I've been trying the very basic NFS configuration, using ArchWiki.
/etc/hosts, client side:
#
# /etc/hosts: static lookup table for host names
##<ip-address> <hostname.domain.org> <hostname>
127.0.0.1 rimfirebox localhost.localdomain localhost
::1 rimfirebox localhost6.localdomain6 localhost6
192.168.1.34 rimfirebox.localdomain rimfirebox
192.168.1.33 stovepipebox.localdomain stovepipebox
# End of file
Server:
hosts.allow:
#
# /etc/hosts.allow
#
nfsd: ALL
portmap: ALL
mountd: ALL# End of file
hosts.deny:
#
# /etc/hosts.deny
#ALL: ALL
# End of file
/etc/exports:
# /etc/exports
#
# See exports(5) for a description.# use exportfs -arv to reread
#/export 192.168.1.10(rw,no_root_squash)
/home/alexey/common *(ro,sync)
The required directory is apparently exported, but "access denied":
[alexey@rimfirebox ~]$ showmount -e stovepipebox
Export list for stovepipebox:
/home/alexey/common *
[alexey@rimfirebox ~]$ sudo mount stovepipebox:/home/alexey/common /mnt/stovepipe
mount.nfs: access denied by server while mounting stovepipebox:/home/alexey/common
Where am I supposed to look?
Last edited by Llama (2011-01-17 08:03:31)
Offline
What do the logs on the server say?
Can you mount it as root?
Can you try replacing the * with the actual IP address/32?
Are you familiar with our Forum Rules, and How To Ask Questions The Smart Way?
BlueHackers // fscanary // resticctl
Offline
What do the logs on the server say?
There's something funny with my logs. I do have relatively old NFS entries in everything.log, but nothing shows as I try to make a testcase of the "access denied" error. Nothing shows in any log, if I'm to believe the time stamps...
Offline
What do the logs on the server say?
Can you mount it as root?
No, I can't.
Can you try replacing the * with the actual IP address/32?
It blandly accepts everything (I remember about exportfs -arv), but still "access denied". BTW, * stands for the server or the client IP (I tried both )?
Offline
BTW, * stands for the server or the client IP (I tried both )?
Client that want to allow access to.
Are you familiar with our Forum Rules, and How To Ask Questions The Smart Way?
BlueHackers // fscanary // resticctl
Offline
Llama wrote:BTW, * stands for the server or the client IP (I tried both )?
Client that want to allow access to.
That's what I suspected right away . I never expected the subject problem to be that difficult, though.
Offline
What about the permissions on the server-side? Did you use idmap?
This is how my /etc/exports looks like:
/srv/export 192.168.0.0/255.255.255.0(rw,sync,fsid=0,crossmnt,subtree_check)
/srv/export/homes 192.168.0.0/255.255.255.0(rw,sync,subtree_check)
/srv/export/share 192.168.0.0/255.255.255.0(rw,sync,subtree_check)
iirc you need to export the main folder in which the the actual exports are listed (in my case they are symlinks to the actual folders)
My /etc/idmapd.conf (on Debian):
[Mapping]
Nobody-User = nobody
Nobody-Group = nogroup
This works for me, both from Debian and Archlinux-clients.
Zl.
/EDIT: I almost forgot, but I also have an Archlinux-server using NFS. The /etc/exports:
# EXPORT ROOT
/export 192.168.0.0/255.255.255.0(rw,fsid=0,no_subtree_check,async,insecure,anonuid=1000,anongid=100)
# EXPORT FOLDERS
/export/media 192.168.0.0/255.255.255.0(rw,no_subtree_check,async,nohide,insecure,anonuid=1000,anongid=100)
/export/tdone 192.168.0.0/255.255.255.0(rw,no_subtree_check,async,nohide,insecure,anonuid=1000,anongid=100)
/export/twatch 192.168.0.0/255.255.255.0(rw,no_subtree_check,async,nohide,insecure,anonuid=1000,anongid=100)
Last edited by zenlord (2011-01-18 10:47:05)
Offline
Thank you, zenlord!
Unfortunately, your examples doesn't make much sense for me yet . There's still a long way to go.
Offline
My studies turned up that there's NFSv4 there .
https://wiki.archlinux.org/index.php/Nfs
https://wiki.archlinux.org/index.php/NFSv4
https://help.ubuntu.com/community/NFSv4Howto
So I've made another go:
/etc/exports:
# /etc/exports
#
# See exports(5) for a description.# use exportfs -arv to reread
#/export 192.168.1.10(rw,no_root_squash)
/export 192.168.1.34(rw,fsid=0,insecure,no_subtree_check,async)
/export/alexey 192.168.1.34(rw,nohide,insecure,no_subtree_check,async)
/etc/fstab:
/home/alexey /export/alexey none bind 0 0
/etc/idmapd.conf:
[General]
Verbosity = 0
Pipefs-Directory = /var/lib/nfs/rpc_pipefs
Domain = localdomain[Mapping]
Nobody-User = nobody
Nobody-Group = nobody[Translation]
Method = nsswitch
My first question: what my Domain actually is? Do I have to change it to something from my /etc/hosts? Do I have to mend /etc/hosts or something else?
Starting server:
[alexey@stovepipebox ~]$ sudo /etc/rc.d/rpcbind start
:: Starting rpcbind [DONE]
[alexey@stovepipebox ~]$ sudo /etc/rc.d/nfs-common start
:: Starting rpc.statd daemon [DONE]
:: Mounting pipefs filesystem [BUSY] :: Starting rpc.idmapd daemon [DONE]
[alexey@stovepipebox ~]$ sudo /etc/rc.d/nfs-server start
:: Mounting nfsd filesystem [DONE]
:: Exporting all directories [DONE]
:: Starting rpc.nfsd daemon [DONE]
:: Starting rpc.mountd daemon [DONE]
Is the [BUSY] thing OK?
Client side:
[alexey@rimfirebox ~]$ showmount -e stovepipebox
Export list for stovepipebox:
/export/alexey 192.168.1.34
/export 192.168.1.34
[alexey@rimfirebox ~]$ sudo /etc/rc.d/rpcbind start
Password:
:: Starting rpcbind [DONE]
[alexey@rimfirebox ~]$ sudo /etc/rc.d/nfs-common start
:: Starting rpc.statd daemon [DONE]
[alexey@rimfirebox ~]$ sudo mount -t nfs4 stovepipebox:/ /mnt
mount.nfs4: No such device
Here I at the very least have no clear idea what names to use. Please, help.
Last edited by Llama (2011-01-23 17:19:02)
Offline
Sorry,
[alexey@rimfirebox ~]$ sudo mount -t nfs4 stovepipebox:/ /mnt
is good enough, provided the nfs module is loaded:
$ sudo modprobe nfs
Unfortunately, owner and group of imported files are undefined, like this:
[alexey@rimfirebox alexey]$ ls -l /mnt/alexey
total 17728
-rw-r--r-- 1 4294967294 4294967294 18061424 Jan 9 01:20 Mandarin_sounds.zip
drwxr-xr-x 2 4294967294 4294967294 4096 Nov 15 14:47 Movies
drwxr-xr-x 4 4294967294 4294967294 4096 Jun 21 2010 Music
drwxr-xr-x 5 4294967294 4294967294 4096 Jan 22 20:26 Pictures
-rw-r--r-- 1 4294967294 4294967294 31 Aug 19 13:42 Requirements.txt
Moreover, I don't know what they should be for correct rw access.
Offline
Offline
Thanks!
Correcting /etc/conf.d/nfs-common.conf and remounting didn't help, tough.
I tried to restart daemons, but got this:
[alexey@rimfirebox ~]$ sudo umount /mnt/stovepipe/
[alexey@rimfirebox ~]$ sudo /etc/rc.d/rpcbind stop
:: Stopping rpcbind [DONE]
[alexey@rimfirebox ~]$ sudo /etc/rc.d/nfs-common stop
:: Stopping rpc.idmapd daemon [FAIL]
Nevertheless, it started OK:
[alexey@rimfirebox ~]$ sudo /etc/rc.d/nfs-common start
:: Starting rpcbind [DONE]
:: Mounting pipefs filesystem [BUSY]
:: Starting rpc.idmapd daemon [DONE]
[alexey@rimfirebox ~]$ sudo mount -t nfs4 stovepipebox:/ /mnt/stovepipe/
[alexey@rimfirebox ~]$
[alexey@rimfirebox alexey]$ ls -l
total 17728
-rw-r--r-- 1 alexey users 18061424 Jan 9 01:20 Mandarin_sounds.zip
drwxr-xr-x 2 alexey users 4096 Nov 15 14:47 Movies
drwxr-xr-x 4 alexey users 4096 Jun 21 2010 Music
drwxr-xr-x 5 alexey users 4096 Jan 22 20:26 Pictures
drwxr-xr-x 2 alexey users 4096 Sep 12 12:06 qBT_dir
-rw-r--r-- 1 alexey users 31 Aug 19 13:42 Requirements.txt
Last edited by Llama (2011-01-23 23:54:43)
Offline