linux如何查看所有的用户和组信息?

cat /etc/passwd

cat /etc/passwd|grep

cat /etc/group

cat /etc/group|grep 组名

groups 查看当前登录用户的组内成员

groups test 查看test用户所在的组,以及组内成员

whoami 查看当前登录用户名

posted on 2018-08-10 06:12  amirong  阅读(417)  评论(0)    收藏  举报

导航