Remove ACLs in Linux permissions

0

I have files that have a plus sign next to the permissions -rwxrwx---+ on a Linux samba server. I found the setfacl command to adjust the acl settings, I would like to remove the ACL completely, instead of having to adjust acl settings. How can I do this, so that users can access the files that they need, and the permissions would show -rwxrwx---, in Linux?

thecomputerguru

Posted 2019-10-10T00:50:16.607

Reputation: 329

Answers

2

You should also have found this setfacl option:

-b, --remove-all        remove all extended ACL entries

So in order to remove ACLs just run setfacl -b -R on the directory, and chmod g=rwx afterwards. (Fixing group permissions might be needed, because currently your changes actually went to changing the ACL 'mask' instead.)

Note that Samba directly exposes POSIX permissions and ACLs to SMB clients (translating them to SMB/NTFS ACLs), so the same could be done from Windows by manually removing all except the 3 "Unix" access entries.

user1686

Posted 2019-10-10T00:50:16.607

Reputation: 283 655