LLEARNING NOTES

技术 · 思考 · 实践 · 成长

首页/Linux/正文

linux - gpasswd命令添加、删除组成员

Linux585 次阅读


groupdel命令可以删除指定的用户组


# 格式:

gpasswd [选项] 用户名 组名

# 选项:

-a 向组中添加用户

-d 从组中删除用户-d 


# 将用户super加入root组中

[root@node-a shell]# gpasswd -a super root
Adding user super to group root
[root@node-a shell]# id super
uid=1000(super) gid=1000(super) groups=1000(super),0(root)


# 将用户super从root组中删除

[root@node-a shell]# gpasswd -d super root
Removing user super from group root
[root@node-a shell]# id super
uid=1000(super) gid=1000(super) groups=1000(super)


顺,不妄喜;逆,不惶馁;安,不奢逸;危,不惊惧。--史记

评论交流

理性讨论,共同进步
验证码

相关文章

继续阅读