I would like to know, why it is required to reboot, to apply the changes, which I made.

I refer to the use of

adduser username sudo

I use Ubuntu 12.04.1 LTS "Server".

up vote 6 down vote accepted

You are not required to reboot the system but you have to log out and log in again. Group membership is evaluated at login time only.

If you are in a situation in which logging out and back in is inconvenient (for example, an SSH session) then you can just spawn a login subshell with su - <user> (or equivalently su -l <user> or su --login <user>) but it will work only in that subshell.
(thx to steeldriver for pointing this out).

to test, from your terminal call


which will show you your username and group, for your current login session. it's the only way to know for sure whether your change was correct. The output will be something like

uid=102(andrew) gid=101(users) groups=101(users),14(sysadmin)

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.