PostgreSQL - is the server running locally and accepting connections on unix domain socket /tmp/.s.pgsql.5432
rm /usr/local/var/postgres/postmaster.pid
PostgreSQL - is the server running locally and accepting connections on unix domain socket /tmp/.s.pgsql.5432
rm /usr/local/var/postgres/postmaster.pid
could not connect to server: Connection refused Is the server running on host "localhost" (::1) and accepting TCP/IP connections on port 5432
// In my case PostgreSQL updates from version 13.4 to 14 in background, so it fixes by:
brew postgresql-upgrade-database
// In other case the problem fixed by:
rm -rf /usr/local/var/postgres/postmaster.pid
// Restart service postgresql:
brew services restart postgresql
// How can you understand what is the problem?
// For first see what service is not correct started:
brew services list
// For second show file postgres.log, where will be the error:
tail -f /usr/local/var/log/postgres.log
// And so find answer by this error's text
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us