postgresql - Postgres - Homebrew Install Cannot Find Server Files Multiple Versions -
i trying use postgres
on machine , realized time ago had installed database software after running brew install postgres
, receiving error: postgresql-9.4.5_2 installed
. there decided install homebrew/services
able run postgres in background , launched , closed background job
brew services start postgresql==> started
postgresql(label: homebrew.mxcl.postgresql)
however, when run postgres
received error of:
postgres not know find server configuration file. must specify --config-file or -d invocation option or set pgdata environment variable.
when followed answer on so, cat /usr/local/var/postgres/server.log
received following error:
log: skipping missing configuration file "/usr/local/var/postgres/postgresql.auto.conf" fatal: database files incompatible server detail: data directory initialized postgresql version 9.3, not compatible version 9.4.5.
which makes me think had older version of postgresql installed needs removed.
i tried psql
, received:
psql: not connect server: no such file or directory server running locally , accepting connections on unix domain socket "/tmp/.s.pgsql.5432"?
and decided init new db initdb /usr/local/var/postgres
, didn't fix it, resulted in following original message , setting env varible: export pgdata=/usr/local/var/postgres
. after trying postgres
again, receive
log: skipping missing configuration file "/usr/local/var/postgres/postgresql.auto.conf" fatal: database files incompatible server detail: data directory initialized postgresql version 9.3, not compatible version 9.4.5.
what tells me there version compatibility issue, needs resolved in order launch postgres server, i'm not sure file paths need cleared or proper way clear them. can provide guidance?
Comments
Post a Comment