I have server (debian 6) machine (say, ip = with nfs exports



There are two users on this machine admin (uid = 1000) and user (uid = 1001)

on client machines (also debian 6) (say, ip = i have /etc/fstab /my/mount/point nfs rw,exec,user,owner 0 0

There is only one user (uid = 1000)

after reboot or mount -a, the shared folder is mounted successfully, but i can not execute any file on it (even if files have exec permissions). However, read and write for files on this file system works fine.


3 Answers 3


May be the noexec flag is set.

  • I have the noexec flag for my shared folder entry in /etc/mtab.. even if I remove the entry from mtab and than unmount and mount the shared folder, the noexec appears again.. Why? And how can i fix this???
    – yakki
    Mar 18, 2013 at 19:27
  • It is the default for nfs. You may add the exec option to change it.
    – Brigo
    Mar 18, 2013 at 19:33
  • Should I add it to client:/etc/mtab? or server:/etc/exports? or client:/etc/fstab?
    – yakki
    Mar 18, 2013 at 19:36
  • /etc/fstab, i think, but not really sure, sorry. :-)
    – Brigo
    Mar 18, 2013 at 19:37
  • its already in fstab, and still does not work=( thanks anyway
    – yakki
    Mar 18, 2013 at 19:42

The culprit is the user option you have used in /etc/fstab, and specifically that you have placed the exec option before the user option.

From man mount:

user: Allow an ordinary user to mount the filesystem. ... This option implies the options noexec, nosuid, and nodev (unless overridden by subsequent options, as in the option line user,exec,dev,suid).

I suppose this behaviour is for security reasons. Anyhow, whenever you use user, you should specifically add an exec option if that is what you want and it should be after the user option to override the noexec implied by user.

  • /mnt/nfs nfs defaults,user,exec,dev,suid 0 0 in my fstab and I can run .sh scripts from my nfs share again
    – Ahi Tuna
    Mar 16, 2022 at 23:28

I've fixed the issue by changing the client:/etc/fstab contents to the following: /my/mount/point nfs rw,exec 0 0
  • 1
    This won't allow sudo-less mount though.
    – John Jiang
    Jan 10, 2021 at 6:35

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .