Linux File Permissions

Explanation

For example: dwrxr–r– You can split this in 4 segmenst: d wrx r– r–
d means the name is a directory. wrx is the first of 3 permission segments, and represents the owner. The next segment is for the same group users, and the last is for other users like guests.

Above stands for: directory, writable, readable, exacutable. Readable (by same group user), Not writable (by same group user), only readable by other (guest) users.

Change permissions

Change fileperission on newfile.txt

chmod 660 newfile.txt

660 is a binary notation which represents the permission level.
7 Read-write-execute
6 Read-write
5 Read-execute
4 Read
3 Write-Execute
2 Write
1 Execute
0 No permissions

Comments

Leave a Reply