Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1o249D-00019e-Rq for pgsql-general@arkaria.postgresql.org; Fri, 17 Jun 2022 05:03:55 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1o249C-0002W9-Bp for pgsql-general@arkaria.postgresql.org; Fri, 17 Jun 2022 05:03:54 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1o249B-0002V5-VS for pgsql-general@lists.postgresql.org; Fri, 17 Jun 2022 05:03:54 +0000 Received: from mail-pl1-x62e.google.com ([2607:f8b0:4864:20::62e]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1o2496-0007hf-BR for pgsql-general@lists.postgresql.org; Fri, 17 Jun 2022 05:03:52 +0000 Received: by mail-pl1-x62e.google.com with SMTP id d5so2939518plo.12 for ; Thu, 16 Jun 2022 22:03:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=date:message-id:to:cc:subject:from:in-reply-to:references :user-agent:mime-version:content-transfer-encoding; bh=csS9qodqpiRvTDXqyibIcCfQ+4QfJ3jft+hF+5Yl7J4=; b=nGmCE46zHz+zV6+Q11lC1nIlkDD34dFlya5bY1RRXdiRD8l3Ght2SMBwLCpnVVvgC8 s30YHRREImc/n7GAzWE7LDcTwgBpJmoJopgA7Jdr0JKlkqbdOWSd0ZhS4lm9gLSS8CWP 3OuisJ5Xdzk4NLiL3VQcYL4EBIm+Dr9xvdj/L8p4hHa3Vba6wXIBFiN+6vSAsrNDzu3K zjMDxGKxfqYHvSY9c4nxbTJYMmtydUSUFa91BWgwn1lOoO7adl62MsnClu9ox8TyNqxb hylsKVtFxVUgb0hQBdjZsDdl2ulOv8LR/J6yRcWJJO5flWlbEIOhNigjCgY73TJVtj8V njeg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:message-id:to:cc:subject:from:in-reply-to :references:user-agent:mime-version:content-transfer-encoding; bh=csS9qodqpiRvTDXqyibIcCfQ+4QfJ3jft+hF+5Yl7J4=; b=0RIrxkPVIkBuiY0nhb4n8uCIjxDgR8Iu5ezr7AvgQpQks2MqALAqKqVxh7cjyQhWo1 z1D49MEJS3JVxrwpx028zX8L+H7tpGAlGqNFl2Ngsq6ThVUJek8yrUmvKRD4daYCjQbJ A6//O6iJ9lr72oxZqrDuV0CFbkR0WcG9Retuovzz4quF1dvPHqHVjoGBM132bX+7JWH4 Gs6IEsfNZ/uTTNAurqZDH3mEx43XPcqsjjV7kJ2jVPHTJGfmyPwOF7+HHOaLUolwgvo5 ksWeHh0us/1a5MK2Wn99IiCdBmbw8BJhjUwf1Xgz4TEVb88Uf+f7EJEaz3Ax0ps/bmpj TChQ== X-Gm-Message-State: AJIora9x67aBG3oZk3v8h8lk0qhrZrI2jPSFiBuuc2UkaVa7dHmmgOI9 TB9ep0Nwif+9K4Zh6P/MyJY= X-Google-Smtp-Source: AGRyM1t8VT6/SBDg2VuWgSKD82Hxaxb/alZcNs9er3U35Cpm0J4NsxKCKU/UrM1JJdiWYPeXshSVCA== X-Received: by 2002:a17:90a:17ce:b0:1ea:c77d:c99e with SMTP id q72-20020a17090a17ce00b001eac77dc99emr18437153pja.63.1655442226294; Thu, 16 Jun 2022 22:03:46 -0700 (PDT) Received: from localhost (KD036014041111.ppp-bb.dion.ne.jp. [36.14.41.111]) by smtp.gmail.com with ESMTPSA id jc15-20020a17090325cf00b00168dadc7354sm2516022plb.78.2022.06.16.22.03.44 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Thu, 16 Jun 2022 22:03:45 -0700 (PDT) Date: Fri, 17 Jun 2022 14:03:43 +0900 (JST) Message-Id: <20220617.140343.794518949016832455.horikyota.ntt@gmail.com> To: hkanchu@apple.com Cc: pgsql-general@lists.postgresql.org Subject: Re: Any way to understand state after data corruption failures during startup. From: Kyotaro Horiguchi In-Reply-To: <9AAF8A3E-560D-4EEC-8828-92636B356777@apple.com> References: <9AAF8A3E-560D-4EEC-8828-92636B356777@apple.com> User-Agent: Mew version 6.8 on Emacs 26.1 Mime-Version: 1.0 Content-Type: Text/Plain; charset=iso-2022-jp Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk At Thu, 16 Jun 2022 19:46:25 -0700, Harinath Kanchu wrote in > > Hello, > > If postgres fail when it is starting as standby due to WAL file corruption, can we get the status through any exit code or by parsing pg_control file ? > > I can see the “XX001” code is emitted in logs but parsing logs doesn’t seem to be a good option. Please suggest. I'm not sure exactly what is what you want to achieve here, but there is a negative evidence for the reliability of detecting WAL corruption failure without searching server logs. [64923:startup] [XX000] 2022-06-17 13:30:52.493 JST PANIC: incorrect resource manager data checksum in record at 0/3000060 At least in this case, there's no trace of a server-stop due to WAL corruption left behind other than in server log. regards. -- Kyotaro Horiguchi NTT Open Source Software Center