Re: pgsql initial superuser - Mailing list pgsql-admin

From Gémes Géza
Subject Re: pgsql initial superuser
Date
Msg-id 40311E87.4090701@kzsdabas.sulinet.hu
Whole thread Raw
In response to Re: pgsql initial superuser  (Pedro Almeida <niker@netvisao.pt>)
List pgsql-admin
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Pedro Almeida írta:
| kaolin fire wrote:
|
|> try user 'pgsql' :) that's the default initially created superuser, no
|> password (it would be good to give it one).
|>
|> -kaolin fire
|> -http://erif.org/code/fallingup/ for a 'spin' on tetris
|>
|>
| That was a quick response :-)
|
| using a clean pg_hba.conf file (no user lines added), this is what
| happened:
|
| *******
| ~# createuser -Upgsql
| Enter name of user to add: blabla
| Shall the new user be allowed to create databases? (y/n) n
| Shall the new user be allowed to create more new users? (y/n) n
| psql: FATAL:  IDENT authentication failed for user "pgsql"
|
| createuser: creation of user "blabla" failed
| *******
|
| What am I doing wrong ?
|
| ---------------------------(end of broadcast)---------------------------
| TIP 9: the planner will ignore your desire to choose an index scan if your
|      joining column's datatypes do not match

Add a line:
local  all     all     ident   sameuser
to your pg_hba.conf
restart postgresql
find out under what userid is your postgresql running typicaly it would
be postgres, I'll supose that it is postgres:
su postgres
and do whatever you like with your database cluster.
Because of this I would suggest as a first step to do:
psql template1
SQL commands follow:
ALTER USER postgres password='SomeReallyBigSecretHere' ;

Hope it helps.

Cheers,

Geza
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFAMR6G/PxuIn+i1pIRAoaAAKCBALjM0r1nQ3K8anMwrDh/BGscOgCggs18
V+YlMMBEGys7jd7LzfV5M0Y=
=udMf
-----END PGP SIGNATURE-----


pgsql-admin by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: pgsql initial superuser
Next
From: Pedro Almeida
Date:
Subject: Re: pgsql initial superuser