When specifying an NFS mountpoint in /etc/fstab, What is the "addr" option for?

When specifying an NFS mountpoint in /etc/fstab, what's the purpose of the addr option? For example:

192.168.1.5:/home         /home                   nfs     rw,addr=192.168.1.5 0 0

It can specify the client address to use when the client has multiple subnet IPs on an interface and traversing the same routes (think aliased eth0:1, bond0:2, etc.). Typically in this situation you'd put the NFS server on another interface/subnet to avoid the whole problem but in large network installations things can get messy.


addr is not the same as clientaddr. The addr option is what the NFS server /etc/exports explicitly specifies, e.g.

 /home 192.168.1.5 (rw)

instead of simply

 /home * (rw)

If the NFS server has multiple interfaces, you can designate a specific interface for the NFS traffic. Of course if you do leave it to the server to choose an interface (i.e. specify *), the server chooses one out of the available IPs and you see it in the client side `mount' command output.

(in response to troyengel's answer) The clientaddr mount option is for the server to callback the client for certain metadata, not data. I think this includes verifying whether the client is allowed to mount, etc.

addr is a server IP. clientaddr is a client IP.