Problems because of NFS mount options

As mentioned in post title it is not about NFS mount issues but some issues that I’ve seen on client because of options  used while mounting.

  1. Not able to execute shell script:

We have a bash shell script and getting permission denied error while running it. Execute permissions are set “755”. Checked if the bash interpretor mentioned as first line and it is present “#!/bin/bash”.

A: When we run the script with “/bin/bash” then it is executing with no problems. In the end found that the script is on a mount which is mounted with option “noexec”. While running with bash we are asking the shell to execute the script on behalf of us so it is being executed fine.

2. Files with nobody:nobody permissions:

Files in mounted folder owned by nobody:nobody – I’ve tried to change using chown with the existing username and group which also present on the NFS server but still nobody:nobody.

A: Problem is with NFSv4. It expects the server and client to be present in the same domain but our client system in different domain compared to the nfs server.

Check in /etc/idmapd.conf for domain configuration. We can also configure the default nobody user and nobody group to something that we want. After updating the entries restart the “rpcidmapd” process and clear the idmap cache using “nfsidmap -c”.



Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s