Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1w73BW-004uYW-18 for pgsql-hackers@arkaria.postgresql.org; Mon, 30 Mar 2026 03:21:02 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1w73BU-000tgE-2k for pgsql-hackers@arkaria.postgresql.org; Mon, 30 Mar 2026 03:21:01 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1w73BU-000tfb-19 for pgsql-hackers@lists.postgresql.org; Mon, 30 Mar 2026 03:21:00 +0000 Received: from mail-ot1-x331.google.com ([2607:f8b0:4864:20::331]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1w73BR-00000001jx7-0MYO for pgsql-hackers@postgresql.org; Mon, 30 Mar 2026 03:20:59 +0000 Received: by mail-ot1-x331.google.com with SMTP id 46e09a7af769-7d75371d873so3957545a34.3 for ; Sun, 29 Mar 2026 20:20:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1774840856; cv=none; d=google.com; s=arc-20240605; b=amkw0CftYX8EiXd6yTm2UqX8zCT/zYuveY/TUQE2LBpQPvq6DyzsIrifd8xT2UrqEv i34bgmt8Cy4dwp3PJAiQLKte63h326rSl//cO0LzE4+2YgoTFnZRkPIu8ig4YXCEn1i5 21+h6F6oCfeJp5tTuMcmqtAOX8d/0rFS/kWTVlJUrTHA0vn9d5hrfvZulRMPfiuddJAK cCNEYeG9TbtKt5UHtAGF4cUvGxGQbTk+ze6g7TAXBlJgxVFO7INF6ckkLHvDwXgt5yRX pALE5oKp/N5ySU5E2Wq6QJDSrekJbDQkOzvk1WwwU3SJHjgEHeCKLKoC4ICN4X+1riFu neFQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:dkim-signature; bh=8iDTd1GimT19VrJFrfTGUqH6jJktKQvMBr+zNyNNjyE=; fh=mDOW5o7duyRoal69YH+GIB822ve3WsByHL70y82Wnrg=; b=KohOBnZeLCqOjR8TJiXFFrqY5ZclNR8pmHPyX4b6Iam0Ba8a2o8Rddbt0tVZyufsy7 +c26tcc5Gwo1edKJyJ2UFt04t73qCZB4EU1SJ9BSWzHS8HTpQQMqhkYXunLGuJD9C08M e56Gtq8e/NnS1WeuwYgRHH070IRwHT6SzftbD2pzP3TiioVSdRBZt66ZBYCkjTWMZYU7 zhGRLV15bA5k/hOxa5dKtDIgJzlIWtZdnVCR0FWAGkTvWDC8SLtmEelNe1MCOcmWgGy/ FD4xwM9eoowQj24Q14+CpnbXWanlIU6g94Osnxin1g2TabZaqRypp6ue54/qjp6SJYfJ xJWw==; darn=postgresql.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1774840856; x=1775445656; darn=postgresql.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=8iDTd1GimT19VrJFrfTGUqH6jJktKQvMBr+zNyNNjyE=; b=aCN58si8OHQQkpGAdORad7RQiDITdymmNpusgWQnWuo+3ZtYVY4AhLf9nnbLcUIEUi fK2fFmmv7XKtEV4k7oH0H4jdrjtwkFHHm5bEXYn6oyTowAUgTMpvyNX2W4yBJ0C3qo16 2ncvbAbbETBgXRZKJcW9jL3XM332bQHSMS7EYzSAcRMw7JXsE+XEDwghZGvC+c1vNEis 5Uedf+BSeZjP2qh6TApiUzG8eMCJYmzwNDJ3hzZYJa+8BXV5MEot+isC/ELKen4Rm4xu DhOX23G5rxwRgngZyHJgPBeop2+f38OoWkJBYHO1wxVz7RB8xuv1uSxbCnPkA3C8qWH9 7mkQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1774840856; x=1775445656; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=8iDTd1GimT19VrJFrfTGUqH6jJktKQvMBr+zNyNNjyE=; b=eiuTEO3s7Q1dFHXR8hGNdw9sVPxhxlPt5uajBeVCc2HGZOse1qjTOzc8ir8YWYjfRc 6mxgH1/DrVMWc/mvt8le0DGng27eCsMnLzu9f+DMXoW7zIVQkp9RTz4CCVmgFO5PuQOz yKRhfq6UA/W5EgrgNPKbjdCPCy05LVlVzb0UD7Y+TO9L9AIpoh6fboogEWonkbu1DK44 toWvcOq3wLl7KDn5nLCqqfM0SAiK2qgJW4lGRAPd9KE0uCtyNfOz7YO4TvJQOlNTNxCf mSbTRyflv3591cpSqCTYbPRN0F5O37dDa2Eyq9eTgDOUEEnmtEUF66zj99uYpjz3T/ZM sETg== X-Forwarded-Encrypted: i=1; AJvYcCUobeft6WRoLCpoA59evltL8fI7h50RQzOd/OIw0P8bNlDQeI8aU/bhGMWuT9lLudFOJCqZyIDuUFRg2qpV@postgresql.org X-Gm-Message-State: AOJu0YxB6SEIv02GA/0YFbb1cxz5DcXhw0IJ7dK8/sXC6Bd4BsDyBD5u 4L6Ha2C9cE0kusYlzIuDNeoRTd5XYNRN9bmJxMktCht8qzeHnYLRUD/ITt4riH/E+uCvoDfTdu8 bSsZt6cSJqo3G4UByK77VczQelQBZgZA= X-Gm-Gg: ATEYQzybiD4RAO9Pj7idHz9mRKu8GiQEUWyKFZqWlXt0VxrS4KSaMg/oIG22ct21O7E f6mFT+j0f4hERP6GhLOMHu7dVC1SrtPvdQNU/He2JyBtLmEuUM5jok9jaxbSB2lsVolhT75rl19 TZ5z7p5fSTlfCOZhWnPEDxW5qvyZgGyoAWFk7M2t/ZFxu+q1jSvjJ2GbRVueDK3TURXndXMBd9W SSvQE4HjLXaQT5yhSiczEKJqBurm3mHl2vQUz85ohoWw7yFv8fqs6Xq8OCszr53hbjkylBeEw3H +4u48wXiKT5qnylpzbkYaUY2JCC1SxrFkNXe/5Y= X-Received: by 2002:a05:6820:179a:b0:679:88ee:e3f8 with SMTP id 006d021491bc7-67e187911e1mr5743208eaf.68.1774840856340; Sun, 29 Mar 2026 20:20:56 -0700 (PDT) MIME-Version: 1.0 References: <1849705.1774809224@sss.pgh.pa.us> In-Reply-To: <1849705.1774809224@sss.pgh.pa.us> From: "David G. Johnston" Date: Sun, 29 Mar 2026 20:20:20 -0700 X-Gm-Features: AQROBzDh7qRmvmPUj1HXq3BelBh0YSO-1czDWIiR9d4_tUYmsErm8SE26GD7U4s Message-ID: Subject: Re: docs: warn about post-data-only schema dumps with parallel restore. To: Tom Lane Cc: vaibhave postgres , pgsql-hackers@postgresql.org Content-Type: multipart/alternative; boundary="000000000000c66bab064e3556f2" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --000000000000c66bab064e3556f2 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Sun, Mar 29, 2026 at 11:33=E2=80=AFAM Tom Lane wrote= : > "David G. Johnston" writes: > > On Sun, Jan 25, 2026 at 10:23=E2=80=AFPM vaibhave postgres < > > postgresvaibhave@gmail.com> wrote: > >> Following up on the discussion in [1] about pg_restore failing to > restore > >> post-data items due to circular foreign key deadlocks. > >> I=E2=80=99m attaching a doc patch that adds a warning about using post= -data-only > >> schema dumps together with parallel restore. > > > Not a fan of the patch overall though. I'd want to add something to > > pg_restore noting that use of --jobs for constraint restoration needs > > schema information to compute the restoration order. > > Yeah, dropping this into the list of options is bad. We put caveats > like that into the Notes section usually. > > I also tend to think that it'd be better to document this under > pg_restore: when people run into this type of failure, they are going > to go to the pg_restore docs not the pg_dump docs to understand it. > I guess there could be a case for repeating the info in both the > pg_dump and pg_restore pages, but that feels a bit verbose. > > So maybe like the attached? > > Works for me. But how about adding something like the following to the pg_dump notes? We already have the corresponding link going to pg_dump in the pg_restore notes. "If producing a non-plaint-text format output see also the pg_restore documentation for details on how the restore process uses the different sections." David J. --000000000000c66bab064e3556f2 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
On Sun, Mar 29, 2026 at 11:33=E2=80=AFAM Tom Lane <tgl@sss.pgh.pa.us> wrote:
"David G. Johnston" <david.g.johnston@g= mail.com> writes:
> On Sun, Jan 25, 2026 at 10:23=E2=80=AFPM vaibhave postgres <
> postgr= esvaibhave@gmail.com> wrote:
>> Following up on the discussion in [1] about pg_restore failing to = restore
>> post-data items due to circular foreign key deadlocks.
>> I=E2=80=99m attaching a doc patch that adds a warning about using = post-data-only
>> schema dumps together with parallel restore.

> Not a fan of the patch overall though.=C2=A0 I'd want to add somet= hing to
> pg_restore noting that use of --jobs for constraint restoration needs<= br> > schema information to compute the restoration order.

Yeah, dropping this into the list of options is bad.=C2=A0 We put caveats like that into the Notes section usually.

I also tend to think that it'd be better to document this under
pg_restore: when people run into this type of failure, they are going
to go to the pg_restore docs not the pg_dump docs to understand it.
I guess there could be a case for repeating the info in both the
pg_dump and pg_restore pages, but that feels a bit verbose.

So maybe like the attached?


Work= s for me.

But how about adding something like the followi= ng to the pg_dump notes?=C2=A0 We already have the corresponding link going= to pg_dump in the pg_restore notes.

"If producin= g a non-plaint-text format output see also the pg_restore documentation for= details on how the restore process uses the different sections."

David J.

--000000000000c66bab064e3556f2--