From: | "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com> |
---|---|
To: | Peter Eisentraut <peter(at)eisentraut(dot)org> |
Cc: | Gabriele Bartolini <gabriele(dot)bartolini(at)enterprisedb(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Magnus Hagander <magnus(at)hagander(dot)net>, Robert Haas <robertmhaas(at)gmail(dot)com>, Martín Marqués <martin(dot)marques(at)gmail(dot)com>, Isaac Morland <isaac(dot)morland(at)gmail(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Possibility to disable `ALTER SYSTEM` |
Date: | 2024-02-06 14:38:06 |
Message-ID: | CAKFQuwaWhu0Y84JaVf+Vt4d6VQtRPhY0PEud8uM_Ostes=-dsA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Tue, Feb 6, 2024 at 7:10 AM Peter Eisentraut <peter(at)eisentraut(dot)org>
wrote:
>
> How about ALTER SYSTEM is disabled if the file
> postgresql.auto.conf.disabled exists? This is somewhat similar to making
> the file read-only, but doesn't risk other tools breaking when they
> encounter such a file. And it's more obvious and self-explaining.
>
A separate configuration file would be self-documenting and able to always
exist; the same properties as postgres.conf
ISTM the main requirement regardless of how the file system API is designed
- assuming there is a filesystem API - is that the running postgres process
be unable to write to the file. It seems immaterial how the OS admin
accomplishes that goal.
The command line argument method seems appealing but it seems harder in
that case to ensure that the postgres process be disallowed from modifyIng
whatever file defines what should be run.
One concern with a file configuration is that if we require it to be
present in the data directory that goes somewhat against the design of
allowing configuration files to be placed anywhere by changing the
config_file guc.
Any design should factor in the almost immediate need to be extended to
prevent copy variants that touch the local filesystem or shell directly.
I was pondering a directory in pgdata where you could add *.disabled files
indicating which features to disable. This is a bit more pluggable than a
single configuration file but the later still seems better to me.
David J.
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2024-02-06 14:51:56 | Re: Why is subscription/t/031_column_list.pl failing so much? |
Previous Message | Peter Eisentraut | 2024-02-06 14:10:27 | Re: Possibility to disable `ALTER SYSTEM` |