1

Have user1 and user2. They are in usergroup1.

in console run it:

sudo chgrp -R usergroup1 /folder

Lihe this - https://help.ubuntu.com/12.04/serverguide/samba-fileprint-security.html > Share Security.

In smb.conf

[folder]
comment = folder
path = /folder
browsable = yes
writable = yes
guest ok = no
write list = user1, user2
create mask = 0777

But only user2 can create/delete files.

I think it because before that I run in console:

sudo chown -R user2 /folder

How set folder writable for both users?

Also I try

write list = user1 user2

Without a comma. But so does not work.

UPD

I try change owner like this http://en.wikipedia.org/wiki/Chown

chown -R :usergroup1 /folder

And edit smb.conf like this

write list = @usergroup1

But still both users can't add/del file in /folder.

UPD2 - Solution

I can cunfig it! Hope it help somebody.

smb.conf

[folder]
comment = folder
path = /folder
browsable = yes
writable = yes
read only = no
create mask = 0770
directiory mask = 0770
valid users = @usergroup1

And mod for folder

chmod 775 /folder
  • 1
    Please post the solution in the answer box below, so this question shows up as answered! – Grimtech Mar 23 '13 at 21:46
1

ok.. let's try this..

parent folder (chmod 777 / chown nobody:nogroup -R)

  • Folder1 (chmod 770 / chown nobody:group1 -R)
  • Folder2 (chmod 770 / chown nobody:group2 -R)

    useradd user1 group1 useradd user2 group2

at samba...

[group1]
guest ok = no (or yes you must check this)
force user = nobody
force group = group1
writelist = user1 @group1
read list = user2 @group2

same for the [group2] but change the order os users at write and read...

bye!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.