This section also speaks of user and user group managementOr retry the previous user-limited issueCan be used chage can also use USERADD-EChage-l View the user's time limit and some other informationYou can also use USERMOD-E to set time limits.The old boy here said there are many commands to set up some of the same functionsBut all we have to do is use one of our habits and preferences.You don't have to remember anything.And then speaking of Userdel command,Userdel-r User name to delete home di
This section is mainly about using scripts to build accounts in bulk#/bin/sh #这是脚本使用的命令, we're using the scripting language SH#authur: Arthur #作者#qq: 10000 #这是联系方式For num in ' seq 3 'DoUseradd $suerchars $numPasswd= ' date|md5sum|cut-c3-20 'echo "$passwd" |passwd--stdin $userchars $numEcho-e "User: $userchars $num\tpasswd: $passwd" >>/tmp/user.logSleep 1DoneEcho----------------------------------------Cat/tmp/user.log20161108l04-05 old boy Linux OPS training
Front User GroupAdd User Group commandGroupaddWe just need to remember some common parameters.Groupadd-g 8888 Syz #添加 GID 888 user GroupView grep syz/etc/group after adding completeThe point is, passwd, this command.Used to change the passwordPasswd-d This is the delete passwordWith passwd This command, root can change any user's password, and is not required to lose the original passwordPassword for other user passwords, and can only change their own passwordPasswd-l lock account, cannot log in
Operational commands for some Linux usersUseradd Creating a userAddUser Creating a userpasswd Password Change commandUsermod Change the user name, and the user directoryUserdel Deleting a userID shows the user uid and GIDGroupadd Creating a user groupGroupdel Deleting a user groupGroupmod changing user group name informationGroups displays the group to which the user belongs/etc/skel When a user creates a new user and defaults to the location of the configuration/etc/login.defs is used to define
/wKiom1ed5UbwkvKjAAHU-XzUyaw119.png "title=" 7.png " alt= "Wkiom1ed5ubwkvkjaahu-xzuyaw119.png"/>650) this.width=650; "src=" Http://s1.51cto.com/wyfs02/M02/85/3D/wKioL1ed5XOQi1YMAAGWPqHx9Zk325.png "title=" 8.png " alt= "Wkiol1ed5xoqi1ymaagwpqhx9zk325.png"/>CP,RM,MV Differences in inode usageCP: Allocating idle inode numbersRM: When deleting data, the inode is deleted first and data is temporarily not deletedMV: On the same file system, the data does not move, just change the inodeWhen not on the
Or is that sudo and su?When you log in with Su, add the following-Because of this, the environment variable will become the switch user'sThis can cause unnecessary trouble if you do not use environment variables.General Sudo is not allowed for remote logins, because passwords are plaintext and are very insecureBut you can use ssh-t [email protected] sudo-l this way to log inOkay, I'm done.20161129l04-09 old boy Linux OPS training-linux system user and
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.