How to change password on Ubuntu 22.04
Here, we have summed up all the required steps that will lead you to successfully change your password on Ubuntu 22.04. So, let’s start!
Step 1: OpenGrub Menu
If you wish to change your root account password, then you need to open the Grub menu on your Ubuntu 22.04. In order to do so, you need to first restart your system and then quickly press and hold the “Shift” key when the system is restarting:
Step 2: Edit Grub Menu
Now you need to change the default boot entry of the system and for that press the “E” button on the keyboard. This will allow you to make changes to the GRUB menu:
Once you are in the edit mode, bring your keyboard cursor to the line starting with the word “linux” using the arrow keys and write the following command at the end of that line:
Now boot the system with the new configuration using Ctrl+X, or F10.
Step 3: Check Access
After performing the above step, you will be given root access. Now ensure that you have read and write access to the file system where Ubuntu 22.04 is installed. To evaluate this, run this command:
If you see the above-given output, then it means you have read and write access.
Step 4: Change Password
Now run the following command to change the password on your Ubuntu 22.04 system and enter the new password:
However, if you wish to change the password for another user account rather than the root account, then utilize the command and specify the “username” in it:
Step 5: Reboot system
Now reboot the Ubuntu 22.04 system using the below-mentioned command and press Enter to log in with the new password:
That was all about changing the password on Ubuntu 22.04. Give it a try on your system.
In order to change the password on Ubuntu 22.04, you need to open the Grub menu and edit this menu by pressing the “E” key. Once in the edit mode, make the specified configurations. After saving them, evaluate whether you have read and write access to the file system or not and change your password using the system password with the “passwd” command and reboot the system to log in with the new password. This post discussed the method to change passwords on Ubuntu 22.04 system.