Reading Permissions
Part of the Fundamentals section of Coddy's Terminal journey — lesson 54 of 82.
Use ls -l to display the detailed file listing and examine the permission strings for each item.
Look at the output and identify the permissions for each file and directory. For each item, read the 10-character permission string and determine:
- Whether it's a file (
-) or directory (d) - What permissions the owner has (first group of three)
- What permissions the group has (second group of three)
- What permissions others have (third group of three)
Run the command:
ls -lIn the output, notice how backup.sh, report.txt, and config.cfg are regular files. Observe their specific read and write permissions for the owner.
Compare these to the projects directory, which starts with d instead of -, and has execute permission which allows users to enter the directory.
Challenge
EasyUse ls -l to display the detailed file listing and examine the permission strings for each item.
Look at the output and identify the permissions for each file and directory. For each item, read the 10-character permission string and determine:
- Whether it's a file (
-) or directory (d) - What permissions the owner has (first group of three)
- What permissions the group has (second group of three)
- What permissions others have (third group of three)
Run the command:
ls -lIn the output, notice how backup.sh, report.txt, and config.cfg are regular files without execute permission (x). Compare these to the projects directory, which starts with d instead of - and includes execute permission, allowing users to enter the directory.
Try it yourself
This lesson includes a short quiz. Start the lesson to answer it and track your progress.
All lessons in Fundamentals
4Directories
Create A DirectoryCopy A DirectoryMove And Rename A DirectoryDelete A DirectoryRecap - Directory Operations7File Content
Head And TailWord CountSort CommandUnique CommandGrep BasicsGrep With FlagsRecap - Text Detective2Navigation
Print Working DirectoryList FilesChange DirectoryAbsolute vs Relative PathsHome And Root DirectoryRecap - Find Your Way8Redirection
Standard OutputOverwrite To A FileAppend To A FileStandard InputStandard ErrorRecap - Log Builder11Permissions
Understanding PermissionsReading PermissionsChmod With NumbersChmod With SymbolsFile OwnershipRecap - Lock It Down6Wildcards And Patterns
The Star WildcardThe Question Mark WildcardBracket WildcardsCombining WildcardsRecap - Selective Operations9Piping
What Is A PipeChaining Two CommandsChaining Multiple CommandsPipe With GrepRecap - Data Pipeline