How can we fstab mount a samba share that give permission 0777 (to every samba users in the write list) for new created directory or files? E.g. I created a new directory in client PC (Ubuntu 12.10), and want the directory to have permission drwxrwxrwx in the server (Ubuntu 12.04 LTS).

dir_mode=0777,file_mode=0777 already been set in the fstab, still no effect. I can read/write the mounted smb share, but other users in the write list cannot write to the new directory created by me. The permissions in server is always drwxr-xr-x.

Other option that I have tried 'nounix', 'noperm','uid'. But still cannot get it work.

Any idea?

2 Answers 2


You can use the next configuration (for example):

   comment = Users profiles
   path = /var/www/site-red
   guest ok = no
   valid users = josecarlos yovany
   admin users = josecarlos yovany
   browseable = yes
   create mask = 0600
   directory mask = 0700
   write list = josecarlos yovany
   force group = www-data
   force user = www-data

I hope help you ;-)


To clarify on josecarlos answer, the change you are looking for is in the smb.conf file of the server (Ubuntu 12.04 according to your post).

The "create mask" and "directory mask" options are what you want to set 0777.

The reason is that your samba server has ultimate authority, even if you mount the share with 'nounix', 'noperm','uid' options on the client, this will not impact how samba (the server) will share these files and folders.

You must log in to answer this question.

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