修改文件/etc/login.defs

[root@linux ~]# cat /etc/login.defs |grep -v "#" MAIL_DIR /var/spool/mail PASS_MAX_DAYS 99999 ---过期时间 PASS_MIN_DAYS 0 ---最短时间 PASS_MIN_LEN 5 PASS_WARN_AGE 7 UID_MIN 500 ---UID最小值 UID_MAX 60000
GID_MIN 500 ---GID最小值 GID_MAX 60000 CREATE_HOME yes ---是否创建家目录 UMASK 077
USERGROUPS_ENAB yes ENCRYPT_METHOD SHA512