If I use command:
adduser [username] [groupname], then the user would be added to the group, and the file
/etc/group would then be updated.
However, the file
/etc/passwd is not updated. if I check which group I belongs to, via
groups command, I can only see groups stated in
passwd file.. therefore, the user is not added to the group base on this result.
Mirror Question: https://stackoverflow.com/questions/31530362/where-how-is-user-group-information-stored-in-ubuntu. (I'll remove one of them after I got the answer)
- What's the meaning of storying group info into
adduseronly update the
- How to add group to the
passwdfile via command?
- Why does
groupsreturn group info from
passwdfile, but not