执行命令如下:
[root@hds01 home]# useradd -s /sbin/nologin -M -g wwwgroup nginx
-s表示指定用户所用的shell,此处为/sbin/nologin,表示不登录。 -M表示不创建用户主目录。 -g表示指定用户的组名为wwwgroup。 最后的nginx表示用户名。