Linux permission details: how to configure multiple sets of permissions for multiple users

Source: Internet
Author: User

Linux permission details: how to configure multiple sets of permissions for multiple users

There are too many details about Linux permissions on the Internet. The main explanation is that these permissions are not applicable to other users or groups.

I. Permission Classification

R: Read Permission, number code: "4 ".
W: Write Permission. The number is "2 ".
X: execute or switch the permission. The number is "1 ".
-: You do not have any permission. The digit code is "0 ".

In linux, each segment is r + w + x, and the maximum value is 777. For details, see


Ii. When to use Permissions

Directory write permission: YesAdd/deleteAll contents in the directory,ChangeFile and directory name. <喎?http: www.bkjia.com kf ware vc " target="_blank" class="keylink"> VcD4KPHA + xL/Signature + CjxwPsS/authorization/J0tS9 + MjrxL/authorization + 0 LTIqM/eo7q/authorization + tsHIqM/eo7q/authorization + authorization/sP8we48L3A + Cgo8aDI + Signature + u/fingerprint + 38zl0Ke5 + 6GjPC9wPgo8cD682cnoZ3J1b3DI58/Co7o8L3A + cjxwp1_vcd4kphbyzsbjbgfzcz0 = "brush: java; "> getso: x: 502: jerry, laohujerry: x: 506:

That is, jerry is the master of the jerry group and belongs to the getso group. Laohu is not the master and only belongs to the getso group.

Effect:

Jerry and laohu use the group permission to access the getso object.

Getso is used to access files of jerry and laohu with public permissions.

Laohu uses public permissions to access jerry and group permissions to access getso.

Getso group to which the file created by laohu belongs

The files created by jerry and getso belong to their own group.

In this case, we can solve all the issues that do not have access permissions.

Iv. User Group changes

Usermod-G getso jerry makes jerry a member of getso

Usermod-g getso jerry makes jerry a member of getso, and jerry is not the leader.

Gpasswd-M jerry getso makes jerry a member of getso

Gpasswd-d jerry getso makes jerry no longer a member of getso

Related Article

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.