Re: [GENERAL] postgres user account on OSX

2008-10-14 Thread Dave Page
On Tue, Oct 14, 2008 at 3:55 AM, Darren Weber
<[EMAIL PROTECTED]> wrote:
>
> Have you seen anything like this before?  I have no idea what this means:
> "CFPreferences: user home directory at /Library/PostgreSQL/8.3 is
> unavailable"
> It looks like a hangover from using a binary installer and I have no idea
> how to get rid of that "CFPreference".

% sudo dscl . delete /users/postgres

will delete the user account that the binary installer created. I
assume the MacPort will recreate it as it likes.

-- 
Dave Page
EnterpriseDB UK:   http://www.enterprisedb.com

-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] postgres user account on OSX

2008-10-13 Thread Darren Weber
Hi Shane,

I'm trying to untangle some postgresql issues on OSX.  I'm now using a
macport installation for postgresql 8.3.4 and I'm using my own custom
Portfile to configure the installation (hardly changed from the main
Portfile, really).  Anyhow, the macport install creates a lauchdeamon config
that uses this startup call below.  When I test it directly, it's failing:

sudo su postgres -c "/opt/local/lib/postgresql83/bin/pg_ctl -D
${POSTGRESQL83DATA:=/opt/local/var/db/postgresql83/defaultdb} start -w -l
/opt/local/var/log/postgresql83/postgres.log -o \"-i -l\""

waiting for server to start...2008-10-13 19:50:21.734 pg_ctl[43992:617]
CFPreferences: user home directory at /Library/PostgreSQL/8.3 is
unavailable. User domains will be volatile.
could not start
server

Have you seen anything like this before?  I have no idea what this means:
"CFPreferences: user home directory at /Library/PostgreSQL/8.3 is
unavailable"
It looks like a hangover from using a binary installer and I have no idea
how to get rid of that "CFPreference".

Any tips much appreciated ;-)

Thanks, Darren



On Fri, Sep 12, 2008 at 8:52 AM, Shane Ambler <[EMAIL PROTECTED]> wrote:

> Darren Weber wrote:
>
>  If you want a GUI to alter the home location of the existing user
>>> account run NetInfo Manager which is in /Applications/Utilities
>>>
>>
>>
>> I have OSX Server.  This user account doesn't appear in the usual System
>> Preferences > Accounts.  I did find it eventually under Applications >
>> Server > Workgroup Manager, when I selected a "local" domain to administer.
>>
>>
> That would be a 10.5 machine.
>
> Seems Apple has dropped netinfo manager in 10.5 and replacing it with
> Directory and Directory Utility. (Data storage has changed too)
>
> Workgroup Manager is a OSX Server app that isn't a standard part of the
> client installs (but can be added by installing the server admin tools)
> and (pretty sure) it will only connect to an OSX Server to administer it
> - not useful for adjusting a client machine.
> You could call it a more user friendly form of netinfo manager (edits
> the same data)
>
>
>
> System Preferences > Accounts will only list accounts normally created
> within the Accounts Tab (I believe the criteria is userid's > 500) which
> makes it easy for the novice user as they don't get to see all the
> system accounts like mailman, nobody, postmaster and so on, just the
> ones they have manually created.
>
>
> --
>
> Shane Ambler
> pgSQL (at) Sheeky (dot) Biz
>
> Get Sheeky @ http://Sheeky.Biz
>


Re: [GENERAL] postgres user account on OSX

2008-09-11 Thread Dave Page
On Thu, Sep 11, 2008 at 3:53 AM, Shane Ambler <[EMAIL PROTECTED]> wrote:
> Tom Lane wrote:
>>
>> "Darren Weber" <[EMAIL PROTECTED]> writes:
>>>
>>> There is a postgres user account on my OSX system.  I'm not clear
>>> about how it was created.  I've installed a binary version of 8.3 in
>>> /Library/PostgreSQL/8.3/ and built another version from source into
>>> /usr/local/pgsql/.  When I login as root and then 'su - postgres' it
>>> takes me to the postgres account and the user directory is at
>>> /opt/local/var/db/postgresql83/.
>>
>>> Can someone explain how this user account was created?
>>
>> I'm guessing that binary package created it for you --- check its docs,
>> or look at the install script if you can.
>>
>
> Quite sure that the EDB binary installer sets /Library/PostgreSQL8 as the
> home path, matching the install location.

/Library/PostgreSQL/8.3 by default, but yes, that is essentially correct.

> The /opt/local/. home path would indicate that you used macports or
> similar at some stage and the install from there would have created it.
>
> As the postgres user existed the EDB installer would have left it as is.

Correct.

-- 
Dave Page
EnterpriseDB UK: http://www.enterprisedb.com

-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] postgres user account on OSX

