Skip to Content

Reset the PostgreSQL admin password on a Jitterbit private agent

Introduction

The private agent installation process sets up the following two PostgreSQL administrator user accounts:

  • postgres: The default admin user. You set the password for this account when you install the private agent.

  • jitterbit: An additional admin user created by the installation process. The password for this account is randomly generated at installation time, then written to the [DbInfo] section of the jitterbit.conf file.

Since both accounts have the same access rights, you can use the jitterbit account to connect to the database and change the postgres account's password if you lose or forget it.

Change the postgres admin user account password

To change the postgres admin user account password, follow these steps:

  1. Log into the private agent host.

  2. Find the randomly generated PostgreSQL password in the jitterbit.conf file:

    Windows PowerShell
    Select-String -Path 'C:\Program Files\Jitterbit Agent\jitterbit.conf' -Pattern "^Password"
    
    Linux terminal
    grep ^Password /opt/jitterbit/jitterbit.conf
    
  3. Copy the value of the Password key (excluding the leading and trailing single quotes).

  4. In a console, log into the database:

    cd "\Program Files\PostgreSQL\14\bin"
    .\psql --username=jitterbit --dbname=postgres
    
    export LD_LIBRARY_PATH="/opt/jitterbit/pgsql/lib"
    /opt/jitterbit/pgsql/bin/psql --username=jitterbit --dbname=postgres --port=6432
    

    When prompted, enter the password copied in the previous step.

  5. At the postgres=# prompt, change the password for the postgres admin user:

    ALTER USER postgres WITH PASSWORD '********';
    

    Replace ******** with a password meeting the PostgreSQL password restrictions and your organization's security policies.

  6. Exit the psql session:

    \q
    
  7. Restart the private agent.