1846551 Members
1790 Online
110256 Solutions
New Discussion

ACL setting problem

 
Matthew_50
Valued Contributor

ACL setting problem

I have two user accounts. userA and userB. userA belongs A group,
userB belongs B group. the userA's umask is 0137

$ls
drwxrwxr-x 2 userA A 1024 Nov 17 15:57 Ericsson_2

$ ls -l Ericsson_2/
total 36
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.I
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.J
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.K
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.L
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.M
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.N
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.O
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.P
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.Q
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.R
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.S
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.T
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.U
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.V
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.W
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.X
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.Y
-rw-r----- 1 userA A 17 Nov 17 15:41 154136.Z

now, the userB would like to read the files which under Ericsson_2 dir.
I know I have to set the acl like this `setacl -m user:userB:r-- Ericsson_2/*`
but, userA will create the file minutes by minutes, how can I setup my acl, let
userB can read new files which create by userA, or I can't ? or should I write
a cron script let it set the acl permissions ?

Note: Can't change userA's usermask.

Thanks for help!!

1 REPLY 1
Siem Korteweg
Advisor

Re: ACL setting problem

Assign a "default" ACL to the directory. This ACL will be assigned to all new files and sub-directories.

setfacl -m d:u:userB:rx Ericsson_2

Siem