Step 3: Change the root PasswordΒΆ

The default root password often comes in an email or is displayed in the configuration settings of your VPS provider. In other words, neither option is secure. Changing a password is simple!

Warning

Record your new password someplace safe. Losing your root password requires you to reset it using your VPS login panel.

  1. Choose a new password.

    • My favorite method is to choose a Fort Knox Password or CodeIgniter Encryption Key from RandomKeygen.

  2. Use command passwd [user].

    • Or, use passwd to change the password of the logged in user.

root@vps298933:~# passwd
Enter new UNIX password:
Retype new UNIX password:
passwd: password updated successfully
root@vps298933:~#