getfacl
Linux · Files · reference only
What it does
Shows the access control lists (ACLs) of files and directories: extra permissions for specific users and groups.
Syntax
getfacl [opciones] fichero...
Options and parameters
-aShows only the access ACL.
-dShows only a directory's default ACL.
-RWalks directories recursively.
-nShows numeric UID and GID instead of names.
-tUses a tabular format.
-pDoes not strip the leading slash from absolute paths.
Usage examples
getfacl informe.txtShows owner, group and the ACL entries of the file.
getfacl -R proyecto/Shows the ACLs of the whole project tree.
getfacl -d proyectoShows the ACL that new files in the directory will inherit.
getfacl a.txt | setfacl --set-file=- b.txtCopies the ACL of a.txt to b.txt.
Notes and common mistakes
- A + at the end of the permissions in ls -l means the file has an ACL.