Linux command----chmod

Source: Internet
Author: User

Function: Change the file's ownership rights

chmod [OPTION] ... Mode... FILE ...

u user

Group G

o Other

A All users (default)

+ Add Permissions

-Delete Permissions

= Reassign Permissions

R Read

W Write

X execution

s set user (or group) ID number

T set the sticky bit (sticky bit) to prevent files or directories from being deleted by non-owner

For permission settings, we typically use a 3-bit octal number representation: 4 (Read), 2 (write), 1 (Execute)

You can also set the 4-bit, which is in front of the 3-bit permission sequence, with values of 4, 2, 1

4 Set the user ID at execution time for authorization to a file-based process rather than to the user who created the process

2 Set user group ID at execution time for authorization to processes based on the group of files, rather than on the user who created the process

1 this sticky bit.

Linux command----chmod

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.