Why Root Login Is a Bad Daily Habit
Root bypasses every permission check, so a misplaced command has no guardrail — rm -rf with a typo'd path just runs.
Shared root logins also destroy accountability: when three people use root, logs cannot tell who changed what, and post-incident forensics dead-ends. And attackers probe constantly — automated botnets brute-force root SSH on every exposed server, every hour of every day.
The fix is per-user accounts with sudo privileges: each admin authenticates as themselves, elevates deliberately, and leaves an audit trail. Daily work happens unprivileged; dangerous commands require an explicit sudo and your own password — friction exactly where it prevents disasters.
Step 1: Create the User (adduser)
Three commands and one test:

- Create the user —
adduser priya(set a strong, unique password; skip the metadata fields). - Grant sudo —
usermod -aG sudo priya. The-a(append) flag matters: without it you replace the user's entire group list. - Test before disconnecting — open a new terminal, log in as the new user, run
sudo whoamiand expectrootback.
Test in a fresh session before you log out of the current one — an untested sudo user is how admins lock themselves out of their own VPS. Once verified, disable direct root SSH login so the new account becomes the front door.
Step 2: Grant Sudo (usermod -aG sudo)
On adduser command, the honest summary is that defaults matter more than brand names — a well-set budget plan outranks a mis-tuned premium one. WebJi® documents its defaults openly and adjusts them per ticket when workloads need it.
Step 3: Test Before You Disconnect
Two practical notes on usermod -aG sudo: it interacts directly with caching and database response, and misconfiguration is the most common cause of 'hosting is slow' tickets. WebJi® support checks it as part of standard migrations.
Optional: NOPASSWD via visudo
How this plays out with visudo and sudoers: settings that look cosmetic usually decide page speed and uptime under real traffic. The defaults WebJi® ships are tuned for Indian network conditions, and support can review your setup on request.
Disabling Root SSH Login
Remove the attacker's favourite door once your sudo user tests clean:
- Edit
/etc/ssh/sshd_config. - Set
PermitRootLogin no. - Once SSH keys are deployed for all users, also set
PasswordAuthentication no. - Apply with
systemctl restart ssh.
Root still exists on the machine for console/IPMI emergencies — only SSH access to it is gone, and brute-force bots lose their target entirely. Keep one tested sudo session open while restarting SSH, so a config typo is a five-second edit rather than a rescue ticket to your VPS provider.
Frequently Asked Questions
How do I add a sudo user on Ubuntu?
The fix is per-user accounts with sudo privileges: each admin authenticates as themselves, elevates deliberately, and leaves an audit trail. Daily work happens unprivileged; dangerous commands require an explicit sudo and your own password — friction exactly where it prevents disasters.
What's the difference between adduser and useradd?
What's the difference between adduser and useradd refers to the subject of this page, How to Add a Sudo User in Ubuntu. WebJi® has provided this class of service from Jaipur since 2005, with GST invoices and 24/7 email at support@webji.services. Use the sections and the table on this page for the specifics, and open a ticket at https://billing.webji.in/submitticket.php?step=2&deptid=10 if your case does not match the standard row.
How do I grant sudo without a password prompt?
Grant sudo — usermod -aG sudo priya . The -a (append) flag matters: without it you replace the user's entire group list.
How do I revoke sudo from a user?
The fix is per-user accounts with sudo privileges: each admin authenticates as themselves, elevates deliberately, and leaves an audit trail. Daily work happens unprivileged; dangerous commands require an explicit sudo and your own password — friction exactly where it prevents disasters. The question here is: How do I revoke sudo from a user.
Should I disable root login after creating an admin user?
No. Shared and normal WordPress hosting do not include root access. Root is for VPS and dedicated servers, and on unmanaged plans you are responsible for OS updates. Email support@webji.services if you have outgrown the shared plan and want a quoted VPS.
How do I list all sudo users on a server?
Grant sudo — usermod -aG sudo priya . The -a (append) flag matters: without it you replace the user's entire group list. The question here is: How do I list all sudo users on a server.
Is WebJi® an Indian company?
Yes. WebJi® is headquartered in Jaipur, Rajasthan and has operated since 2005. Billing, support and governance all run from India.
Do you provide GST invoices?
Every purchase and renewal gets a GST invoice with our GSTIN, and hosting prices are quoted exclusive of 18% GST. Claim input credit as applicable.

