I am in to the process of setting up a new machine (ubuntu2) in which two users will login (let's name them user1 and user2). To manage the machine I have added a third user 'admin'. All users are all members of the same group (users).
On this machine the admin user permanently mounts a samba share shared by another ubuntu machine (ubuntu1) (the choice for samba was made as this share will also be mounted by windows and mac machines).
The relevant section in the smb.cnf on ubuntu1:
Code:
[Linux-Share-01] guest ok = no path = /storage/shared valid users = @users write list = @users force group = users force directory mode = 0775 force create mode = 0775 browsable = yes
Code:
//ubuntu1/Linux-Share-01 /mnt/Linux-Share-01 cifs credentials=/home/admin/.smbcredentials 0 0
Currently, the files written by user1 and user2 on the share will be owned by the 'admin' user:
Code:
-rwxrwxr-x 1 admin users 0 mrt 11 19:13 x.dat
Code:
-rwxrwxr-x 1 user1 users 0 mrt 11 19:13 x.dat -rwxrwxr-x 1 user2 users 0 mrt 11 19:13 y.dat
برچسب:
نویسنده: استخدام کار