Linux files have there own permissions set-up. There are mainly there types of access permission:
  • Read
  • Write
  • Execute


Permission sets in linux for files and directories

There is permission set for the Owner, Group and Others. When you type " ll " you will get 10 set of values for each files eg: -rw-rw-r-- 1 name name 41333 Aug 18 22:57 jpg . The 1st bit denotes if its a directory or file. 2nd, 3rd and 4th bit is the owner's permission. 5th, 6th and 7th bit is group's permission and 8th, 9th and 10th bit is for other's permission. According to the example owner and group has read/write permission and other's have only read permission.
You can change the permission of a file. Try chmod 777 filename. This will give owner, group and other's full permission (read/write/execute) over the file.

Permission Sets
  • 1 - Execute
  • 2 - Write
  • 3- Write and Execute
  • 4- Read
  • 5- Read and Execute
  • 6 - Read and Write
  • 7 - Read, Write and Execute
Try chmod 700 filename. This will give the owner of the file full permission. The Group and other's will have no permission to access the file. Only the owner of the file can read, write or execute the file. If you want other and Group only to read the file you can givechmod 744 filename.


Leave a Reply

Subscribe to Posts | Subscribe to Comments

Blog Archive

Powered by Blogger.

- Copyright © 2013 Taqi Shah Blogspot -Metrominimalist- Powered by Blogger - Designed by Johanes Djogan -