LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   NFS stalls (https://www.linuxquestions.org/questions/linux-networking-3/nfs-stalls-611407/)

zkab 01-05-2008 05:22 PM

NFS stalls
 
I have Ubuntu 7.10 computers in my network and 2 computers are set up as NFS servers.
Very often when I copy (cp) large files from NFS client to NFS server the client stalls ... same thing when I from the client copy large files between NFS servers.

What should I check to solve this problem ... BTW I have a couple of Windows XP computers in the network also and Windows do not have any problem to copy much larger files to the NFS servers (they act as Samba servers also)

I had the feeling that Linux was superior to Windows but ... I mean NFS has been around for ages so it should be rock-solid ...

Brian1 01-05-2008 05:26 PM

Try using async as an option in your /etc/exports file.
If no luck post info in /etc/exports file.

Brian

zkab 01-06-2008 06:10 AM

When I read the NFS documentation I got the impression that sync was the recommended option for NFS2/3 due to the risk of possible data corruption ... it says:

'Finally, note that, for NFS version 3 protocol requests, a subsequent commit request from the NFS client at file close time, or at fsync() time, will force the server to write any previously unwritten data/metadata to the disk, and the server will not reply to the client until this has been completed, as long as sync behavior is followed. If async is used, the commit is essentially a no-op, since the server once again lies to the client, telling the client that the data has been sent to stable storage. This again exposes the client and server to data corruption, since cached data may be discarded on the client due to its belief that the server now has the data maintained in stable storage.'

My /etc/exports looks like:

/my_media_lib 192.168.1.44(rw,subtree_check,sync)

On my NFS-client (the one who dies) cat /var/log/messages | grep nfs gives:

Jan 6 04:45:09 pluto kernel: [16403.378139] nfs: server neptun not responding, still trying

And on my NFS server /var/log/messages gives:

Jan 6 06:14:03 neptun -- MARK --
Jan 6 06:34:03 neptun -- MARK --
Jan 6 06:54:03 neptun -- MARK --
Jan 6 07:14:03 neptun -- MARK --
Jan 6 07:34:03 neptun -- MARK --
Jan 6 07:36:20 neptun syslogd 1.4.1#21ubuntu3: restart.
Jan 6 07:54:03 neptun -- MARK --
Jan 6 08:14:03 neptun -- MARK --

How to interpret these messages ... why doesn't server respond ?
If you need more output please let me know.
I will test your recommendation with async and let you know how it went ...

Brian1 01-06-2008 11:55 AM

Have you tried changing sync to async and see if the issue still continues. No idea on errors posted.

Brian

zkab 01-06-2008 01:24 PM

OK - I will test it

zkab 01-08-2008 08:44 AM

It WORKS !!! Thanks for solution.
I have tested it with several large files between NFS servers and client. The CPU utilization is high but the client survives.

One question though ... since the only thing I changed is sync -> async in /etc/exports for the NFS servers it must imply that everything else is set-up OK for my NFS servers/clients. How come the default/recommended option sync doesn't work for NFSv3 ... is it a bug ?

Brian1 01-08-2008 03:44 PM

I don't really know an answer to that unless googling but have no time for that. async just pretty much starts transferring and does not really confirm it is complete like the sync option. async is much faster to transfer files than sync.

Brian

zkab 01-08-2008 03:50 PM

OK ... I will google and see what I can find


All times are GMT -5. The time now is 12:15 PM.