How To Add Users To Sudoers Group On Centos
First Login as root.
Let us create a dummy user first for this example.
Create Password For User
Create password for our dummyuser.
Add User To Wheels Group
usermod -aG wheel dummyuser
Adding User to the Sudoers File
To add user to sudoers file, we need to edit /etc/sudoers. Open the file using vi or vim.
Add following line at the end in above file...
dummyuser ALL=(ALL) ALL
That's it. Now open a new shell and login as dummyuser. For any system level (root) tasks, just add sudo to the beginning of command line.