How to Manage and Modify user Permissions in Linux

August 21, 2025 / Servers, Hosting & Email

In this article, we have explained how to manage and modify user permissions in Linux.

On a Linux system, limiting who can do what is essential for administration and security. A user’s ability to access files, make modifications, and run programs is determined by their permissions. You can use important commands like ‘chmod’, ‘chown’, and ‘usermod’ to examine, modify, and apply file and user permissions.

Let us first understand Linux Permissions:

Each file and directory in Linux carries three possible access rights:

  • Read (r): Enables the user to access and examine the contents of a file or a directory.
  • Write (w): Enables adding and deleting files within a directory as well as editing and deleting files.
  • Execute (x): Provides authorisation to enter a directory or run a file as a script or program.

These rights apply separately to three categories of users:

  1. Owner: Usually the user who created the file.
  2. Group: A set of users who share access privileges.
  3. Others: Everyone else on the system.

Linux File Permissions – Step by Step

  1. Check Current Permissions
    Use this to see what permissions a file or directory currently has:

    ls -l filename

    Example output:

    -rw-r--r--  1 alice staff  1200 Aug 26 14:30 report.doc

    Breakdown:
    • rw- > Owner (alice) = read + write
    • r– > Group (staff) = read only
    • r– > Others = read only

  2. Modify Permissions (chmod)
    If the current permissions don’t match your needs, change them using chmod.

    • Symbolic mode:
      chmod u+x script.sh

      Adds execute permission for the file’s owner.

    • Numeric mode:

      chmod 755 script.sh

      Owner = read, write, execute | Group = read, execute | Others = read, execute

  3. Change Ownership (chown)
    Sometimes you need to reassign who owns a file or its group.

    sudo chown newuser:newgroup file.txt

    Updates both the owner and the group of file.txt.

  4. Manage Group Access (usermod, gpasswd)
    Groups help manage permissions for multiple users.

    1. Add a user to a group:

      sudo usermod -aG developers bob
    2. Check group memberships:

      groups bob
    3. Remove a user from a group:
      sudo gpasswd -d bob developers

Best Practices

  • Apply the principle of least privilege, give users only the access they need.
  • Avoid granting write access to “others” unless necessary.
  • Use groups for efficiency when managing permissions across multiple users.

Linux user permissions can be managed and changed in this manner. Please do not hesitate to contact our support staff if you find any difficulties.

Want to manage permissions in cPanel too? Learn How to change file permissions in cPanel

Spread the love