nativeInstallersonarqube

Modify the default administrator password

Before running the commands shown on this page, you should load the Bitnami stack environment by executing the installdir/use_APPNAME script (Linux and MacOS) or by clicking the shortcut in the Start Menu under “Start -> Bitnami APPNAME Stack -> Application console” (Windows). On OS X VMs, the installation directory is /opt/bitnami and OS X VM users can click the “Open Terminal” button to run commands. Learn more about the Bitnami stack environment and about OS X VMs.

Change the default administrator password manually

You can manually change the administrator password from the command line by following these steps:

  • Log in to the server console.
  • Obtain your database credentials. Learn how to find database credentials.
  • Load the Bitnami SonarQube environment before connecting to your database server:

    • Linux and Mac OS X:

      $ sudo installdir/use_sonarqube
      
    • Windows:

      $ installdir/use_sonarqube
      

Once you have obtained the database credentials and loaded the environment, you should be able to connect to the PostgreSQL server in order to change the administrator password. To do so:

  • Access the database by executing the following command:

    $ psql --username=postgres bitnami_sonarqube
    

    You will be prompted for your current database password.

  • Execute the following command. It will change your application administrator password. Remember to replace NEW_PASSWORD with the password you wish to set as default.

    bitnami_sonarqube=# UPDATE users SET crypted_password=SHA1(CONCAT('--', salt, '--', 'NEW_PASSWORD', '--')) WHERE id='1';
    

Now, you should be able to access your application using the new password.

Change the default administrator password from the SonarQube dashboard

You can change the administrator password from the SonarQube dashboard by following these steps:

  • Log in to the SonarQube dashboard.
  • Under the “User Name” dropdown menu in the upper right corner, click on “My Account”.

    User account settings

  • Select the “Security” tab.

  • Enter your old password and enter your new password twice to confirm the change.

    Change the default administrator password

  • Click the “Change password” button.

Last modification July 4, 2019