
Be sure to change the username with the actual user which you want to add to the wheel group.ġ. Note : On CentOS, by default, the members of the wheel group have sudo privileges. Use the usermod command to add the user to the wheel group. To create a group, use the groupadd command.ġ. Note : Set and confirm the new user's password at the prompt.ġ. Use the passwd command to update the new user's password. Note – Be sure to replace the username with the user you want to create.ģ. # ssh Use the adduser command to add a new user to your system. We will cover steps on creating user accounts, assigning 'sudo' privileges, and creating a group on a CentOS 7 server. While granting additional accounts, you can maintain administrative capabilities when necessary by utilizing a "sudo." Sudo allows authorized users to temporarily acquire administrative privileges, providing a more controlled and secure approach to server management. This practice enables better monitoring and management of individual activities.

Creating unprivileged user accounts for performing everyday tasks is recommended to mitigate this risk.įurthermore, it is essential to establish separate accounts for each user who requires access to your server. Any command executed under the root account can potentially impact the entire file system of the server. The main concern with using the root account is its increased vulnerability to security exploits. However, relying solely on the root account poses security risks and is not advisable for regular use.


When setting up a new server, the default account is typically the root account, which grants extensive privileges and flexibility. As a result, one of the fundamental tasks in Linux system administration is adding or removing users, which can be achieved by configuring the system settings. Linux is an operating system designed to support multiple users simultaneously, making it a multi-user system.
#SUDO USER CENTOS HOW TO#
How to Create Users and Groups in CentOS 7?
