3
ExecStart=/usr/pgsql-9.4/bin/pg_ctl start -D ${PGDATA} -s -w -t 300 (code=exited, status=1/FAILURE)

This error appears after changes in

/var/lib/pgsql/9.4/data/postgresql.conf or pg_hba.conf

And even I return the original conf file the error stays.

Questions: 1) What this error means? 2) How can I solve it?

I try all methods which describes in forums, but nothing

Full error:

systemctl status postgresql-9.4.service -l
postgresql-9.4.service - PostgreSQL 9.4 database server
Loaded: loaded (/usr/lib/systemd/system/postgresql-9.4.service; enabled)
Active: failed (Result: exit-code) since Mon 2014-12-22 11:53:14 EST; 6s ago
Process: 1934 ExecStart=/usr/pgsql-9.4/bin/pg_ctl start -D ${PGDATA} -s -w -t 300 (code=exited, status=1/FAILURE)
Process: 1929 ExecStartPre=/usr/pgsql-9.4/bin/postgresql94-check-db-dir ${PGDATA} (code=exited, status=0/SUCCESS)
4
  • You haven't posted an error! Dec 22, 2014 at 17:38
  • @MichaelHampton I posted! xecStart=/usr/pgsql-9.4/bin/pg_ctl start -D ${PGDATA} -s -w -t 300 (code=exited, status=1/FAILURE)
    – alizade
    Dec 22, 2014 at 17:57
  • 2
    That is not an error. Post the actual error messages. You may have to look in log files. Dec 22, 2014 at 18:10
  • Check the PostgreSQL log files. Probably in /var/lib/pgsql/9.4/data/pg_log or /var/log/postgresql/ or /var/log/pgsql . Dec 23, 2014 at 23:21

2 Answers 2

0

I had this issue when upgrading to 9.4 from 9.3 - I choose to remove the old 9.3 main cluster, but didn't create a new one at that time. This then prevented the main postgres process from starting.

Postgres Release Notes says a dump/restore is necessary, so depending on your system, you should run pg_upgradecluster or similar, or just create a new cluster with pg_createcluster (these commands are for debian systems - you didn't specify your OS).

0

I got the same error after I changed my pg_hba.conf. Luckily the answer was in /var/lib/pgsql/9.4/data/pg_log directory.

In my case I made context mistake (I added):

# TYPE  DATABASE        USER            ADDRESS                 METHOD
host    all     127.0.0.1/32    trust

The line suppose to looks like:

host    all all 127.0.0.1/32    trust

Not the answer you're looking for? Browse other questions tagged .