Tools

How to allow external connection to the PostgreSQL database in WHD

This article provides the information on how to allow external connection to the PostgreSQL database.

First published date

11/9/2026 6:16 PM

Last published date

11/9/2026 6:16 PM

Overview

This article provides the information on how to allow connection to the PostgreSQL database from an external application. PostgreSQL database is used in Web Help Desk and sometimes, the database server is located in a separate server.

Product section

Web Help Desk

Resolution

In the PostgreSQL database Server:

 

  1. Log in to the database server as an administrator.
  2.  Navigate to C:\Program Files\PostgreSQL\<version number>data.
  3. Back up the following files to a separate location:
    - postgresql.conf 
    - pg_hba.conf
  4.  Open the postgresql.conf file in a text editor (such as Notepad)
  5. In the connections and authentication section:
    a. uncomment listen_addresses and set the parameter to:  listen_addresses = '*'
    b. uncomment the port and set the parameter to:  port = 20293 or 5432

  6. Save your changes.
  7. Open the pg_hba file in a text editor.
  8. Locate the following lines: 
    # IPv4 local connections:
    host all all 127.0.0.1/32 password
  9. Add a line with your_ip. your_ip that represents the ip address from which you want to connect with pg Admin.
    For example,
    # IPv4 local connections:
    host all all 127.0.0.1/32 password
    host all whd your_IP/32 password

     

Note:  instead of password, you may also use md5 instead

  1. Save.
  2.  Stop WHD using the Start Menu options (right-click and select Run as Admin).
  3. Stop PostgreSQL service under services.msc.
  4. Start PostgreSQL service under services.msc.
  5. Start WHD using the Start Menu options (right-click and select Run as Admin).