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 1pXk02-00034r-7U for pgsql-admin@arkaria.postgresql.org; Thu, 02 Mar 2023 14:33:38 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1pXk00-0006kz-Ss for pgsql-admin@arkaria.postgresql.org; Thu, 02 Mar 2023 14:33:36 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pXk00-0006kp-Hq for pgsql-admin@lists.postgresql.org; Thu, 02 Mar 2023 14:33:36 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pXjzy-0007GA-Gs for pgsql-admin@lists.postgresql.org; Thu, 02 Mar 2023 14:33:36 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 322EXU1B1897765; Thu, 2 Mar 2023 09:33:30 -0500 From: Tom Lane To: Holger Jakobs cc: "pgsql-admin@lists.postgresql.org" Subject: Re: psql terminates on first error In-reply-to: <572addf0-5116-cec0-77fb-9a0ba0161240@jakobs.com> References: <572addf0-5116-cec0-77fb-9a0ba0161240@jakobs.com> Comments: In-reply-to Holger Jakobs message dated "Thu, 02 Mar 2023 12:53:19 +0100" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <1897763.1677767610.1@sss.pgh.pa.us> Date: Thu, 02 Mar 2023 09:33:30 -0500 Message-ID: <1897764.1677767610@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Holger Jakobs writes: > While trying to transfer data from one instance to another using > pg_dumpall and psql, the psql stopped on first error, causing pg_dumpall > to terminate as well. > This behaviour was seen on Windows (EDB installer), but is different on > Linux. > Only when using an option -c "\set ON_ERROR_STOP false" (plus -f - of > course to continue reading) psql continued after first error. > Not even the option -v ON_ERROR_STOP=0 helped. > Why is the behaviour between Linux and Windows different? This is not > reflected in the documentation. It shouldn't be different. However, this report would be trivially explained if your Windows machine has an %APPDATA%\postgresql\psqlrc.conf file that turns ON_ERROR_STOP on. You could try invoking psql with the -X command line switch to prevent reading that. regards, tom lane