About CHMOD

Do you know about CHMOD command?  Yf you dont know about CHMOD, please read this article carefully. I will write little bit about CHMOD and if you are not satisfied with this article please go to your favorite search engine and search it.
I think CHMOD is abbreviations of CHange MODe. Is there any other who doesnt agree with me?? Actually CHMOD is used to add and subtract users permission to access files or directory, you can also use a numeric system code or letter system code.Every files have permission for its owner, group and other. There are three types of permissions :

  • -r to read
  • -w to write
  • -x to exceute

numeric description for permissions above :

  • 1 = cd permission to perform to a directory.
  • 2 = permission to write.
  • 4 = permission to read.

 

File permission diagram:
chmod diagram
For example we have the default permissions 711 for a directory, so that means:
7 = 4 +2 +1: you (the owner) can read / write / execute files.
1 = 1: all users in your group can do "cd" command / execute but not read and write.
1 = 1: all the user is not a group you can do "cd" command / execute but not read and write.

Suppose we have a public_html directory permissions 755 means:

7 = 4 +2 +1: you (the owner) can read / write / execute files.
5 = 4 +1: all users in your group can "cd" command / execute / read but not write.
5 = 4 +1: the user is not a group you can "cd" command / execute / read but not write.

Files you create at least public_html directory should have permissions 644 (directory must be 755) or WWW server will not be able to read it that can not appear in the web browser.

to change the index.html file permissions we use this command:
chmod 644 index.html

to create a directory of images and contents of his files can be read by all user:
chmod 755 images
cd images
chmod 644 *

to hidden a file we use:
chmod 700 nama_file.

 



Add this page to your favorite Social Bookmarking websites

Add comment


Security code
Refresh

Who's Online

We have 12 guests online
© 2010 BitOfCloud.com | Jasa Pembuatan Website, Translate, Online Shop
Blogger Indonesia Dukung Internet Aman, Sehat & Manfaat