Posts Tagged ‘CIFS’

How to: Implement Samba Share on CIFS (Common Internet File System)

Monday, May 18th, 2009

It took me a while to achieve the proper implementation and inheritance of privileges. But all in all, it boils down to this post.

I will make this short and easy.

Mounting a Network Attached Storage (NAS) via file system table (fstab):

//192.168.1.2/MyShare /mnt/MyShare cifs user=MyUser,pass=MyPassword,gid=users,rw 0 0

Add samba user account to users group:
usermod -G users aby

And lastly, in Samba config:

[myshare]
path = /mnt/MyShare
valid user = aby
force user = aby
force group = users
browseable = yes
writable = yes
public = no
create mask = 775
directory mask = 775

**Disclaimer: I had to this workaround for a NAS although without all these complex (if I may say) settings in another NAS actually worked and is still working. It’s just too weird to be true. (yes, weird. I can’t explain the orthodox myself.)