how to give a user full permission the same as root, and disable root!!

January 16, 2014 2.7k views
Hi, I have an issue with giving a user full permissions to control the server the same as root. I created a user and gave permissions, but when I turned the use of DNS off I got the user out of editing everything. I followed this tut here to create a user: now I'm locked out and can't use root as well as the user itself. even through the SFTP the user can't get in to edit any file. is there a method on how to add a user and give that user full permissions the same as root. I searched around the net, but the solutions are not really doing any of the job since they are messy to some level and not accurate. your comments are welcome!! Thanks,
4 Answers
I found similar question, but not quiet exact thing I was hoping for :

I want the user to have the same privileges as root...

any idea???
by Etel Sverdlov
This tutorial covers how to login with root, how to change the root password, how to create a new user, how to give the new user root privileges, how to change the port, and how to disable root login in. This tutorial is written for Ubuntu. When you first create your server, this tutorial explains the first steps you need to take. This tutorial is made for CentOS.
Thanks @Kamal for the answer.

I still need to add sudo in front of command line I type, but that's not bad.

The thing is that I can't do anything from the SFTP even after following the 4th step in the article provided... am I missing something here??
Which directories do you need to write to?
Have another answer? Share your knowledge.