pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Gustavsson Mikael <mikael.gustavsson@smhi.se>
To: pgsql-general@postgresql.org <pgsql-general@postgresql.org>
Cc: Svensson Peter <peter.svensson@smhi.se>
Subject: Problem with ssl and psql in Postgresql 13
Date: Thu, 17 Dec 2020 07:21:08 +0000
Message-ID: <e5b0b6ed05764324a2f3fe7acfc766d5@smhi.se> (raw)

Hi,
We are starting our journey to migrate from Postgresql 11 to Postgresql 13 and have run into a problem.

The postgresql 13 version of psql don“t seem to work with ssl.
We use the community built rpms on redhat 8.3:

$ rpm -q postgresql11
postgresql11-11.10-1PGDG.rhel8.x86_64

$ rpm -q postgresql13
postgresql13-13.1-1PGDG.rhel8.x86_64

Is there some configuration we have missed that have changed between Postgresql 11 and 13?

Here is an example, sorry for the obfuscations.

It works as expected from psql 11:
$ psql -d postgres -Ukalle -hserver -W
Password:
psql (11.10, server 13.1)
WARNING: psql major version 11, server major version 13.
         Some psql features might not work.
SSL connection (protocol: TLSv1.3, cipher: TLS_AES_256_GCM_SHA384, bits: 256, compression: off)
Type "help" for help.

postgres=>

But not from psql 13:
$ /usr/pgsql-13/bin/psql -d postgres -Ukalle -hserver -W
Password:
psql: error: FATAL:  no pg_hba.conf entry for host "nnn.nn.n.nnn", user "kalle", database "postgres", SSL off
FATAL:  no pg_hba.conf entry for host "nnn.nn.n.nnn", user "kalle", database "postgres", SSL off


Our mean all-ssl test pg_hba.conf file:
# TYPE  DATABASE        USER            ADDRESS                 METHOD

# "local" is for Unix domain socket connections only
local   all             all                                     reject
# IPv4 local connections:
hostssl all             all             0.0.0.0/0                pam
# IPv6 local connections:
#host   all             all              ::1/128                 reject
# Allow replication connections from localhost, by a user with the
# replication privilege.
#host    replication          postgres                               reject


Kind Regards
Mikael Gustavsson, SMHI - Swedish Meteorological and Hydrological Institute

view thread (17+ messages)  latest in thread

Message-ID: <e5b0b6ed05764324a2f3fe7acfc766d5@smhi.se>
Permalink:  ../e5b0b6ed05764324a2f3fe7acfc766d5@smhi.se/
Also on:    postgresql.org/message-id/e5b0b6ed05764324a2f3fe7acfc766d5@smhi.se

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-general@postgresql.org
  Cc: mikael.gustavsson@smhi.se, peter.svensson@smhi.se
  Subject: Re: Problem with ssl and psql in Postgresql 13
  In-Reply-To: <e5b0b6ed05764324a2f3fe7acfc766d5@smhi.se>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox