Re: can't createdb with my new user

From: "Usama Dar" <munir(dot)usama(at)gmail(dot)com>
To: della <ildella(at)gmail(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: can't createdb with my new user
Date: 2007-11-30 09:26:57
Message-ID: ff0e67090711300126v78c4a5b1u39136c3231290fc3@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 11/28/07, della <ildella(at)gmail(dot)com> wrote:
>
> hi, I describe my steps:
>
> 1. installed postgresql 8.2 via apt-get (ubuntu gutsy)
> 2. # sudo -u postgres psql template1
> 3. template1=# CREATE ROLE kokomo WITH LOGIN CREATEDB PASSWORD
> 'kokomo';
> 4. template1=# \q
> 5. # createdb kokomo_dev -U kokomo -W
>
> Here I receive:
> createdb: could not connect to database postgres: FATAL: Ident
> authentication failed for user "kokomo"
>
> So, given that I do not fail submitting the password for kokomo when
> requested... what could be the problem? Have I to create a system user
> for kokomo?
> If I use pgadmin3 I see the kokomo user with it own encrypted password
> and I can create the DB with kokomo as a owner. So what am I missing
> in the command line?
>
> Thanks for help.

Looks like you have a Database user kokomo but since your authentication
method in pg_hba.conf is set to ident, which means database user is mapped
to an OS user, and you need to be logged in as that OS user on which a DB
user is mapped. By default the mapping is on "sameuser" which means inorder
to logon as kokomo db user you will have to be authenticated /logged in as
kokomo OS user.

Change the pg_hba.conf auth method to trust or password

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

--
Usama Munir Dar http://linkedin.com/in/usamadar
Consultant Architect
Cell:+92 321 5020666
Skype: usamadar

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Usama Dar 2007-11-30 09:29:54 Re: Threads limit for postmaster
Previous Message Brendan Jurd 2007-11-30 09:14:14 Re: [GENERAL] Empty arrays with ARRAY[]