Using sudo to Assign the Root Access of a User on a Linux


A Linux server is a server which is built on the Linux open-source operating system. It provides the businesses a low-cost option for the content, apps, and services delivered to the users. As Linux is an open source, users are also get benefited from the huge community of resources. Linux servers have a graphical desktop environment and also the applications that run on it. There are few networking applications for Linux like traffic analysis, security and the network management, that even have graphical interfaces. However, they are less in number than those for desktops and servers



Steps to assign the root access to a user on a Linux Server by using sudo:


Step-1: Login to the server as a root.


Step 2: Run the below-mentioned command :

root@host [~]# visudo


Step-3: The screen which is been displayed will the sudoers file in the vi editor. You need to include the below-mentioned line into the file to assign the entire root privileges to an account:

abcdef ALL=(ALL) ALL


Step-4: If you are not interested to provide the entire access but need to run a few lists of commands, you need to create a command alias in your sudoers file, as mentioned below:

User_Alias ADMINS = abcdef

Cmnd_Alias HTTPD = /etc/init.d/httpd



Now, you must be able to create a group of users whom you'll be able to assign command aliases to. You need to only make sure that the users are being separated with the help of (,) comma. The Cmnd_Alias will show you an inventory of various commands which the users of a few Alias will run. You can later select the user alias and assign the command alias. Later you will be asked to enter the password each and every time the sudo is running. If you do not need the system to ask for the password each and every time you can replace by mentioning the below command:



In the last line with the following below mention command :



If you need more information related to assigning the Root Access of a User on a Linux Server using the sudo you can contact our support team via live chat, phone, email, ticket system or toll-free no 1800-123-8642


If you are looking for complete root access to your server you can choose our best in class VPS server at an affordable price, where you also get complete root access to the server and with the help of that you can easily install, run, delete and edit any files, data, software etc.