Linux group basic introduction knowledge summary

Time:2021-5-8

1、 Introduction to Linux group

In Linux, each user must belong to a group, not independent of the group. In Linux, each file has the concept of owner, group and other groups

1) Owner

2) Group

3) Other groups

4) Change the user’s group

2、 File / directory owner

Generally, it is the creator of the file. Whoever creates the file will naturally become the owner of the file

1. View the owner of the file

1) Instruction: LS   – ahl

2) Application example:

2. Modify file owner

Instruction: chown   user name     file name

Application examples

requirement:

3、 Group creation

1. Basic command

groupadd   Group name

2. Application examples

 

4、 File / directory group

When a user creates a file, the default group of the file is the user’s group

1. View the group of the file / directory

Basic instruction      ls -ahl

2. Modify file group

Basic instruction chgrp   Group name   file name

3. Application examples

5、 Other groups

In addition to the owner and group of the file, other users of the system are all other groups of the file

The above is all the knowledge points of this introduction. Thank you for your study and support for developer.

Recommended Today

Looking for frustration 1.0

I believe you have a basic understanding of trust in yesterday’s article. Today we will give a complete introduction to trust. Why choose rust It’s a language that gives everyone the ability to build reliable and efficient software. You can’t write unsafe code here (unsafe block is not in the scope of discussion). Most of […]