Re: exposing pg_controldata and pg_config as functions

From: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Peter Eisentraut <peter_e(at)gmx(dot)net>, Joe Conway <mail(at)joeconway(dot)com>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Michael Paquier <michael(dot)paquier(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: exposing pg_controldata and pg_config as functions
Date: 2015-09-02 21:34:57
Message-ID: 20150902213457.GY2912@alvherre.pgsql
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane wrote:
> Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> > But I'm not sure I like the idea of adding a server dependency on the
> > ability to exec pg_controldata. That seems like it could be
> > unreliable at best, and a security vulnerability at worst.
>
> I hadn't been paying attention --- the proposed patch actually depends on
> exec'ing pg_controldata? That's horrid! There is no expectation that
> that's installed.

No, it doesn't. For the pg_controldata output it processes the
pg_control file directly, and for pg_config it relies on compile-time
CPPFLAGS.

I think trying to duplicate the exact strings isn't too nice an
interface.

--
Álvaro Herrera http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Josh Berkus 2015-09-02 21:36:30 Re: Horizontal scalability/sharding
Previous Message Josh Berkus 2015-09-02 21:31:35 Re: Allow a per-tablespace effective_io_concurrency setting