[pgsql-jp: 36960] VACCUM の動作について

y-sugita @ cnt.mpd.nec.co.jp y-sugita @ cnt.mpd.nec.co.jp
2006年 4月 5日 (水) 17:57:35 JST


杉田と申します。

postgereSQL7.4のバキューム処理についてご教授ください

日次でVACUUM処理を実行しており、通常2分程度で終わるVACUUMが
6時間経過しても終わりませんでした。
(今回はVACUUM処理のプロセスを中断させました。)

※前日から流れているSQL(下記PSコマンドの結果)が影響をしているのでしょうか?

Q1. どのような時にこのような状態になるのでしょうか?
Q2. 調査方法、対処方法を教えていただけますでしょうか。

以上、よろしくお願いいたします。

環境:postgres7.4

□参考にバキュームの所要時間は以下のとおりです。
4/2 4:03 〜 4:05
4/3 4:03 〜 4:05
4/4 4:03 〜 4:05
4/5 4:03 〜 10:14 (強制終了)

□Webアプリが固まったときのpsコマンド結果
# ps -ef|grep post
postgres 15557     1  0 Mar17 ?        00:08:35 /usr/local/pgsql/bin/postmaster -D /usr/local/pgsql/data
postgres 15562 15557  0 Mar17 ?        00:00:59 postgres: stats buffer process
postgres 15563 15562  0 Mar17 ?        00:03:47 postgres: stats collector process
postgres 22338 15557 57 Apr04 ?        12:44:02 postgres: postgres mail 192.168.227.21 SELECT
postgres 22753 15557 57 Apr04 ?        12:34:12 postgres: postgres mail 192.168.227.21 SELECT
postgres 23072 15557 57 Apr04 ?        12:31:50 postgres: postgres mail 192.168.227.21 SELECT
postgres  7871  6855  0 04:03 ?        00:00:00 /bin/bash /crmhome/bs/shell/CRMS_VACM0010.sh mail
postgres  7940  7871  0 04:03 ?        00:00:00 /usr/local/pgsql/bin/vacuumdb -z -f -d postdb
postgres  7941 15557  0 04:03 ?        00:00:00 postgres: postgres mail [local] VACUUM waiting
postgres  8006 15557  0 04:09 ?        00:00:00 postgres: postgres mail 192.168.227.21 SELECT waiting
postgres  8094 15557  0 04:20 ?        00:00:00 postgres: postgres mail 192.168.227.21 SELECT waiting
postgres  8260 15557  0 04:39 ?        00:00:00 postgres: postgres mail 192.168.227.21 SELECT waiting
postgres  8430 15557  0 05:00 ?        00:00:00 postgres: postgres mail 192.168.227.21 SELECT waiting



pgsql-jp メーリングリストの案内