setup sudo | zuhdi.org

Setup sudo

Environment

  • Debian 9.7 x64

Excerpt https://wiki.debian.org/sudo

Log 2019 / 05

root@athos:~# apt-get update && apt-get -y upgrade && apt-get -y dist-upgrade

root@athos:~# dpkg -l | grep sudo
ii  sudo   1.8.19p1-2.1   amd64   Provide limited super user privileges to specific users

root@athos:~# adduser zuhdi
Adding user `zuhdi' ...
sent invalidate(passwd) request, exiting
sent invalidate(group) request, exiting
Adding new group `zuhdi' (1001) ...
sent invalidate(passwd) request, exiting
sent invalidate(group) request, exiting
sent invalidate(group) request, exiting
sent invalidate(passwd) request, exiting
sent invalidate(group) request, exiting
Adding new user `zuhdi' (1001) with group `zuhdi' ...
sent invalidate(passwd) request, exiting
sent invalidate(group) request, exiting
sent invalidate(passwd) request, exiting
sent invalidate(group) request, exiting
sent invalidate(passwd) request, exiting
sent invalidate(group) request, exiting
Creating home directory `/home/zuhdi' ...
Copying files from `/etc/skel' ...
Enter new UNIX password:
Retype new UNIX password:
passwd: password updated successfully
Changing the user information for zuhdi
Enter the new value, or press ENTER for the default
        Full Name []:
        Room Number []:
        Work Phone []:
        Home Phone []:
        Other []:
sent invalidate(passwd) request, exiting
sent invalidate(group) request, exiting
sent invalidate(passwd) request, exiting
Is the information correct? [Y/n]

root@athos:~# grep sudo /etc/group
sudo:x:27:

root@athos:~# usermod -aG sudo zuhdi
sent invalidate(passwd) request, exiting
sent invalidate(group) request, exiting
sent invalidate(passwd) request, exiting
sent invalidate(group) request, exiting

root@athos:~# id zuhdi
uid=1001(zuhdi) gid=1001(zuhdi) groups=1001(zuhdi),27(sudo)

Hugo. Malte Kiefer & Zuhdi Najib.