acl_delete_entry - Linux


Overview

acl_delete_entry removes specified access control list (ACL) entries from the given file or directory. It’s primarily used for modifying permissions for specific users, groups, or other entities within a file system.

Syntax

acl_delete_entry [options] file acl_type:identifier

Options/Flags

  • -v, –verbose: Print verbose information.
  • -l, –show-acl: Print the ACL after modifications.
  • -R, –recursive: Recursively apply the ACL changes to all subdirectories.
  • -k, –skip-errors: Skip errors on non-readable files or directories.
  • -n, –dry-run: Only print the changes that would be made without actually modifying the ACL.
  • -a , –acl : Specify the ACL to be modified. Default: "access". Valid options: "access", "default".

Examples

Remove ACL entry for user "username" from file "my_file":

acl_delete_entry my_file user:username

Recursively remove all ACL entries for group "my_group" from directory "my_dir":

acl_delete_entry -R my_dir group:my_group

Common Issues

  • Permission denied: Ensure you have sufficient permissions to modify the ACL.
  • File not found: Verify the file or directory path is correct.
  • Invalid ACL entry: The specified ACL entry must match an existing entry in the ACL.

Integration

acl_delete_entry can be used in combination with other ACL-related commands, such as:

  • getfacl: Retrieve ACL information.
  • setfacl: Set or modify ACL entries.
  • acl: Manage ACLs using a graphical interface.

Related Commands