Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1ruXFu-005zr4-7B for pgsql-general@arkaria.postgresql.org; Wed, 10 Apr 2024 12:40:46 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1ruXFs-0026qK-8K for pgsql-general@arkaria.postgresql.org; Wed, 10 Apr 2024 12:40:44 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1ruXFr-0026qC-Tn for pgsql-general@lists.postgresql.org; Wed, 10 Apr 2024 12:40:43 +0000 Received: from ms-10.1blu.de ([178.254.4.101]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1ruXFp-000C7i-16 for pgsql-general@lists.postgresql.org; Wed, 10 Apr 2024 12:40:43 +0000 Received: from [212.222.85.114] (helo=pureos) by ms-10.1blu.de with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.95) (envelope-from ) id 1ruXFn-004Sf9-E4; Wed, 10 Apr 2024 14:40:39 +0200 Date: Wed, 10 Apr 2024 14:40:37 +0200 From: Matthias Apitz To: Ian Lawrence Barwick Cc: pgsql-general@lists.postgresql.org Subject: Re: mystery with postgresql.auto.conf Message-ID: Reply-To: Matthias Apitz References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Operating-System: FreeBSD 14.0-CURRENT 1400094 (amd64) X-message-flag: Mails in HTML will not be read! Send only plain text. X-Con-Id: 51246 X-Con-U: 0-guru X-Originating-IP: 212.222.85.114 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk El día miércoles, abril 10, 2024 a las 09:08:56 +0900, Ian Lawrence Barwick escribió: > > # cat postgresql151/data/postgresql.auto.conf > > # Do not edit this file manually! > > # It will be overwritten by the ALTER SYSTEM command. > > shared_preload_libraries = 'pg_tde' > > > > How is this possible? I only used in the 16.2 server the SQL commands: > > > > sisis=# CREATE EXTENSION pg_tde; > > sisis=# SELECT pg_tde_add_key_provider_file('file','/tmp/pgkeyring'); > > sisis=# SELECT pg_tde_set_master_key('my-master-key','file'); > > The simplest explanation is that you (or someone), when configuring pg_tde, > accidentally executed (as per the instructions [*]): > > ALTER SYSTEM SET shared_preload_libraries = 'pg_tde'; > > in the 15.1 instance, rather than the 16.2 instance. This will have > resulted in the > entry in the 15.1 postgresql.auto.conf. Here are my notes from the testing pg_tde: Install sisis-pap v73 and create a PostgreSQL 16.2 cluster the usual way, load a database dump into it (all done on srap21dxr1.dev.oclc.org) I followed exactly https://github.com/Percona-Lab/pg_tde?tab=readme-ov-file psql -Usisis sisis psql (16.2) Type "help" for help. sisis=# ALTER SYSTEM SET shared_preload_libraries = 'pg_tde'; (PostgreSQL restart) ... The notes have been done by cut&paste into a text file. The psql was fired up against the 16.2 server as it says above. And we also have never two servers up at the same time. Maybe later I did it accidently against the 15.1 server from the psql history. I just tested it in the 15.1 server: it does not give any error: psql -Usisis sisis psql (15.1) Type "help" for help. sisis=# ALTER SYSTEM SET shared_preload_libraries = 'pg_tde'; ALTER SYSTEM sisis=# and the file gets modified :-( Why it does not give an error because the shared lib isn't there? matthias -- Matthias Apitz, ✉ guru@unixarea.de, http://www.unixarea.de/ +49-176-38902045 Public GnuPG key: http://www.unixarea.de/key.pub