Linux notes: User profiles

Source: Internet
Author: User

User Information file:/etc/passwd
Function: Store user's basic information
Each row represents a user.

First field: User name
Second field: Password flag (just a placeholder for a password that indicates that the user has a password and does not hold a real password)
Third field: UID (User ID)
The UID of which,
0: Super User
1-499: System users (some system processes)
500-65535: Normal User
Fourth field: GID (user initial group ID)
Initial group: Each user immediately login to have the initial group of relevant permissions, each user's initial group can only have one, generally is the user name of the same group name.
Additional groups: Users can join multiple other groups of users.
Fifth field: User description
Sixth field: Home directory
Normal User:/home/user name/
Super User:/root/
Seventh field: Shell used after login


Shadow file (password file):/etc/shadow
Function: Save user password related
First field: User name
Second field: Encrypt password
Third field: The last modification time of the password
Fourth field: Set the time interval between password changes 2 times
Fifth field: Password validity period (must be modified after password expires)
Sixth field: Number of warning days before password expiration
Seventh field: The number of days after the password expires (0 means that the password expires immediately after expiration, 1 means that the password will never expire.) )
Eighth field: Account Expiration time
Nineth field: Reserved fields

Group information file:/etc/group
Function: Store user group information.
First field: Group name
Second field: Group password flag
Third field: GID
Fourth field: Additional users in the group

Group Password file:/etc/gshadow
First field: Group name
Second field: group password
Third field: Group Administrator user name
Fourth field: Additional users in the group


User Management related files

User's home directory:
Normal User:/home/user name/, owner and owning group are this user, permissions are 700
Superuser:/root/, owner and owning group are root users, permissions are 550

User Templates directory:/etc/skel/
Function: When creating a new user or user login, the files in this directory are generated by default in the user's home directory.

Linux notes: User profiles

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.