From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com> |
Cc: | Michael Paquier <michael(at)paquier(dot)xyz>, Haribabu Kommi <kommi(dot)haribabu(at)gmail(dot)com>, Magnus Hagander <magnus(at)hagander(dot)net>, Stephen Frost <sfrost(at)snowman(dot)net>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: pg_basebackup ignores the existing data directory permissions |
Date: | 2019-04-03 16:01:15 |
Message-ID: | CA+TgmobBf+x7XqxbPKYR4+snFq8iWzS8Rtc=z8V92iJYHm79aQ@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Fri, Mar 29, 2019 at 6:05 AM Peter Eisentraut
<peter(dot)eisentraut(at)2ndquadrant(dot)com> wrote:
> On 2019-03-26 03:26, Michael Paquier wrote:
> > Do we really want to extend the replication protocol to control that?
>
> Perhaps we are losing sight of the original problem, which is that if
> you create the target directory with the wrong permissions then ... it
> has the wrong permissions. And you are free to change the permissions
> at any time. Many of the proposed solutions sound excessively
> complicated relative to that.
I don't think I agree with that characterization of the problem. I
mean, what do you mean by "wrong"? Perhaps you created the directory
with the "right" permissions, i.e. those you actually wanted, and then
pg_basebackup rather rudely insisted on ignoring them when it decided
how to set the permissions for the files inside that directory. On the
other hand, perhaps you wished to abdicate responsibility for security
decisions to whatever rule pg_basebackup uses, and it rather rudely
didn't bother to enforce that decision on the top level directory,
forcing you to think about a question you had decided to ignore.
I am not sure what solution is best here, but it is hard to imagine
that the status quo is the right thing.
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Haas | 2019-04-03 16:13:51 | Re: Caveats from reloption toast_tuple_target |
Previous Message | Robert Haas | 2019-04-03 15:55:00 | Re: New vacuum option to do only freezing |