What to Know
- Open a terminal window, issue the command passwd, type your current password, and then type the new password twice.
- For someone else, enter sudo passwd username (use their username), type your password. Type the new password for the user twice.
With the Linux operating system, it's easy to change your user password. The easiest way to change your password is from a shell prompt. The steps below show you how to change your Linux user password and reset your Linux password.
How to Change Your Linux Password
How you change your password from the command line is accomplished with the passwd command. Don't let the idea of the command line scare you away, as it's incredibly simple. Here's how to use this command:
-
Open a terminal window.
-
Issue the command passwd.
-
When prompted, type your current user password.
-
Type the new password.
-
Verify the password by typing it a second time.
-
Close the terminal window.
The password change takes effect immediately.
Linux: Reset User Password
To change someone else's password, use the sudo command.
-
Open a terminal window.
-
Issue the command sudo passwd USERNAME (where USERNAME is the name of the user whose password you want to change).
-
Type your user password.
-
Type the new password for the other user.
-
Retype the new password.
-
Close the terminal.