[postgresforest-users 77] Re: オンラインリカバリー後のTomcatの再起動について

アーカイブの一覧に戻る

nagat****@nttda***** nagat****@nttda*****
2007年 8月 24日 (金) 13:15:23 JST


長妻です。

オフラインリカバリを行う際には、Forestにアクセスするアプリケーション
(今回の場合ではTomcat)を停止する必要があります。

というのも、ユーザーアプリケーションからTomcatへのアクセスがなくとも、
Tomcatマシン上でForestが動き続けていますので、GSCへのアクセスが発生します。
そのため、オフラインリカバリーの最中にもGSCの書き換えが発生してしまい、
整合性が取れなくなるためです。


Yasunaga Kobari さんは書きました:
> 長妻様
> 
> ご連絡が遅れてすいません。
> 
> 正しくは、管理者ガイドに記載されている
> オフラインリカバリーの手順に従ってリカ
> バリーをおこないました。
> 
> Tomcatは起動したまま、上記リカバリーを
> 実施しました。
> 
> 記述にオンラインとあったのはオフラインの
> 誤りでした。
> 
> よろしく御願いいたします。
> 
> 小針
> 
> On Mon, 20 Aug 2007 18:22:10 +0900
> "Satoshi.Nagatsuma" <nagat****@nttda*****> wrote:
> 
>> 長妻です。
>>
>>> オフラインリカバリーの場合はどうでしょうか?
>>> 障害があったマシンのPostgresを停止し、環境を
>>> 整え、再起動後オンラインリカバリーを実施しま
>>> したが、その間Tomcatへのアクセスはないことが
>>> わかっていましたので、Tomcatは停止しないで
>>> オフラインリカバリーを実施しました。
>> オンライン・オフラインという言葉がいまいちわかりにくく
>> 全体として何を行ったのか、ちょっと状況がわかりませんでした。
>>
>> PostgreSQLは一旦停止し、再度起動したとあります。
>> その後、PostgreSQL間でdump/restoreを行ったということでしょうか?
>> それとも、その状態からリカバリーツールを使ってのリカバリーを
>> 行ったということでしょうか?
>>
>> よろしくお願いします。
>>
>> Yasunaga Kobari さんは書きました:
>>> 長妻様
>>>
>>> ご回答ありがとうございます。
>>>
>>> オフラインリカバリーの場合はどうでしょうか?
>>>
>>> 障害があったマシンのPostgresを停止し、環境を
>>> 整え、再起動後オンラインリカバリーを実施しま
>>> したが、その間Tomcatへのアクセスはないことが
>>> わかっていましたので、Tomcatは停止しないで
>>> オフラインリカバリーを実施しました。
>>>
>>> 障害が発生データベースマシンでPostgresを停止
>>> する時、-m fast のオプションを指定して止めま
>>> した。
>>>
>>> オフラインリカバリー後、Webサーバーでロード
>>> が上がり、原因を調べてみるとTomcatがCPU TIME
>>> を消費続けていました。Tomcatを再起動すること
>>> で、復旧しました。
>>>
>>> オフラインリカバリーした後、しばらくしてTomcat
>>> がCPU TIMEを消費し始めたときの、2台のデータ
>>> ベースサーバーのプロセス状況は以下のとおりです。
>>>
>>> よろしく御願いいたします。
>>>
>>> 障害が発生し、その後リカバリーした後のマシンでの状況
>>>  1905 pts/0    S      0:00 /usr/local/pgsql818p/bin/postmaster -D /usr/local/forest402/data -p 5432
>>>  1906 pts/0    S      0:00 postgres: logger process
>>>  1908 pts/0    S      0:00 postgres: writer process
>>>  1910 pts/0    S      0:00 postgres: stats buffer process
>>>  1911 pts/0    S      0:00 postgres: stats collector process
>>>  2476 pts/0    S      0:00 postgres: forest XXXXXXX 192.168.0.54(41511) idle
>>>  2477 pts/0    S      0:00 postgres: forest XXXXXXX 192.168.0.53(48000) idle
>>>  2479 pts/0    S      0:00 postgres: forest YYYYYYYY 192.168.0.52(34374) idle
>>>  2480 pts/0    S      0:00 postgres: forest XXXXXXX 192.168.0.52(49185) idle
>>>  2481 pts/0    S      0:00 postgres: forest XXXXXXX 192.168.0.52(41863) idle
>>>  2482 pts/0    S      0:00 postgres: forest XXXXXXX 192.168.0.56(59569) idle
>>>  2483 pts/0    S      0:00 postgres: forest YYYYYYYY 192.168.0.54(36061) idle
>>>  2486 pts/0    S      0:00 postgres: forest YYYYYYYY 192.168.0.51(36623) idle
>>>  2487 pts/0    S      0:00 postgres: forest YYYYYYYY 192.168.0.53(60727) idle
>>>  2488 pts/0    S      0:00 postgres: forest YYYYYYYY 192.168.0.55(38794) idle
>>>  2489 pts/0    S      0:00 postgres: forest YYYYYYYY 192.168.0.56(51545) idle
>>>  2490 pts/0    S      0:00 postgres: forest YYYYYYYY 192.168.0.52(55209) idle
>>>  2526 pts/0    S      0:00 postgres: forest XXXXXXX 192.168.0.53(35768) idle
>>>  2535 pts/0    S      0:00 postgres: forest XXXXXXX 192.168.0.51(35058) idle in transaction
>>>  2550 pts/0    S      0:00 postgres: forest XXXXXXX 192.168.0.51(45681) idle
>>>  2556 pts/0    S      0:00 postgres: forest YYYYYYYY 192.168.0.51(41826) idle
>>>
>>>
>>> 障害が出ていないマシンでの状況
>>> 28999 ?        S      6:54 /usr/local/pgsql818p/bin/postmaster -D /usr/local/forest402/data -p 5432
>>> 29000 ?        S      0:01 postgres: logger process
>>> 29002 ?        S      0:00 postgres: writer process
>>> 29003 ?        S      1:02 postgres: stats buffer process
>>> 29004 ?        S      0:39 postgres: stats collector process
>>> 23210 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.52(52163) idle
>>> 23213 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.52(39231) idle
>>> 23241 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.52(49481) idle
>>> 23244 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.52(56858) idle
>>> 23252 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.53(38527) idle
>>> 23255 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.53(56136) idle
>>> 23258 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.53(39003) idle
>>> 23271 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.55(55127) idle
>>> 23279 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.54(42053) idle
>>> 23286 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.54(36368) idle
>>> 23292 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.53(35579) idle
>>> 23296 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.53(42564) idle
>>> 23330 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.51(41332) idle
>>> 23333 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.51(60973) idle
>>> 23369 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.55(33089) idle
>>> 23385 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.55(42938) idle
>>> 23399 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.56(38935) idle
>>> 23402 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.56(38134) idle
>>> 23447 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.51(38893) idle
>>> 24074 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.53(55062) idle
>>> 24107 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.55(36038) idle
>>> 24166 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.51(54802) idle in transaction
>>> 24169 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.51(47318) idle
>>> 24578 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.52(52441) idle
>>> 24596 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.56(52908) idle
>>> 24599 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.56(37784) idle
>>> 24949 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.54(53008) idle
>>> 27944 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.53(56494) idle
>>> 27954 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.52(44121) idle
>>> 29119 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.55(60535) idle
>>> 29174 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.54(45758) idle
>>> 31056 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.51(39593) idle
>>> 11604 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.52(33256) idle
>>> 11665 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.54(37289) idle
>>> 11735 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.54(41302) idle
>>> 11738 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.54(51565) idle
>>> 11756 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.56(39547) idle
>>> 11769 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.56(35129) idle
>>> 14703 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.56(39817) idle
>>> 15167 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.51(48658) idle
>>> 18959 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.53(51832) idle
>>>   526 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.52(40755) idle
>>>  1867 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.54(38954) idle
>>>  1891 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.53(50797) idle
>>>  1903 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.52(43026) idle
>>>  1922 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.52(38831) idle
>>>  1930 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.52(46050) idle
>>>  1934 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.56(37612) idle
>>>  1942 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.54(36542) idle
>>>  1956 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.51(44950) idle
>>>  1984 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.53(60104) idle
>>>  1987 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.55(38163) idle
>>>  2009 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.56(51097) idle
>>>  2035 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.52(58673) idle
>>>  2617 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.53(42381) idle
>>>  2881 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.51(40424) idle in transaction
>>>  3072 ?        S      0:00 postgres: forest XXXXXXX 192.168.0.51(37641) idle
>>>  3189 ?        S      0:00 postgres: forest YYYYYYYY 192.168.0.51(49409) idle
>>>
>>> 小針
>>>
>>> On Thu, 16 Aug 2007 14:24:13 +0900
>>> "Satoshi.Nagatsuma" <nagat****@nttda*****> wrote:
>>>
>>>> 長妻です。
>>>>
>>>> Tomcatへのアクセスが遅くなりTimeOutするとのことですが、
>>>> 申し訳ありませんがこちらでの試験の限りでは再現しておりません。
>>>>
>>>> リカバリツールの設計上、そういった再起動等が必要ない
>>>> 作りにはなっているはずですが・・・。
>>>>
>>>> もし再現するようでしたら、その際の情報
>>>> (PostgreSQLのプロセスの状態など)を頂ければ
>>>> 何か対処等がわかるかもしれません。
>>>>
>>>>
>>>> Yasunaga Kobari さんは書きました:
>>>>> 小針です。
>>>>>
>>>>> お世話になります。
>>>>>
>>>>> オンラインリカバリー後のTomcatの再起動について質問が
>>>>> あります。
>>>>>
>>>>> 現在以下の環境で運用しています。
>>>>> ・Fedora 6
>>>>> ・Postgreforest 4.0.2 マシン2台でクラスタリング
>>>>> ・PostgreSQL 8.1.8 Timeoutパッチ
>>>>> ・Java SDK 1.5.0_11
>>>>> ・Tomcat 5.5.15
>>>>> ・Connection Pool / dbcp
>>>>> ・Apache 2.2.4
>>>>> ・mod_jk2
>>>>>
>>>>> 1台のデータベースマシンに障害が発生し、オンラインリカバリーを
>>>>> したのですが、オンラインリカバリーをしたあと、Webアクセスが非常
>>>>> に遅くなりTimeOutするようになりました。Tomcatを再起動したとろこ
>>>>> 正常に戻りましたが、原因がわかりません。オンラインリカバリーの
>>>>> 後は運用上かならずTomcatの再起動が伴うのでしょうか?
>>>>> ちなみに、障害時、1台での運用では問題なくアクセスできていました。
>>>>>
>>>>> 切り離しログは以下のとおりです。
>>>>> An I/O error occured while sending to the backend. | 08006  | SELECT * FROM chk_table LIMIT 1
>>>>>
>>>>> よろしく御願いいたします。
>>>>>
>>>> _______________________________________________
>>>> postgresforest-users mailing list
>>>> postg****@lists*****
>>>> http://lists.sourceforge.jp/mailman/listinfo/postgresforest-users
>> _______________________________________________
>> postgresforest-users mailing list
>> postg****@lists*****
>> http://lists.sourceforge.jp/mailman/listinfo/postgresforest-users
> 




postgresforest-users メーリングリストの案内
アーカイブの一覧に戻る