Would like to share postgres error , which I happen to notice on psql (9.2). It is sort of weird and I was not able to initiate any database connections.
psql: could not connect to server: No such file or directory
Is the server running locally and accepting
connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"?
I happened to check database was down.
[root@sajidserver ~]# ps -ef|grep pg
root 4152 4238 0 12:43 pts/2 00:00:00 grep --color=auto pg
####
Fix:
####
[root@sajidserver ~]$ cd /u01/pgsql/data
[root@sajidserver ~]$ cp postmaster.pid postmaster.pid.bkp
[root@sajidserver ~]$ rm postmaster.pid
Sweet and cool to see DB is back up and running
[root@sajidserver ~]# ps -ef|grep pg
root 4152 4238 0 13:43 pts/2 00:00:00 grep --color=auto pg
postgres 21453 1 0 oct19 ? 00:01:00 postgres -D /u01/pgsql/data
No comments:
Post a Comment