Linux Mint

How to Change Root Password in Linux Mint 21

In a Linux system, a person with root privileges would be able to work as an administrator. Most of the Linux tasks required root-level permission to further proceed. It is quite possible that most of the users working on the same system have root privileges which sometimes create security problems.

However, to avoid security attacks, it is necessary to change the root password regularly. Because resetting the password time to time helps you to get rid of these issues, even if your ex-team member finds your old password, they wouldn’t be able to access the system.

How to Change Root Password in Linux Mint 21

We have two most common ways to change root password on Linux Mint 21 system:

  1. Using sudo Permission
  2. Using root Permission
  3. Using GUI

1: Change root Password with sudo Permission

With sudo privileges, a user can easily modify the root password if forgotten or even set it for the first time. But keep in mind, you should know about the older password. Whenever you run the mentioned command, the system will ask you to type the sudo password; type it and hit enter:

$ sudo passwd root

In the next move, you will be asked to type the new root password for the Linux mint system:

Re-enter the new root password you have set above for confirmation:

Once both passwords match, you will get a message on terminal that you have successfully updated Linux Mint root password.

2: Change root Password with root Permission

For this method, you should have changed the root password of the Linux Mint system at least one time before. And, you must know the current sudo password to gain root privileges. So, execute the mentioned command and type the current root password of your Linux system:

$ su root

In the next command, execute the ‘passwd’ command to the terminal for further process. This will allow you to modify the root password:

$ passwd

Type the new password you want to set, and hit Enter:

Re-enter the password you have set above. You will receive a successfully updated message if the password is entered correctly:

3: Change root Password Using GUI

You can also change the root password through a graphical user interface if you don’t prefer the terminal.

What you need to do is, open the applications menu, move to the Administration icon and their select Users and Groups option:

Type the current root password and click to Authenticate button:

After authentication, you will see a user with their respective details like name and password. In the password category, click on the dotted hidden password to reset it:

Once you clicked, a dialogue box of Change Password will be appeared on the screen:

Type the new password of your choice in the New Password entry and re-write it on the Confirm Password tab. If your passwords match, then hit to Change button:

The root password of the Linux Mint 21 system has changed successfully.


Root password is the key to managing your whole Linux system as all administration tasks and queries are handled with root permission. Sometimes, it is necessary to change the root password after some time to avoid unnecessary usage and attacks.

Through this guide, we have learned how to change the root password on Linux Mint 21 system. We have done it using two different approaches, one approach leads to CLI which includes sudo and root permissions. And in the second approach, we used the GUI method.

About the author

Syeda Wardah Batool

I am a Software Engineer Graduate and Self Motivated Linux writer. I also love to read latest Linux books. Moreover, in my free time, i love to read books on Personal development.