How do I change the Linux root password?

If you need to change the server’s root password:

  • Log in as root using PuTTY
  • At the root shell prompt (# pound sign), type passwd and hit ENTER
  • Follow the prompts to set your new password
  • When finished, type exit to exit the shell.