Error installing Analytics-on-Premise when generating database for datastore

Document ID : KB000093195
Last Modified Date : 27/04/2018
Show Technical Document Details
Issue:
While installing Analytics-on-Premise datastore, after successfully installed Postgre SQL, user cannot create user and database for Postgres with provided setup.psql

Error messages:
C:\Program Files\PostgreSQL\9.4\bin>psql -h hostname -p 5433 -U postgres -v username="uc4analytic" -v password="'******'" -v db_name="uctpostgre" -f C:\automic\datastore\setup.psql
psql: FATAL: no pg_hba.conf entry for host "x.x.x.x", user "postgres", database "postgres", SSL off

 
Cause:
This is a general error with postgre where the PostgreSQL Client Authentication Configuration File(..\PostgreSQL\<version>\data\pg_hba.conf) does not contain corresponding entry
Resolution:
Solution is to add the following entry to the PostgreSQL Client Authentication Configuration File(..\PostgreSQL\<version>\data\pg_hba.conf):
 
# TYPE DATABASE USER ADDRESS METHOD
host all all 0.0.0.0/0 md5

(it will allows all connections from any hosts)
then restart your postgreSQL before continue with the process

Other workaround: The original setup only allows local connections, so another fix could be replacing your hostname.domain with the localhost or it's local name/ip (if Postgre was installed on the same local host)
Additional Information: