A sudo user lets you manage a Linux VPS without logging in as root for every task. This is safer for daily administration and makes it easier to track who has access.
Connect to the VPS as root first, then replace username with the user you want to create.
adduser username usermod -aG sudo username
On AlmaLinux, Rocky Linux, or Oracle Linux, use the wheel group instead:
adduser username passwd username usermod -aG wheel username
Open a new SSH session and test:
ssh username@your.vps.ip sudo whoami
If the command returns root, sudo is working. Keep the root login available until you have confirmed the new user can log in and run sudo commands.
