I've added myself into the sudoers users list by using the commandroot@debian:/home/oshirowanen#adduser oshirowanen sudoIf I try to run that command again, root@debian:/home/oshirowanen# adduser oshirowanen sudoThe user `oshirowanen' is already a member of `sudo'.root@debian:/home/oshirowanen# All looks good so far.When I then exit the root user and try to install/remove/search something using my own account, it doesn't work and complains that I am not a sudoer...  For exampleroot@debian:/home/oshirowanen# exitexitoshirowanen@debian:~$ sudo aptitude search ice[sudo] password for oshirowanen: oshirowanen is not in the sudoers file.  This incident will be reported.oshirowanen@debian:~$ Why is this happening?This is what I get from visudo## This file MUST be edited with the 'visudo' command as root.## Please consider adding local content in /etc/sudoers.d/ instead of# directly modifying this file.## See the man page for details on how to write a sudoers file.#Defaults        env_resetDefaults        mail_badpassDefaults        secure_path=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin# Host alias specification# User alias specification# Cmnd alias specification# User privilege specificationroot    ALL=(ALL:ALL) ALL# Allow members of group sudo to execute any command%sudo   ALL=(ALL:ALL) ALL# See sudoers(5) for more information on #include directives:#includedir /etc/sudoers.d
How to add self to sudoers list?
linux;sudo;debian
You need to log in again after adding yourself to a group to get the correct privileges.To verify with two shells:alice $ sudo adduser test                                alice $ su - testalice $ sudo adduser test sudo                                test $ sudo ls                                test is not in the sudoers file.  [...]                                test $ exit                                alice $ su - test                                test $ sudo ls                                examples.desktopTo clarify, any shells which were opened before the user was added to the sudo group do not have the new privileges.