User Management
useradd create user
Options:
-u UID
-g GID
-d Home directory, ordinary users have the highest authority in the home directory; the default is in the /home directory of the operating system.
-s User-enabled shell, GUI and command line after login.
[root@localhost zyj]# useradd sl // Create home directory and group ID by default, username id and shell after login [root@localhost zyj]# cd / home [root@localhost home]# ls hello.txt sl x zyj [root@localhost sl]# more /etc/passwd root:x:0:0:root:/root:/bin/bash bin:x:1:1:bin:/bin:/sbin/nologin daemon:x:2:2:daemon:/sbin:/sbin/nologin adm:x:3:4:adm:/var/adm:/sbin/nologin sl:x:501:501::/home/sl:/bin/bash
userdel: delete user
[root@localhost sl]# userdel sl [root@localhost sl]# more /etc/passwd root:x:0:0:root:/root:/bin/bash bin:x:1:1:bin:/bin:/sbin/nologin daemon:x:2:2:daemon:/sbin:/sbin/nologin adm:x:3:4:adm:/var/adm:/sbin/nologin zyj:x:500:500: python_full:/home/zyj:/bin/bash
usermod
passwd
chsh
chfn
finger
id
chage
group management
groupadd
groupdel
groupmod
gpasswd
authority management
chown
chgrp
chmod
umask