Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id C7A23B5DC13 for ; Tue, 20 Sep 2011 13:48:42 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 40977-08 for ; Tue, 20 Sep 2011 16:48:36 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.8.0-rc2 Received: from mail-pz0-f44.google.com (mail-pz0-f44.google.com [209.85.210.44]) by mail.postgresql.org (Postfix) with ESMTP id 65AAEB5DC09 for ; Tue, 20 Sep 2011 13:48:36 -0300 (ADT) Received: by pzk36 with SMTP id 36so3626165pzk.3 for ; Tue, 20 Sep 2011 09:48:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:subject :content-type:content-transfer-encoding; bh=H7of9dbSUGed2Mci1pmxS/IlOTC5wNjiC0CcL+BQSGc=; b=fpSCKyAa3YQzkX4b2KaUpjI56KHqHZ17YK8PsOhx2XTwDd7HZr9kmJbSXTDVSsFiXX 9r6RhA2vQV8S90pwlhrW+s+g4Ca88xAcdUsk69BdFE3gflvMO9MDzUHu/5pMvyBLMEeo +GSNtkriiXbH+a+bQfl4Gd/42MQqpkR2/VEYw= Received: by 10.68.52.106 with SMTP id s10mr3663287pbo.40.1316537315709; Tue, 20 Sep 2011 09:48:35 -0700 (PDT) Received: from [192.168.11.3] ([114.85.128.121]) by mx.google.com with ESMTPS id n10sm7525813pbe.4.2011.09.20.09.48.21 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 20 Sep 2011 09:48:33 -0700 (PDT) Message-ID: <4E78C3C3.5040208@gmail.com> Date: Wed, 21 Sep 2011 00:48:03 +0800 From: Rural Hunter User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:6.0.2) Gecko/20110902 Thunderbird/6.0.2 MIME-Version: 1.0 To: pgsql-admin@postgresql.org Subject: Warm standby terminate itself? Content-Type: text/plain; charset=GB18030; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.889 tagged_above=-10 required=5 tests=BAYES_00=-1.9, FREEMAIL_FROM=0.001, T_TO_NO_BRKTS_FREEMAIL=0.01 X-Spam-Level: X-Archive-Number: 201109/135 X-Sequence-Number: 38372 Hi, I set up an warm standby server which fetches WAL logs from a remote server. It has been working very well. But today, I was editing the restore script(which is set as the restore_command) with vi. Just right after I saved the script, I noticed suddenly the standby server terminated. I checked log and only found these: scp: /dbbk/postgres/logarch/0000000100000079000000B3.gz: No such file or directory #this is in my script and it unzip the WAL log if it exists 2011-09-20 23:56:50 CST FATAL: could not restore file "0000000100000079000000B3" from archive: return code 65280 2011-09-20 23:56:51 CST LOG: startup process (PID 2153) exited with exit code 1 2011-09-20 23:56:51 CST LOG: terminating any other active server processes I believe the script doesn't exit with 0 for any error(and it has been working smoothly without any modification after server restart). After I started the server, it just restored passing the file without problem and it can live with file "No such file" warning because the master server hasn't generated the log yet. I have no idea why the restore failed. But even the restore fails, why it lead to a server crash(looks like so)?