[Linux] Change the password of non-root account

  1. Log in to the server with the root account (or an account with sudo permissions)
  2. Use commands passwd + 想要修改的用户名, for example: passwd recordyou will be prompted to enter a new password
  3. After entering the new password, you will be prompted to enter it again and then just remember it.
  4. Seeing passwd: all authentication tokens updated successfullymeans that the modification was successful

Notice:

  1. Changing the password does not require restarting the server.
  2. You need to have sudo permissions, otherwise you will be prompted for insufficient permissions.
  3. The username can /etc/shadowbe found below, as well as the encrypted password, but it is one-way encrypted.

Guess you like

Origin blog.csdn.net/qq_38486203/article/details/130655075