3

In regards to: Preventing broken NFS connection from freezing the client system.

My system runs SLES 11.4 and I use NFS v3.

In my /etc/fstab file on an NFS client system I have:

mastersystem:/masterdata  /data  nfs defaults 0 0

Can someone tell me how I can find out what the defaults are? I'm looking to find where in the filesystem it says to use whatever options as default from the listing shown by doing a man nfs?

  • man nfs should give you plenty of details, or linux.die.net/man/5/nfs – Stephen Harris Sep 15 '16 at 20:51
  • 1
    both of those tell me all the options i can use, but what i am asking is when i specify defaults in my /etc/fstab file, what specific options make up the defaults list. This i cannot find. – ron Sep 15 '16 at 20:53
  • It does explain, but you have to read; eg soft / hard ... If neither option is specified (or if the hard option is specified), NFS requests are retried indefinitely. so we can tell that "hard" is the default for that one option. You need to read the whole page to see what the default values are for each option. – Stephen Harris Sep 15 '16 at 20:57
  • sorry let me rephrase, I understand what the values are as reported by doing man nfs, but i looking to find if and where those values actually reside. for instance I have /etc/sysconfig/nfs where i can specify port numbers for statd, mountd, and lockd. Wondering if there is a similar file somewhere under /etc/ where is says nfs_defaults=hard,timeout=600, and so on. – ron Sep 15 '16 at 21:03
  • No such file in /etc, no. – Stephen Harris Sep 15 '16 at 21:10
3

Taken from man fstab

Basic filesystem-independent options are:

defaults use default options: rw, suid, dev, exec, auto, nouser, and async.

This defines the settings for the defaults keyword.

NFS has its own (additional) set of defaults that are implied unless you tell it otherwise. An example of this is hard vs soft, where hard is the implied value unless you specify soft. These are not enumerated clearly anywhere that I know of, but must be gleaned (quite possibly painfully slowly) from the nfs(5) man page.

  • looking to find a file similar to /etc/sysconfig/nfs that will have something in it like nfs_defaults=hard, timeout=600, retrans=3...... and so on corresponding to all those values that are said to be default per the man page or linux.die.net. The default value of 600 for timeout, that number of 600 has to be specified somewhere in the system and i'm looking to find where and if i can edit it. – ron Sep 15 '16 at 21:10
  • 1
    so far i have only found /proc/mounts where it has mastersystem:/masterdata /data nfs rw,relatime,vers=3,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2 so even though i'm using nfs defaults in /etc/fstab my retrans is not 3. – ron Sep 15 '16 at 21:15
  • @Ron it's probably embedded in the program code – roaima Sep 15 '16 at 21:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.