How to use ACL

I want to set acl as a normal user. Fellow is my operation:

attr set sys.acl=u:test:r nnnn
error: unable to set attribute in file/directory /eos/home/nnnn: Unable to set attribute /eos/home/nnnn
(errc=1) (Operation not permitted)
attr set user.acl=u:test:r nnnn
error: unable to set user.acl - the file/directory does not evaluate user acls (sys.eval.useracl is undefined)!
(errc=22) (Invalid argument)
attr set sys.eval.useracl=1 .
error: unable to set attribute in file/directory /eos/hxmt/home/niejy/test: Unable to set attribute /eos/hxmt/home/niejy/test
(errc=1) (Operation not permitted)

And I set sys.acl as root, also give same error. What’s wrong with my operation?
Thanks。

Hi Nie,

Can you provide as a user from the standard command line, output from theese:
eos whoami
eos ls -l /eos/home/
eos ls -l /eos/home/nnnn
eos attr ls /eos/home/
eos attr ls /eos/home/nnnn

In order to have the right to set user acl you need:

  1. sys.eval.useracl=1 set on the directory/file by root on the MGM
  2. Properly authenticated user recognized by eos user
  3. To be the owner of the file/directory or have acl rights

Cheers