Filetype + users permission | Index
/ links |
owner | user | size | date | time | File name |
– rw-rw-r– | 1 | opc | opc | 0 | Sep 5 | 02:31 | file2 |
File Types ( first letter ) |
|
d : directory | l: link |
File Permissions | r → read (r) | w → write (w) | e → execute (x) |
rw- rw- r– ( – means no permission) | first three for owner/admin (a) | next : group (g) | last : others (o) |
1 | Add – Owner(a) + execution(x) to file | chmod a+x <filename> |
2 | Add – group(g) + execution(x) to file | chmod g+x <filename> |
3 | Add – others(o) + execution(x) to file | chmod o+x <filename> |
4 | Add owner,group,other + exe(x) to file | chmod o+x,g+x,o+x <filename> |
5 | Add all permission to all | chmod o+rwx,g+rwx,o+rwx <filename> |
File Permissions | r → read (4) | w → write (2) | e → execute (1) |
rw- rw- r–(-means no permission) | rw- →owner : r+w+e=4+2+0=6 | rw- →group : r+w+e=4+2+0=6 | r- – →others : r+w+e=4+0+0=4 |
1 | Add Permissions a→rwx, g→rw, o→r ⇒ rwxrw-r– | chmod 764 <filename> |
2 | Add Permissions a→rwx, g→rw, o→r ⇒ rwxr–r– | chmod 744 <filename> |
3 | change –xr–r– ⇒ rwxr-xr– | chmod 754 <filename> |