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 1ntBRa-0008D1-Fc for pgsql-general@arkaria.postgresql.org; Mon, 23 May 2022 17:02:10 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1ntBRZ-0001qg-Bm for pgsql-general@arkaria.postgresql.org; Mon, 23 May 2022 17:02:09 +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 1ntBRY-0001qX-W8 for pgsql-general@lists.postgresql.org; Mon, 23 May 2022 17:02:09 +0000 Received: from mail-pg1-x531.google.com ([2607:f8b0:4864:20::531]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1ntBRR-0003lw-RS for pgsql-general@lists.postgresql.org; Mon, 23 May 2022 17:02:07 +0000 Received: by mail-pg1-x531.google.com with SMTP id a38so11327415pgl.9 for ; Mon, 23 May 2022 10:02:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=message-id:date:mime-version:user-agent:subject:content-language:to :references:from:in-reply-to; bh=hVE3lr1RY11bbqpAvmSDD28z7K7W7emDFBYlZLPtGls=; b=ogGsbovR3sgbgFY6Sr4bq3fOxQ7VAOFlMigtSORI23Weof7NEOGV4IEy0/TcvuWfiX PqXFbXjHNoWzOmzqf1q+pxD2xPi1UKGdyUPJjLVRAZk+hMDphQaVF8F/N9dBuy8y42TK ImLn1xsPS1hDsGMzSYQeaMX5jLRndB8ZjY7PykWUYKrBqep3XXpJYMa73Bj6SWCDLTnG 6G+o+6A4YfUUMVNYmLkjs3GpYHTkOHMNIU1baG/mhrGFYMnqRUqFWExZJf+2Hw1FGbA6 Syrpfh8M1bme5RrhrkTEWxwTcTZBw++uLCC2+5gi+WZEO+W3n+DE1ub/fsY7Idi6Q/Ny nmMg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:references:from:in-reply-to; bh=hVE3lr1RY11bbqpAvmSDD28z7K7W7emDFBYlZLPtGls=; b=2/cOh0V+tSXjhmuA2Mgoy8XOXDCYya2e8m0XUP8slijEli3CwKP8z5WQMLRkkE1pVW bDoXOz+S/pSLyE8cbDVf59Ke33BNNDW+Ye43VIVCW0dcsRcCsisMojbfBjmKWk5g4O7B 57QDHVmyLxhG8r82ks/fQrgo7jk9zdgzws9y8rhffffy8bl42pP/c+rrD+PBoM0N6475 gbz7rmYvwJK+QqB55v9i9J4x3ZeBOsCh0cBrftfEwYXMvvJC7FMOmMkGvm1dwAi4ZUPn MWkC+Bk23WIBILeLlKj+bz1QxDxcvlI/kusZjD3KB8NIe4NJ60J1p9c28hXlALA0fSyv iDpw== X-Gm-Message-State: AOAM532nvjE+b5X5yxoNdTR31PlxARwGTttGsfGNtA7kT90p8CYXG2JK zJXz4Gwc/vy0M5UCwam311WgE1krqvA= X-Google-Smtp-Source: ABdhPJzVTTxzkDpdbqN5saWf4XaCeMzP+MnOFQ8t9JFEM3Da8X8A9PqOZKsub4zJQeBSDr55HFhFOQ== X-Received: by 2002:a65:4988:0:b0:3fa:8154:e1e1 with SMTP id r8-20020a654988000000b003fa8154e1e1mr2612680pgs.12.1653325320833; Mon, 23 May 2022 10:02:00 -0700 (PDT) Received: from [10.128.71.194] ([155.98.131.2]) by smtp.gmail.com with ESMTPSA id m26-20020a63711a000000b003c6a80e54cfsm5043217pgc.75.2022.05.23.10.01.59 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 23 May 2022 10:02:00 -0700 (PDT) Content-Type: multipart/alternative; boundary="------------E44jM1f8BczPltx1UMY0O2wl" Message-ID: <2904d7b9-3bf0-fee0-f043-c8f904fc6c1d@gmail.com> Date: Mon, 23 May 2022 11:01:58 -0600 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.0 Subject: Re: list tablespaces named in custom format dump Content-Language: en-CA To: Adrian Klaver , "pgsql-generallists.postgresql.org" References: <29112dbe-b1bd-afe9-63d3-f7ba50ece939@gmail.com> <9013c93e-3f01-f40a-4e14-7b1c9d7b065d@aklaver.com> <55cf2ca7-b431-b5bc-1b86-b6c8726ac4c5@aklaver.com> From: Rob Sargent In-Reply-To: <55cf2ca7-b431-b5bc-1b86-b6c8726ac4c5@aklaver.com> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk This is a multi-part message in MIME format. --------------E44jM1f8BczPltx1UMY0O2wl Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit On 5/23/22 11:00, Adrian Klaver wrote: > On 5/23/22 9:54 AM, Rob Sargent wrote: >> On 5/23/22 10:50, Adrian Klaver wrote: > >> Roger that, but does the dump of a database name the tablespaces from >> which the objects were retrieved? And if so, is that accessible? >> > > > https://www.postgresql.org/docs/14/app-pgrestore.html > > "--no-tablespaces > >     Do not output commands to select tablespaces. With this option, > all objects will be created in whichever tablespace is the default > during restore. > " > > Would indicate it does. I don't have cluster set up with tablespaces > to test, but I would try: > > pg_restore -l > > This will produce a Table of Contents for the file. > Ah, missed that. Thanks. (Now I'll have to find the version used to dump the db...) --------------E44jM1f8BczPltx1UMY0O2wl Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 8bit
On 5/23/22 11:00, Adrian Klaver wrote:
On 5/23/22 9:54 AM, Rob Sargent wrote:
On 5/23/22 10:50, Adrian Klaver wrote:

Roger that, but does the dump of a database name the tablespaces from which the objects were retrieved? And if so, is that accessible?



https://www.postgresql.org/docs/14/app-pgrestore.html

"--no-tablespaces

    Do not output commands to select tablespaces. With this option, all objects will be created in whichever tablespace is the default during restore.
"

Would indicate it does. I don't have cluster set up with tablespaces to test, but I would try:

pg_restore -l <custom_format_file>

This will produce a Table of Contents for the file.

Ah, missed that.  Thanks.
(Now I'll have to find the version used to dump the db...)
--------------E44jM1f8BczPltx1UMY0O2wl--