BUG #16604: pg_dump with --jobs breaks SSL connections

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

BUG #16604: pg_dump with --jobs breaks SSL connections

PG Doc comments form
The following bug has been logged on the website:

Bug reference:      16604
Logged by:          Zsolt Ero
Email address:      [hidden email]
PostgreSQL version: 12.4
Operating system:   Ubuntu 20.04
Description:        

I'm using pg_dump in the following syntax:

pg_dump --dbname="sslmode=verify-ca sslrootcert=server-ca.pem \
      sslcert=client-cert.pem sslkey=client-key.pem \
      hostaddr=1.2.3.4 \
      user=postgres dbname=app" \
      --format=directory \
      --file=dump_app \
      --jobs=3

As long as the --jobs parameter is present, the process breaks after
"pg_dump: saving database definition".
It breaks with "FATAL:  connection requires a valid client certificate".

Without --jobs it completes without errors. I also think it's happening with
pg_restore as well.

Client is postgresql-client-12 under Ubuntu 20.04 from latest official
packages (http://apt.postgresql.org/pub/repos/apt).

Reply | Threaded
Open this post in threaded view
|

Re: BUG #16604: pg_dump with --jobs breaks SSL connections

Daniel Gustafsson
> On 1 Sep 2020, at 22:08, PG Bug reporting form <[hidden email]> wrote:
>
> The following bug has been logged on the website:
>
> Bug reference:      16604
> Logged by:          Zsolt Ero
> Email address:      [hidden email]
> PostgreSQL version: 12.4
> Operating system:   Ubuntu 20.04
> Description:        
>
> I'm using pg_dump in the following syntax:
>
> pg_dump --dbname="sslmode=verify-ca sslrootcert=server-ca.pem \
>      sslcert=client-cert.pem sslkey=client-key.pem \
>      hostaddr=1.2.3.4 \
>      user=postgres dbname=app" \
>      --format=directory \
>      --file=dump_app \
>      --jobs=3
>
> As long as the --jobs parameter is present, the process breaks after
> "pg_dump: saving database definition".
> It breaks with "FATAL:  connection requires a valid client certificate".
>
> Without --jobs it completes without errors. I also think it's happening with
> pg_restore as well.

I am unable to reproduce this with 12.4 as well as 14devel.  If this error is
reproducible for you, can you please share more details on the setup?  (ideally
a recipe for setting up a repro environment)

cheers ./daniel

Reply | Threaded
Open this post in threaded view
|

Re: BUG #16604: pg_dump with --jobs breaks SSL connections

Magnus Hagander-2
On Tue, Sep 15, 2020 at 1:36 PM Daniel Gustafsson <[hidden email]> wrote:
> On 1 Sep 2020, at 22:08, PG Bug reporting form <[hidden email]> wrote:
>
> The following bug has been logged on the website:
>
> Bug reference:      16604
> Logged by:          Zsolt Ero
> Email address:      [hidden email]
> PostgreSQL version: 12.4
> Operating system:   Ubuntu 20.04
> Description:       
>
> I'm using pg_dump in the following syntax:
>
> pg_dump --dbname="sslmode=verify-ca sslrootcert=server-ca.pem \
>      sslcert=client-cert.pem sslkey=client-key.pem \
>      hostaddr=1.2.3.4 \
>      user=postgres dbname=app" \
>      --format=directory \
>      --file=dump_app \
>      --jobs=3
>
> As long as the --jobs parameter is present, the process breaks after
> "pg_dump: saving database definition".
> It breaks with "FATAL:  connection requires a valid client certificate".
>
> Without --jobs it completes without errors. I also think it's happening with
> pg_restore as well.

I am unable to reproduce this with 12.4 as well as 14devel.  If this error is
reproducible for you, can you please share more details on the setup?  (ideally
a recipe for setting up a repro environment)

Grasping a long straw hwere, but I wonder if it could be relataed to the debian/ubuntu wrapper.

Zsolt, can you try running it with hardcoding the pg_dump path to /usr/lib/postgresql/12/bin/pg_dump instead of just pg_dump, to see if that might be it? 

--