setting up sudo account

I want to create a managed account with root powers and the ability to su as root if need be to manage the box without needing root. What is the correct way to do it?

Does this work?

/usr/sbin/adduser -u 0 -o -g 0 -G 0,1,2,3,4,6,10 -M admin

Answer

Following steps will do the needful:

  1. Create a user say PowerUser (/usr/sbin/adduser PowerUser)
  2. Add following line in /etc/sudoers file using visudo

    PowerUser ALL=(ALL) ALL

  3. Read answers of this question.

Attribution
Source : Link , Question Author : Nikki Wilson , Answer Author : Community

Leave a Comment