1

I mean,

if there's a user with username:name

how to make him a sudo user without adding him to wheel group(intention is if wheel group is deleted)?

2

Add that user directly to /etc/sudoers or add a group to sudoers that the user is also in. Most distros use the commend visudo to edit this file.

  • ## Allow root to run any commands anywhere root ALL=(ALL) ALL – Vamsee Bond Oct 17 '17 at 7:52
  • We can add a new user below this line. – Vamsee Bond Oct 17 '17 at 7:52
1

Run: visudo

Add that user, preferably at the bottom of the file under your own comment like:

#Admins
username    ALL=(ALL) ALL

or I like create an admin group like this:

User_Alias ROOTUSERS = jpratt

ROOTUSERS ALL=(ALL) ALL

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.