Error “ Job For Postgresql.service failed ” On Redhat/CentOs 7

0
26
views

If you face this issue on your server means you need to check the status of your database server and logs to resolve this issue asap.

Check out Installation of PostgreSql 9.5 Database Server On Redhat/CentOS 7

In My Case, I found I did not initialize the database that is why I got this error postgresql.service is failed.

So to solve this, You need to initialize the postgresql server first then start the service.

Step 1 : To initialize the database command is

Postgresql-setup  initdb                                                               # postgresql Version 9.x

Another Command is

service postgresql initdb                                                             # Redhat Version 6.x

Step 2 : Now try to start postgresql server

Systemctl start postgresql

You’re done.

LEAVE A REPLY

Please enter your comment!
Please enter your name here