Skip to end of metadata
Go to start of metadata

When you first receive your SmartMachine, you will need to change a few default passwords. The following is how to change them through the command line.  

If you intend to use Virtualmin to manage hosting for your SmartMachine, a good practice is to use the Virtualmin controls for password changing. This way, Virtualmin knows the passwords for your users and can use them as it goes. Otherwise, you may encounter a situation where a single user has a different password for system login, and for MySQL or SVN. This only applies to users created through Virtualmin (not the "root" or "admin" user).

In this topic:

At a Glance

This topic shows you how to change SmartMachine passwords, how to update.

Please note, once you change any passwords, those will not update your machine credentials in your "my.joyentcloud.com" portal.

Changing Passwords

You should change passwords on older cloud SmartMachines. If you use "my.joyentcloud.com" for your SmartMachines, the admin and root system accounts are secured with their system passwords locked. You can use this process to set the system passwords if you need to on a new Joyent cloud SmartMachine.

Admin User

  1. Log into your SmartMachine over ssh.
  2. Run this command: 

    You will need to enter your current password that is supplied by Joyent and your new password.

Root User

  1. Log into your SmartMachine as the admin user
  2. Run this command:

    You will only need to enter your new password.

MySQL Root User

  1. Log into MySQL:

    The system will prompt you for your MySQL password that is supplied by Joyent. 

  2. Once at the MySQL prompt, run this command:

    MySQL should return something like this:


  3. Enter quit to exit.
    Warning!
    After exiting the MySQL command line interface, you should edit your .mysql_history file to remove the entry that shows your password.


    Keep in mind
    If you use webmin you also need to update the password there as well either through the webmin interface or editing /etc/webmin/mysql/config

Webmin User

To change a Webmin user password through the command line, run this command:

sudo /opt/webmin/changepass.pl /etc/webmin admin yournewpassword


Keep in mind
The path to changepass.pl may change as the version of webmin increases. In the example above its version 1.380.
Warning!
After logging out and back in, you should edit your .bash_history file to remove the entry that shows your password.

Disabling Password Authentication

If you prefer public key authentication and want to disable password authentication, do the following:

  1. Open the SSH daemon configuration file by running this command:


  2. Set both of these values to no 
    • PasswordAuthentication
    • PAMAuthenticationViaKBDInt
Labels:
mysql mysql Delete
webmin webmin Delete
virtualmin virtualmin Delete
root root Delete
admin admin Delete
smartmachine smartmachine Delete
postgresql postgresql Delete
passwords passwords Delete
modules modules Delete
ssh ssh Delete
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.