Tools

Migrate WHD with embedded PostgreSQL from Windows to SolarWinds WHD VA or to any Linux machine

How to Migrate WHD Embedded PostgreSQL Database to Linux OS.

First published date

10/19/2018 8:46 PM

Last published date

7/5/2019 5:58 PM

Overview

How to Migrate WHD Embedded PostgreSQL Database to Linux OS. How to access, open the Postgre database.  This contains the steps needed to move the embedded Postgres database in a Windows to a Linux Machine. You can also use the steps to back up the Database in a Linux machine so you can move it to a Windows server.

Product section

Web Help Desk

Resolution

To migrate WHD with embedded PostgreSQL from Windows to SolarWinds Web Help Desk VA or to any Linux machine:
 
  1. Connect to the VA/Linux machine via SSH as user admin.

    Note: The default password admin. If you have changed the password, use that instead.

  2. Once connected, change to the user root: sudo su -
  3. Stop the WHDservice: webhelpdesk stop
  4. Configure PostgreSQL to allow connection from all interfaces. Edit the postgresql.conf file.
    1. vi /usr/local/webhelpdesk/bin/pgsql/var/lib/pgsql/9.2/data/postgresql.conf
    2. Press A on your keyboard.
    3. Look for the line #listen_addresses = 'localhost' and change it to listen_addresses = '*'

      Note: The # has been removed to uncomment the line.

    4. Save the file by pressing SHIFT + Z + Z.
  5. Start PostgreSQL manually using the following command:
    /usr/local/webhelpdesk/bin/pgsql/etc/rc.d/init.d/postgresql-9.2 start
  6. Switch to PostgreSQL user:su - postgres
  7. In the WHD in Windows, go to Setup > General > Database.
  8. Click Backup Now.
  9. Stop WHD once the backup is done on the Windows machine.
  10. Browse to C:\Program Files\WebHelpDesk\pgsql9\bin and run pgAdmin3.
  11. In the pgAdmin III window, go to File > Add Server.
  12. Add the following:
    • Name: WHDDB
    • Host: [the VA/Linux machine's IP Address]
    • Port: 20293
    • Maintenance DB: postgres
    • Username: whd
    • Password: whd
  13. Expand Databases.
  14. Right-click whd, select Delete/Drop from the menu and click Yes.
  15. Create a new DB. Right-click Databases and select New Database.
  16. Set the following:
    • Name: whd
    • Owner: whd
  17. Right-click whd then select Restore.
  18. Search for the backup file of the PostgreSQL DB.
  19. Click Restore.
  20. Once the restore is done and successful, return to the SSH Window connected to the VA/Linux machine and press CTRL + C to stop PostgreSQL from running.
  21. Type exit to switch back to user root.
  22. Start Web Help Desk on the VA/Linux machineservice: webhelpdesk start