[CentOS] Postgres Config File (eg: PGDATA)
Marko A. Jennings
markobiz at bluegargoyle.com
Tue Sep 25 08:18:50 UTC 2007
On Tue, September 25, 2007 3:34 am, Ow Mun Heng wrote:
> Hi guys,
> need some clarification on whether there is a config file sourced by the
> init script to determine where PGDATA is located.
> Right now, it seems like it's not sourced from anywhere by located on
> the init file itself.
> Appreciate if you guys can let me know if this is the correct place for
> altering it.
Multiple instances of Postgres database will have separate init scripts.
The location of the config file for each init script is
For example, for the default init script (/etc/init.d/postgresql) that
gets installed with Postgres, the config file is
/etc/sysconfig/pgsql/postgresql . Although the /etc/sysconfig/pgsql
directory gets created when Postgres is installed, you will not find any
config files in it initially. In order to change the default PGDATA
(and/or PGPORT) values, you sill need to create appropriately named config
file that will look like this:
You don't need to set both values in it if you are changing only one
I hope this helps.
More information about the CentOS