What does each permission symbol mean?

QuestionsQuestions8 SkillsProBasic Files OperationsNov, 03 2025
0115

In the output of the ls -l command, the permission symbols indicate the access rights for the file or directory. Here's a breakdown of what each symbol means:

Permission Symbols:

  1. File Type:

    • The first character indicates the type:
      • -: Regular file
      • d: Directory
      • l: Symbolic link
      • c: Character device
      • b: Block device
      • s: Socket
      • p: Named pipe (FIFO)
  2. User Permissions (next three characters):

    • The next three characters represent the owner's permissions:
      • r: Read permission (owner can read the file)
      • w: Write permission (owner can modify the file)
      • x: Execute permission (owner can execute the file or access the directory)
  3. Group Permissions (next three characters):

    • The following three characters represent the group's permissions:
      • r: Read permission (group can read the file)
      • w: Write permission (group can modify the file)
      • x: Execute permission (group can execute the file or access the directory)
  4. Other Permissions (last three characters):

    • The final three characters represent permissions for others (everyone else):
      • r: Read permission (others can read the file)
      • w: Write permission (others can modify the file)
      • x: Execute permission (others can execute the file or access the directory)

Example:

For the permission string -rw-r--r--:

  • -: Regular file
  • rw-: Owner can read and write
  • r--: Group can read only
  • r--: Others can read only

If you have more questions or need further clarification, feel free to ask!

0 Comments

no data
Be the first to share your comment!