Hi,
On 2024-04-17 16:16:55 -0400, Robert Haas wrote:
> In the "Differential code coverage between 16 and HEAD" thread, Andres
> pointed out that there wasn't test case coverage for
> pg_combinebackup's code to handle files in tablespaces. I looked at
> adding that, and as nobody could possibly have predicted, found a bug.
Ha ;)
> @@ -787,8 +787,13 @@ Does not start the node after initializing it.
>
> By default, the backup is assumed to be plain format. To restore from
> a tar-format backup, pass the name of the tar program to use in the
> -keyword parameter tar_program. Note that tablespace tar files aren't
> -handled here.
> +keyword parameter tar_program.
> +
> +If there are tablespace present in the backup, include tablespace_map as
> +a keyword parameter whose values is a hash. When tar_program is used, the
> +hash keys are tablespace OIDs; otherwise, they are the tablespace pathnames
> +used in the backup. In either case, the values are the tablespace pathnames
> +that should be used for the target cluster.
Where would one get these oids?
Could some of this be simplified by using allow_in_place_tablespaces instead?
Looks like it'd simplify at least the extended test somewhat?
Greetings,
Andres Freund