【发布时间】:2014-09-25 00:58:25
【问题描述】:
我根据ps aux | grep postgres 运行了以下进程
postgres 8720 0.0 0.0 2492848 5652 ??下午 2 点 33 分
0:00.04 /System/Library/Frameworks/CoreServices.framework/Frameworks/Metadata.framework/Versions/A/Support/mdworker -s mdworker -c MDSImporterWorker -m com.apple.mdworker.shared postgres 495 0.0 0.0 2514428 1776 ??下午 1:57 0:00.07 /System/Library/Frameworks/CoreServices.framework/Frameworks/Metadata.framework/Versions/A/Support/mdflagwriter postgres 491 0.0 1.0 2669764 166180 ??下午 1 点 57 分
0:10.31 com.apple.IconServicesAgent postgres 490 0.0 0.0 2505832 2884 ?? Ss 1:57PM 0:00.07 /usr/libexec/xpcd postgres 485 0.0 0.0 2514284 1284 ??下午 1:57 0:00.07 /usr/sbin/cfprefsd 代理 postgres 484 0.0 0.0 2536788
1708 ?? S 1:57PM 0:00.06 /usr/sbin/distnoted 代理 postgres
479 0.0 0.0 2508256 1100 ??下午 1:57 下午 0:00.06 /sbin/launchd postgres 427 0.0 0.0 2493792 608 ?? Ss 1:55PM 0:00.02 postgres:统计收集器进程 postgres 426 0.0 0.0 2654624 2208 ?? Ss 1:55PM 0:00.02 autovacuum 启动器进程 postgres 425 0.0 0.0 2646300 764 ?? Ss 1:55PM 0:00.03 postgres: wal 作家 处理 postgres 424 0.0 0.0 2638108 1608 ??不锈钢 下午 1:55 0:00.07 postgres:编写器进程 postgres 423
0.0 0.0 2638108 836 ?? Ss 1:55PM 0:00.00 postgres:检查点进程 postgres 419 0.0 0.0 2493792
500?? Ss 1:55PM 0:00.00 postgres:记录器进程 postgres 85 0.0 0.1 2638108 13844 ??下午 1:55 下午 0:00.04 /Library/PostgreSQL/9.3/bin/postmaster -D/Library/PostgreSQL/9.3/data 用户名 8910 0.0 0.0 2432784 612 s003 R+ 2:35PM
0:00.00 grep postgres
我要他们死!
但是 killall postgres 给了我:
No matching processes belonging to you were found
我知道我需要使用:
kill -INT `head -1 /usr/local/pgsql/data/postmaster.pid`
但我不明白这个命令。
感谢您的指导。漫长的令人沮丧的早晨!
【问题讨论】:
-
您是否尝试过
kill -9 8720(其中8720是PID)?请注意,这可能会导致数据丢失,因为操作系统会以非常不友好的方式终止进程。 -
酷。我会发布更详细的答案。
-
@CmdrMoozy 现在它不起作用了。太奇怪了。
-
我在我的答案中添加了一些额外的注释,这可能解释了为什么它有时不起作用。看看他们是否有帮助。
标签: postgresql