2008-09-10 Thread kevin kempter
On Linux if you install postgres via RPM's and the postgres user  
account does not exist then the RPM install creates it for you and  
sets the home dir to the root for the postgres binaries (i.e. /var/lib/ 
pgsql)


Maybe the same thing happens on a Mac install ?


On Sep 10, 2008, at 5:14 PM, Darren Weber wrote:


There is a postgres user account on my OSX system.  I'm not clear
about how it was created.  I've installed a binary version of 8.3 in
/Library/PostgreSQL/8.3/ and built another version from source into
/usr/local/pgsql/.  When I login as root and then 'su - postgres' it
takes me to the postgres account and the user directory is at
/opt/local/var/db/postgresql83/.

Can someone explain how this user account was created?

I'm trying to start the server that I built from source but it will
not create a logfile, ie:

elegans:~ postgres$ /usr/local/pgsql/bin/pg_ctl -D
/usr/local/pgsql/data -l logfile start
server starting
sh: logfile: Permission denied
elegans:~ postgres$
elegans:~ postgres$ nohup /usr/local/pgsql/bin/postgres -D
/usr/local/pgsql/data >server.log 2>&1 http://www.postgresql.org/mailpref/pgsql-general




--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] postgres user account on OSX

2008-09-10 Thread Shane Ambler

Tom Lane wrote:

"Darren Weber" <[EMAIL PROTECTED]> writes:

There is a postgres user account on my OSX system.  I'm not clear
about how it was created.  I've installed a binary version of 8.3 in
/Library/PostgreSQL/8.3/ and built another version from source into
/usr/local/pgsql/.  When I login as root and then 'su - postgres' it
takes me to the postgres account and the user directory is at
/opt/local/var/db/postgresql83/.



Can someone explain how this user account was created?


I'm guessing that binary package created it for you --- check its docs,
or look at the install script if you can.



Quite sure that the EDB binary installer sets /Library/PostgreSQL8 as 
the home path, matching the install location.


The /opt/local/. home path would indicate that you used macports or 
similar at some stage and the install from there would have created it.


As the postgres user existed the EDB installer would have left it as is.

If you want a GUI to alter the home location of the existing user 
account run NetInfo Manager which is in /Applications/Utilities



--

Shane Ambler
pgSQL (at) Sheeky (dot) Biz

Get Sheeky @ http://Sheeky.Biz

--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] postgres user account on OSX

2008-09-10 Thread Tom Lane
"Darren Weber" <[EMAIL PROTECTED]> writes:
> There is a postgres user account on my OSX system.  I'm not clear
> about how it was created.  I've installed a binary version of 8.3 in
> /Library/PostgreSQL/8.3/ and built another version from source into
> /usr/local/pgsql/.  When I login as root and then 'su - postgres' it
> takes me to the postgres account and the user directory is at
> /opt/local/var/db/postgresql83/.

> Can someone explain how this user account was created?

I'm guessing that binary package created it for you --- check its docs,
or look at the install script if you can.

Apple includes a version of postgres in Remote Desktop, but last
I heard it was a lot older than 8.3 (7.3.x in fact :-(), and in any case
that's not where they put the database.  So I don't think that's what's
causing this.

> I'm trying to start the server that I built from source but it will
> not create a logfile, ie:

Well, that's cause you're trying to create the logfile in a root-owned
directory that you don't have write permission on.  Put the logfile
someplace you do have privileges for.  Or change the ownership of the
directory --- it definitely seems pretty weird/broken to give an account
a home directory it doesn't own.

> Should I remove this user somehow and replace it with a standard user
> (using the system admin GUI)?

You could do that too if you liked.  Postgres isn't picky about
what account it runs under, so long as it isn't root.  You just need to
be sure the ownership of the database files/directories matches.

regards, tom lane

-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] postgres user account on OSX

2008-09-10 Thread Darren Weber
There is a postgres user account on my OSX system.  I'm not clear
about how it was created.  I've installed a binary version of 8.3 in
/Library/PostgreSQL/8.3/ and built another version from source into
/usr/local/pgsql/.  When I login as root and then 'su - postgres' it
takes me to the postgres account and the user directory is at
/opt/local/var/db/postgresql83/.

Can someone explain how this user account was created?

I'm trying to start the server that I built from source but it will
not create a logfile, ie:

elegans:~ postgres$ /usr/local/pgsql/bin/pg_ctl -D
/usr/local/pgsql/data -l logfile start
server starting
sh: logfile: Permission denied
elegans:~ postgres$
elegans:~ postgres$ nohup /usr/local/pgsql/bin/postgres -D
/usr/local/pgsql/data >server.log 2>&1 http://www.postgresql.org/mailpref/pgsql-general