Common linux account management commands

Source: Internet
Author: User
1groups lists all groups to which the current user belongs. 2. change the valid user group to groupname for the current user. A user can belong to multiple groups, but there is only one valid user group. when a new file is created, the file belongs to the valid user group. 3. use...
1 groups: list all groups to which the current user belongs. 2. change the valid user group of the current user to groupname in newgrp groupname. A user can belong to multiple groups, but there is only one valid user group. when a new file is created, the file belongs to the valid user group. 3. useradd [-d home] [-s shell] [-c comment] [-m [-k template] [-f inactive] [-e ex pire] [-p passwd] www.2cto.com uname creates a user, username: uname 4. passwd [useraccount] set the password for useraccount 5. usermod [-LU] [-c <备注> ] [-D <登入目录> ] [-E <有效期限> ] [-F <缓冲天数> ] [-G <群组> ] [-G <群组> ] [-L <帐号名称> ] [-S ] [-U ] [User account] changing certain attributes of a user 6. userdel [-r] username: delete a user.-r: delete the user together with the home directory. 7. finger username: View usernam information www.2cto.com 8. id [username] query User UID, GID related data 9. groupadd [-g gid] [-r] groupname creates a group named groupname.-r indicates creating a system User Group 10. groupmod [-g gid] [-n new_name] ori_groupname: name and group id 11 of the change group. groupdel [groupname] delete user group 12. change the password of gpasswd by zk1878

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.