Difference between revisions of "Postgresql"
From John Freier
(→Issues) |
|||
Line 26: | Line 26: | ||
location of file: ./data/pg_hba.conf | location of file: ./data/pg_hba.conf | ||
− | Added the following line | + | Added the following line and then restarted Postgres. |
host all all 10.225.41.95/24 md5 | host all all 10.225.41.95/24 md5 |
Revision as of 13:45, 10 September 2019
Test Database Connection
This is a way to test the database connection.
./pg_isready -h localhost -p 5432
Application Structure
Log location
./data/log/
OSX
The Postgres app live here on OSX
/Library/PostgreSQL/11
Start
sudo -u postgres ./bin/pg_ctl -D ./data start
Stop
sudo -u postgres ./bin/pg_ctl -D ./data stop
FYI, haven't tried but look like a nicer app to control Postgres is https://postgresapp.com.
Issues
Error Connecting to database FATAL : no pg_hba.conf entry for host I had to add the host ip address into the pg_hba.conf file.
location of file: ./data/pg_hba.conf
Added the following line and then restarted Postgres.
host all all 10.225.41.95/24 md5