You are not logged in.
I have a arch linux NFS server, and a arch linux nfs client. This setup does not work all that well:
-After a suspend resume of the client and a shutdown powerup cycle of the server, everything on the client that uses NFS hangs, until I ssh into the NFS server, and restart the nfs-server service.
-After my NFS server has been given another IP address from my router, it was nearly impossible to unmount the NFS share that disappeared, and mount the new NFS share. I ultimately had to suspend-resume the PC with the NFS client. (In dmesg I saw the NFS client crashing).
-NFS doesn't use any form of user authentication. This is a massive security risk.
Therefore I'm looking for an alternative to NFS. Any suggestions?
Last edited by cdwijs (2020-12-17 03:46:00)
Offline
I use sshfs on top of ssh
Offline
Samba/CIFS, sshfs, AFP, WebDAV, FTP, iSCSI.... Lots of options, but you've only given a list of problems you've experienced with NFS, without defining what your actual requirements are.
Are you familiar with our Forum Rules, and How To Ask Questions The Smart Way?
BlueHackers // fscanary // resticctl
Offline
Samba?
"Oh, they have the internet on computers now."
Offline
The underlying network issues may spoil CIFS just the same…
11 Fix the NFS options
https://wiki.archlinux.org/index.php/NF … /etc/fstab
2. If the server alters its IP, mount dynamically and unmount on idle
https://wiki.archlinux.org/index.php/NF … th_systemd
User authentication isn't in scope of NFS - it's a network file system, not a remote file system.
Also, I didn't really investigate, but something™ (systemd?) mounts NFS w/ proto=udp by default, which is a dumbfuck idea, so you want to check the output of "mount" and ensure it says "proto=tcp"
In tend to run NFS w/ these options:
users,noauto,x-systemd.automount,x-systemd.device-timeout=10,timeo=14,actimeo=3,noatime,soft,bg,proto=tcp,mountproto=tcp
You may want to also use "nolock" if this is a single server / single client situation.
Offline
-After my NFS server has been given another IP address from my router, it was nearly impossible to unmount the NFS share that disappeared, and mount the new NFS share. I ultimately had to suspend-resume the PC with the NFS client. (In dmesg I saw the NFS client crashing).
I suggest you try to configure your server with a fixed IPv4. Use a DHCP INFORM request to tell your router about it instead of requesting an IP. Most routers have a range of IPs that is reserved for that and isn't part of the DHCP pool.
With IPv6 it might be a bit more difficult, but you can configure a fixed IPv6 suffix and look at how you can set up your router to provide Unique Local Addresses in addition to the global prefix.
-NFS doesn't use any form of user authentication. This is a massive security risk.
You could set up NFSv4 with kerberos, but that is not as straight forward as samba or sshfs. You could also run it with stunnel, if all users that connect will have full access
https://www.linuxjournal.com/content/en … tunnel-tls
Last edited by progandy (2020-12-17 09:02:40)
| alias CUTF='LANG=en_XX.UTF-8@POSIX ' |
Offline
Strangely, on a few kernel updates my NFS mounts via fstab would hang at either startup, suspend, or shutdown.
Switching to systemd mount units for my NFS share fixed the issue until the bug was corrected.
I'm not saying that is your problem, but I thought it was worth mentioning (just in case).
Offline
I suggest you try to configure your server with a fixed IPv4. Use a DHCP INFORM request to tell your router about it instead of requesting an IP. Most routers have a range of IPs that is reserved for that and isn't part of the DHCP pool.
With IPv6 it might be a bit more difficult, but you can configure a fixed IPv6 suffix and look at how you can set up your router to provide Unique Local Addresses in addition to the global prefix.
IPv6 is actually easier. Even private addresses can be stable and unlike DHCP are guaranteed to your host. Only the prefix could change, but that's no different from the DHCP changing.
Offline