BUG #16026: default_tablespace in postgresql.conf is used instead of the database's default. - Mailing list pgsql-bugs

From PG Bug reporting form
Subject BUG #16026: default_tablespace in postgresql.conf is used instead of the database's default.
Date
Msg-id 16026-7938df12bae60c5e@postgresql.org
Whole thread Raw
Responses Re: BUG #16026: default_tablespace in postgresql.conf is used instead of the database's default.
List pgsql-bugs
The following bug has been logged on the website:

Bug reference:      16026
Logged by:          virgile crevon
Email address:      virgile.crevon@dassault-aviation.com
PostgreSQL version: 10.5
Operating system:   redhat 7 64 bits
Description:

Hi,

To reproduce :

1- create a tablespace data  (whereever you want it to be). Note that data
is lowercase without quotation marks.
2- set default_tablespace='DATA' in postgresql.conf. Note this is un
UPPERCASE.
3- reload conf.
4- create a database with default tablespace data (lowercase).
5- create a query that is using parallel (gather step) to seq scan.

Since the worker work with default tablespace at postgresql.conf level, he
will break with the following message :

2019-09-25 16:42:50.444 GMT [71530] ERROR:  invalid value for parameter
"default_tablespace": "DATA"
2019-09-25 16:42:50.444 GMT [71530] DETAIL:  Tablespace "DATA" does not
exist.
::  ::  ::  ::  2019-09-25 18:42:50.445 CEST ::
 LOG:  worker process: parallel worker for PID 62413 (PID 71531) exited with
exit code 1
 ::  ::  ::  ::  2019-09-25 18:42:50.445 CEST ::
 LOG:  worker process: parallel worker for PID 62413 (PID 71530) exited with
exit code 1

(2 workers for this query, will end up with more error if parallel mode is
configured differently on your system).

Perhaps it's a documentation issue (default_tablespace is not mentionned to
be used by parallel_query).
But i think it is more a bug : it would definitively have to get the default
tablespace from database where the query is run.

Regards,

Virgile CREVON


pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #16025: pg_default tablespace is removable but not creatable
Next
From: Tom Lane
Date:
Subject: Re: BUG #16026: default_tablespace in postgresql.conf is used instead of the database's default.