Re: bug on starting postgres

Lists: pgsql-bugs
From: "Puvi Subramanian" <puveee(at)rediffmail(dot)com>
To: pgsql-bugs(at)postgresql(dot)org
Subject: bug on starting postgres
Date: 2005-09-13 06:24:20
Message-ID: 20050913062420.8605.qmail@webmail18.rediffmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-bugs


Hi,

we installed postgres 8.0.3 in fedora core 4 successfully. We created the super user named as postgres to start postgres. When i execute the command "/usr/local/pgsql/bin/postmaster -i -D data" in my terminal it gives bur that
postmaster cannot access the server configuration file "/home/postgres/data/postgresql.conf": No such file or directory

plz help us to proceed further

with regards
Puvi.S


From: John R Pierce <pierce(at)hogranch(dot)com>
To: Puvi Subramanian <puveee(at)rediffmail(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: bug on starting postgres
Date: 2005-09-15 03:34:01
Message-ID: 4328EBA9.4070007@hogranch.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-bugs

Puvi Subramanian wrote:

>
> Hi,
>
> we installed postgres 8.0.3 in fedora core 4 successfully. We
> created the super user named as postgres to start postgres. When i
> execute the command "/usr/local/pgsql/bin/postmaster -i -D data" in
> my terminal it gives bur that
> postmaster cannot access the server configuration file
> "/home/postgres/data/postgresql.conf": No such file or directory
>
> plz help us to proceed further
>

if your pgsql directory is /usr/local/pgsql, chances are, the default
data directory is in /usr/local/pgsql/data ...

But, since you're running Fedora, and that uses SysVinit routines, look
in /usr/local/pgsql/postgresql-(version)/contrib/start-scripts and you
should find a script `linux` there.... as root, copy this to
/etc/init.d/postgresql and chmod that +x then still as root, do
`chkconfig postgresql --add`

now, you can start/stop postgres as root with `service postgresql start`
and `service postgresql stop`.. further, if you now do `chkconfig
postgresql on` it will autostart each time you reboot, running as a
system service.

if you really just want to run it manually, I'd consider changing the
postgres user account's home directory to /usr/local/pgsql rather than
/home/postgres... `usermod -d /usr/local/pgsql postgres`

regardless, you usually need to edit the postgresql.conf and pg_hba.conf
files to support the desired access types