3
最近升级到Mountain Lion之后,我遇到了使用我的brewgres安装的问题。OSX 10.8升级后postgres无法连接服务器
$ rake db:create
>rake db:migratecould not connect to server: Connection refused
> Is the server running on host "localhost" (::1) and accepting
> TCP/IP connections on port 5432?
>could not connect to server: Connection refused
> Is the server running on host "localhost" (fe80::1) and accepting
> TCP/IP connections on port 5432?
>could not connect to server: Connection refused
> Is the server running on host "localhost" (127.0.0.1) and accepting
> TCP/IP connections on port 5432?
在搜索周围的interwebs之后,我还没有找到解决此问题的方法。
我发现了一个建议的步骤来帮助识别问题,但在遵循这些步骤之后,我不确定如何理解结果或接下来要做什么。谁能帮忙?
$ pg_ctl -D /usr/local/var/postgres -l /usr/local/var/postgres/server.log start
>pg_ctl: another server might be running; trying to start server anyway
>server starting
$ pg_ctl -D /usr/local/var/postgres stop -s -m fast
>pg_ctl: could not send stop signal (PID: 865): No such process
$ pg_ctl status
>pg_ctl: no server running
$ ps auxw | grep post
>myuser 19037 2.6 7.7 4388248 324520 ?? S 7:30AM 19:06.02 /Applications/Postbox.app/Contents/MacOS/postbox-bin -psn_0_917728
>myuser 54897 0.1 0.0 2432768 464 s000 R+ 1:47PM 0:00.01 grep post
$ cat /usr/local/var/postgres/server.log
>FATAL: lock file "postmaster.pid" already exists
>HINT: Is another postmaster (PID 821) running in data directory "/usr/local/var/postgres"?
欢迎提供任何可能有用的附加信息。
也许这将帮助:https://gist.github.com/1877457让我知道。 –
好的,这可能是有希望的。杀怪奇怪返回失败:没有这样的过程。停止也返回不能发送停止信号(PID:xxx):没有这样的过程。最后的选项给FATAL:数据目录“/ usr/local/var/postgres”具有错误的所有权,我怀疑这可能很重要,但我不知道这应该如何表现。感谢任何建议 –