installing Postgres

Brandon Allbery allbery.b at
Tue Sep 13 14:18:06 PDT 2011

On Tue, Sep 13, 2011 at 17:07, Brandon Allbery <allbery.b at> wrote:

> On Tue, Sep 13, 2011 at 16:59, Puneet Kishor <punk.kish at> wrote:
>> $sudo su postgres -c '/opt/local/lib/postgresql90/bin/pg_ctl start -D
>> /path/to/db/postgresql90/defaultdb -l ~/Logs/postgresql90-server/main.log'
>> but, I don't know the password for the 'postgres' user
> Are you using the actual command you quoted?  The "sudo" shifts to root,
> which doesn't need a password to "su postgres".

Oh, the "$" isn't part of the command; if you're typing it, then the shell
is trying to expand a variable called "sudo" that is probably empty, so
you'd get the password prompt.

    sudo su postgres -c '/opt/local/lib/postgresql90/bin/pg_ctl start -D
/path/to/db/postgresql90/defaultdb -l ~/Logs/postgresql90-server/main.log'

(all on one line)

brandon s allbery                                      allbery.b at
wandering unix systems administrator (available)     (412) 475-9364 vm/sms
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the macports-users mailing list