Restore default user groups

Hi all,

I made a mistake/typo/whateveryouwannacallit while adding my user to a group, as root.

I ran

usermod -G <groupname> mirdarthos

instead of

usermod -aG <groupname> mirdarthos


Now, I think I’ve restored everything as it should be. At least, I can work and use my computer without any poroblems. But I just want to make sure and be certain about it.

So, my question is whether there is any command to check if a user belongs to all the default groups, and add it to those that he/she/it isn’t a member of?

Alternatively, can you please post a list of the default user groups, so that I can manually double check them?

man id

I can only list the groups my account here is a member of. Things may differ at your end, depending on the software you’ve installed.

1 Like

Thank you @Aragorn.

This is exactly what I was looking for!

1 Like

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.