0

Well I am trying for hours to install and configure postgres in ubuntu but getting below error:

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 have tried almost every solution I found but still no success.

Below are the commands I have used to install postgres:

sudo apt update
sudo apt install postgresql postgresql-contrib

sudo -i -u postgres

psql (After this I got an error)

The error arises during the installation of postgres.Kindly give suggestions or resources through I which I can fix this!

Nabeel Ayub
  • 1,060
  • 3
  • 15
  • 35

0 Answers0