Linux Command Learning

Source: Internet
Author: User

Whereis // find a directory of commands, such as Whereis Curl  ls    ls-mkdir-chown-  chmod777  directory name  777 is the full permission, 1 performs 2 reads 4 writes all has is 7  chmod +x adds the executable one method

File Permission Explanation:

The first bit (left number) in the drwxr-xr-x indicates whether the current directory is a directory or a file, D represents a directory, and-represents a normal file.
The following 9 bits are divided into 3 groups, each 3 groups as 1 groups, from left to right, respectively, the file owner, file group, and all other user permissions.
R means the file is readable, w means the file is writable, and X indicates that the file can be executed.
Change file permissions with the command chmod. There are two kinds of

chmod (Ugoa) (=-+) (rwx) file
U represents the owner of the document, G represents the group of documents, and O represents the user of the system except the owner and the members of the group, and a represents the sum of all users (U,g,o)
+ means to increase the corresponding permissions,-the delegate reduces the appropriate permissions, = represents only the appropriate permissions
chmod g-w file will be able to complete the permissions of the above files to correct.
The second Kind
Corrected with numbers, R is 4,w to 2,x for 1
Add numbers to the corresponding permissions, such as RWX is 7,RW is 6
The permission method to correct the above problem is
chmod 775 file on the line.

Linux Command Learning

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.