I am running MacOS 10.14.1 (absolutely new to MacOS), I am unable to run psql command installed through brew, I get the following error, would love some help:
psql: could not connect to server: No such file or directory
Is the server running locally and accepting
connections on Unix domain socket "/tmp/.s.PGSQL.5432"?
Solutions I have tried
brew services startservice already runningbrew services stop postgresql, brew services start postgresqlstill same errorbrew remove postgres, brew install postgres, psqlstill same errorbrew unlink postgresql && brew link postgresqlstill same errorrm -f /usr/local/var/postgres/postmaster.pidmy/usr/local/var/does not contain apostgres/folder
One more thing to note, when I brew install postgres I get a warning:
Warning: The post-install step did not complete successfully
You can try again using `brew postinstall postgresql`
running brew postinstall postgresql gives the same warning.
Hopefully provided enough information to go by, happy to provide more.
brew update? That fixes a lot of issues when brew has some out of date modules.brew doctorwill also solve some issues. If no luck,brew configand paste the results so we can see what version you are running and status.brew updateandbrew doctor(would love to know what these do - feel free to drop a reference site) ... the output of mybrew configis below (I notice the last line beingXcode: N/AI remember reading something about this...