在Mac OS X 10.8.4上的PostgreSQL有点问题.当postgres服务器运行时,我不小心做了brew rm postgresql --force.当我使用brew install postgresql安装并运行pg_ctl -D /usr/local/var/postgres start时,我得到:
Having a bit of an issue with PostgreSQL on Mac OS X 10.8.4. I accidentally did brew rm postgresql --force while the postgres server was running. When I installed using brew install postgresql and ran pg_ctl -D /usr/local/var/postgres start I get:
pg_ctl: another server might be running; trying to start server anyway server starting FATAL: lock file "postmaster.pid" already exists HINT: Is another postmaster (PID 752) running in data directory "/usr/local/var/postgres"?当我运行"ps -ef | grep postgres"时,我得到:
when I run "ps -ef | grep postgres" I get:
501 752 235 0 12:42PM ?? 0:00.01 /usr/local/opt/postgresql/bin/postgres -D /usr/local/var/postgres -r /usr/local/var/postgres/server.log 501 754 752 0 12:42PM ?? 0:00.00 postgres: checkpointer process 501 755 752 0 12:42PM ?? 0:00.34 postgres: writer process 501 756 752 0 12:42PM ?? 0:00.02 postgres: wal writer process 501 757 752 0 12:42PM ?? 0:00.01 postgres: autovacuum launcher process 501 758 752 0 12:42PM ?? 0:00.01 postgres: stats collector process 501 945 452 0 12:58PM ttys000 0:00.00 grep postgres当我尝试使用pg_ctl stop -D /usr/local/var/postgres -m fast或pg_ctl -D /usr/local/var/postgres stop -mi停止服务器时,我得到:
when I try to stop the server with pg_ctl stop -D /usr/local/var/postgres -m fast or pg_ctl -D /usr/local/var/postgres stop -mi I get:
waiting for server to shut down........................................... Failed pg_ctl: server does not shut down编辑
which pg_ctl /usr/local/bin/pg_ctl pg_ctl --version pg_ctl (PostgreSQL) 9.2.4server.log的要旨: gist.github/anonymous/6106182
推荐答案原来需要在〜/Library/LaunchAgents/处卸载和删除我的postgres的brew.plist.重新启动后一切都很好...关闭的问题.
turns out that my brew.plist for postgres needed to be unloaded and removed at ~/Library/LaunchAgents/ . After a restart all is well... closing question.
更多推荐
PostgreSQL服务器不会停止
发布评论