Re: postgresql.auto.conf read from wrong directory

From: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>
To: Christoph Berg <cb(at)df7cb(dot)de>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: postgresql.auto.conf read from wrong directory
Date: 2014-05-06 15:03:43
Message-ID: CAA4eK1LuW5dSbDOq_Eh=MZJROrkiXQo2k8hp+u33wGQkCHZMMg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, May 6, 2014 at 7:04 PM, Christoph Berg <cb(at)df7cb(dot)de> wrote:
> Hi,
>
> if you split configuration and data by setting data_directory,
> postgresql.auto.conf is writen to the data directory
> (/var/lib/postgresql/9.4/main in Debian), but tried to be read from
> the etc directory (/etc/postgresql/9.4/main).
>
> One place to fix it would be in ProcessConfigFile in
> src/backend/utils/misc/guc-file.l:162 by always setting
> CallingFileName = NULL in src/backend/utils/misc/guc-file.l:162, but
> that breaks later in AbsoluteConfigLocation() when data_directory is
> NULL. (As the comment in ProcessConfigFile says.)
>
> I'm not sure where to break that dependency loop - the fix itself
> seems easy, just don't tell to look for postgresql.auto.conf next to
> ConfigFileName, but in the data_directory.

Thanks for the report, will look into it.

With Regards,
Amit Kapila.
EnterpriseDB: http://www.enterprisedb.com

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2014-05-06 15:05:44 Re: sb_alloc: a new memory allocator for PostgreSQL
Previous Message Ashutosh Bapat 2014-05-06 15:01:35 Re: using array of char pointers gives wrong results