Re: changing user id - Mailing list pgsql-novice

From Mark Kelly
Subject Re: changing user id
Date
Msg-id 200605300630.34826.pgsql@wastedtimes.net
Whole thread Raw
In response to Re: changing user id  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: changing user id
List pgsql-novice
On Tuesday 30 May 2006 03:57, Tom Lane wrote:
> Russell Davie <rjrd@exemail.com.au> writes:

> > hope this is the right list to ask this question...

You might have been better off on the Ubuntu list, but it's one of those
questions that could go either way :)

Here it is, in case you want to join up:
http://www.ubuntu.com/community/lists

> > postgres@XXXXX:~$ /etc/init.d/postgresql-7.4 start
> > chmod: changing permissions of `/var/run/postgresql': Operation not
> > permitted * Starting PostgreSQL 7.4 database server:main
> > Error: Could not change user id
> > [fail]
>
> init scripts generally expect to be launched as root.  Perhaps
>  sudo /etc/init.d/postgresql-7.4 start

That should fix the error above, as long as you run it from a user account
that is in the sudoers file (which the user postgres isn't on Ubuntu). Your
main user account will be.

> would work better.  Actually, I believe that on modern systems
> you're not really supposed to invoke an init script directly like
> that at all, but instead through the "service" program;

"service" is not part of the vanilla Ubuntu install (I've only seen it on
redhat-based systems). The first suggestion you made is the right one for
Ubuntu.

HTH

Mark


pgsql-novice by date:

Previous
From: Tom Lane
Date:
Subject: Re: changing user id
Next
From: Russell Davie
Date:
Subject: Re: changing user id