//open terminal and run this command
passwd
//It will require you to add current password first then updated password
passwd userNameHere
sudo passwd userlogin
passwd $user
#To change password in linux
#Log in to the user and Type the following command.
passwd
#if you dont't have your root password => then don't use sudo command
# passwd <username>
Current password:
New password:
Retype new password:
passwd: password updated successfully
sudo passwd vivek
# Chpasswd command is very simple to use
[ root@myhost ~ ] # echo "tom:1234" | chpasswd
# Using the passwd command, you can also change the password in a batch like mode
[ root@myhost ~ ] # echo "1234" | passwd --stdin "tom"
Changing password for user tom.
passwd: All authentication tokens Updated successfully.