Autostart PostgreSQL in Ubuntu

From: Johann Maar <johann(dot)maar(at)gmx(dot)net>
To: pgsql-general(at)postgresql(dot)org
Subject: Autostart PostgreSQL in Ubuntu
Date: 2007-09-26 06:46:12
Message-ID: 1190789172.265507.67720@k79g2000hse.googlegroups.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi folks,

sorry I do not get it right and I have to ask now.

I manually compiled PostgreSQL on my Kubuntu machine to /usr/local/opt/
pgsql and did all this stuff like creating a "postgres" user and I
have a startup script in /etc/init.d.
But if I try to start PostgreSQL by running "sudo /etc/init.d/
postgresql start" it will fail because it tries to write a PID file to
"/var/run/postgresql" which does not exist. If I create this directory
and set the permissions for postgres to write it works (!), but after
the next restart of the machine the directory is already gone. I tried
to change the location of the PID target directory in postgresql.conf,
but then clients like psql still try to find the PID file in /var/run/
postgresql and fail.

What is a good solution for this problem? It also seems that the
postgres user won't ever have permissions to write to /var/run so does
anybody know how to solve this?

With best regards,

Sebastian

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Bruce Momjian 2007-09-26 08:42:07 Re: PQntuples return type
Previous Message David Fetter 2007-09-26 05:39:05 Re: Why the ERROR: duplicate key violates unique constraint "master_pkey" is raised? - Is this a Bug?