Linux User Management -3__linux

Source: Internet
Author: User

Root user created directory Normal user does not have write permission, you can change the file's owning group by

For example: 1.groupadd softadm Add a group. 2.usermod-g softadm username (gpasswd-a user name Softadm) 3.chgrp softadm/software Change Directory-owning group, 4.chmod G+w/software

Pwck Detect/etc/passwd File error

VIPW edit/etc/passwd file can lock this file and other users cannot edit it

ID View User ID and group information

Finger View User Details

Passwd-s View User Password status

Who,w View current logged-in user information

Su-User plus-after can switch environment variables such as user's host directory

Lock User:

PASSWD-L user name-U for unlocking some need to be-uf (usermod-l username can be locked)

The principle of locking: In the MD5 encrypted password before the join!!, you can edit the user password by editing Vi/etc/shadow password before joining!!

Delete User:

Manual deletion: Use the Find command to locate a file belonging to a user or group of users Find/home-user (-uid,-group,-gid) to find a user file

User Management commands

Chage Set Password (This command is only for Linux)

-L View User password settings

-M password modified minimum days

-M maximum Days

-D Password Modification date

Number of days to lock accounts after the-l password expires

-E

-W

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.