February 2020
Intermediate to advanced
666 pages
15h 45m
English
With the numerical method, you'll use an octal value to represent the permissions settings on a file or directory. For the r, w, and x permissions, you assign the numerical values 4, 2, and 1, respectively. You would do this for the user, group, and others positions, and then add them all up to get the permissions value for the file or directory:
| User | Group | Others |
| rwx | rwx | rwx |
| 421 | 421 | 421 |
| 7 | 7 |
7 |
So, if you have all the permissions set for everybody, the file or directory will have a value of 777. If I were to create a shell script file, by default, it would have the standard 664 permissions, meaning read and write for the user and group, and read-only for others:
-rw-rw-r--. 1 donnie ...