Beruflich Dokumente
Kultur Dokumente
Common NFS Error Messages and Troubleshooting TipsThe Network File System (NFS),
was developed by Sun Microsystems and is the de facto standard for file sharin
g among UN*X type systems. Netapp has taken that file sharing technology and wra
pped it all up into a storage appliance. NFS is a stateless protocol meaning th
at the file server stores no per-client information, and there are no NFS connect
ions per se. As an example, NFS has no operation to open a file, since this would
require the server to store state information such as when a file is open and d
ealing with file descriptor(s) and next byte to read, etc Instead, NFS supports a
lookup procedure which converts a filename into a file handle. This file handle
is an unique identifier which is usually an inode or disk block address. Most o
perating systems provide system calls to open files, and read from them sequenti
ally. The client s operating system must maintain the required state information,
and translate system calls into stateless NFS operations. None of this under the
cover stuff is seen by the end user. Despite being a stateless protocol, NFS e
nvironments are capable of throwing some error messages. Most of them are common
enough and simple enough to deal with. Below is an excerpt of the most common o
nes, there symptoms and how to deal with them.
Problem: Stale NFS File handle NFS Error 70
A stale NFS file handle
vents:
A certain file or directory that is on the NFS server is opened by the NFS clien
t
That specific file or directory is deleted either on that server or on another s
ystem that has access to the same share
Then that file or directory is accessed on the client
A file handle usually becomes stale when a file or directory referenced by the f
ile handle on the client is removed by another host, while your client is still
holding on to an active reference to that object. A typical example is when the
current directory of a process that is running on your client is deleted on the
server by another process running on the server or on another NFS client sharing
the same share. So this can occur if the directory is modified on the NFS serve
r, but the directories modification time is not updated.
Most Unix clients have the error 70 defined in an nfs type header file. And look
s like:
#define
NFSERR_STALE 70
If the share is missing, the best and obvious solution is to remount directory f
rom the NFS client. A remotely sane option is to mount the NFS directory with th
e noac option. But that s a lame workaround and not really recommended because of
performance issues. But could help in the short term, definitely not a long term
fix. Stale NFS file handles are almost always a NFS client application or user
problem, and not an NFS server problem.
How do I fix this problem? What to look for:
Check client vfstab or fstab or automounter maps for correctness
check connectivity to the NFS server(s)
Confirm that the correct mountpoints are there
Confirm valid share permissions and access rights with showmount
from client
Re-run the exportfs command from the filer
e filername
NFS server not responding is actually a great error message, meaning that the er
ror message isn t totally ambiguous Basically the NFS client can no longer commun
icate with the NFS server. Either via IP as in the NFS server has gone down, or
the RPC services have vanished completely from the NFS server. Or even worse, th
e network cable is unplugged, missing or someone powered off a switch. Some comm
on sense tips to resolve this problem are:
How do I fix this problem? What to look for:
Ping the Netapp filer by IP and DNS name or short name.
On the Netapp filer, try to ping the NFS client(s).
Confirm IP configuration on NFS client and servers are correct
Confirm that the correct NFS version is enabled
Check that all the nfs options on the Netapp filer are correct
Check NFS license on the Netapp filer. They don t usually disappear. But ..
nfs mount: mount: /dba_scripts: Permission denied
You are trying to mount a share on /dba_scripts and you continue to get a permis
sion denied. Essentially your NFS client doesn t have access to the NFS share bein
g offered up from the Netapp filer. This can be causes by a variety reasons, but
mostly to do with either IP address and name conficts. I have seen old versions
of AIX systems that don t negotiate NFS versions very well and have to have the N
FS version hard coded on the mount option.
How do I fix this problem? What to look for:
Check showmount e filername from the NFS client
Test NFS share by trying to mount the share on a different mountpoint
Check exportfs share permissions on the Netapp filer
Confirm the IP / hostname of NFS client and that is matches the names / IP a
ddress used in the exports file on the Netapp Filer
If your NFS client is an older version of Unix like an old AIX system, somet
imes you have to hard code the NFS version as mounting it withough will generate
a permission denied message or a vmount error. The older systems don t seem to be
able to negotiate a compatible NFS protocol version.
Network Performance is Slow
You are experiencing slow or poor NFS read and/or write performance. Takes a lon
g time to read or write. NFS performance is closely related to RPC performance.
Since RPC is a request-reply protocol, it exhibits very poor performance over wi
de area networks. NFS performs best on fast LANs.
How do I fix this problem? What to look for:
As the error message clearly states, somewhere, somehow they storage has been us
ed up. In basic Unix filesystems, you can get this error message if you have run
out of inodes. On the netapp its usually more often that you have completely ex
hausted the available storage space.
How do I fix this problem?
Do a df on the filesystem on the NFS client
Do a df on the filesystem on the root node for the filer.
Is the volume full?
Is the Qtree full?
Look for possible snapshot overruns
Check to see if quota s are enabled and if there are any reports for exceeded
quotas
====================
Stale file handles occur when a file or directory was held open by an NFS client
, and then was either removed, renamed, or replaced.
For example a file gets removed and a new file is created using the same inode,
or if the file was renamed and the inode changed.
The only way to get the ESTALE to go away is to force the client process to nego
tiate new handles. Either open the files again, or restart the processes. You c
an try to umount and remount the filesystem on top of itself, or kill/restart an
y processes that have open file handles. If you prefer not to reboot the machine
, you may create a new mount point on the client for the mount point with the St
ale NFS file handle.