Directory of Linux Systems explained

Source: Internet
Author: User

Remember that in the previous introduction of the C H o d command, the permissions bits and files of the directory are different. Now let's take a look at the difference. The Read permission bit for a directory means that the contents can be listed. The Write permission bit means that you can create files in this directory, and you can cancel the corresponding write permission bits if you do not want other users to create files in your directory. Executing a permission bit means searching for and accessing the directory (see table 1-5, Table 1-6).

If you set the permissions of the same group of users or other users to a directory--X, they will not be able to list the files in that directory. If the directory has a script or program that executes a location bit, it can still be executed as long as the user knows its path and file name. The user's ability not to enter the directory does not hinder his execution.

Permissions on the directory will overwrite the permissions of the files in that directory. For example, if directory d o C S has the following permissions:

And the permissions for the file p a Y are:

The user of a D m i n group will not be able to edit the file because the directory it belongs to does not have such permissions.
The file is readable to any user, but because the directory in which it resides does not give execute permissions to users of the A D m i n group, users of that group will not be able to access the directory, and they will get an "Access restricted" error message.

Directory of Linux Systems explained

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.