pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedPostgreSQl newbie! -PLease help, pgAdmin3 on Debian!
8+ messages / 3 participants
[nested] [flat]
* PostgreSQl newbie! -PLease help, pgAdmin3 on Debian!
@ 2006-03-28 07:08 lmyho <lm_yho@yahoo.com>
2006-03-28 13:00 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Richard Broersma Jr <rabroersma@yahoo.com>
0 siblings, 1 reply; 8+ messages in thread
From: lmyho @ 2006-03-28 07:08 UTC (permalink / raw)
To: pgsql-admin
Dear All,
I am totally new to the PostgreSQL. I just installed the PostgreSQL and pgAdmin3 on my Debian system, using the apt-get install command. Apparently, the initial database and the user "postgres" have also been automatically created during the installation.
It seems good. But I got big trouble to login to this initial db by using this auto-created username "postgres" through pgAdmin!!:((( The first time failed due to "Ident authentication failed", then follow the suggestion on the pop-up window of pgAdmin, I changed the ident method in the pg_hda.conf file all to md5, then the database ask me for the password!! I couldn't figure out the passwd so I tried to created rules in the pg_ident.conf file to map both the ordinary user and root user to postgres, then tried again. But still, failed again by "ident authentication failed"!!!:((( I've tried many times for all I could think, everytime failed, so frustrated:((( Everytime I did "pg_ctl reload" before trying, and I could see the failure reason changed after I do reload.
Please can anyone help me here? I've been so frustrated.:( If there is auto-created password for this auto-created postgres user, please anyone tell me what it is?? And also otherwise, how can I login using the "ident auth" method??
Any help would be greatly appreciated!!! Thank you so much for help!!!
leo
---------------------------------
Talk is cheap. Use Yahoo! Messenger to make PC-to-Phone calls. Great rates starting at 1¢/min.
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian!
2006-03-28 07:08 PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
@ 2006-03-28 13:00 ` Richard Broersma Jr <rabroersma@yahoo.com>
2006-03-28 17:41 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
0 siblings, 1 reply; 8+ messages in thread
From: Richard Broersma Jr @ 2006-03-28 13:00 UTC (permalink / raw)
To: lmyho <lm_yho@yahoo.com>; pgsql-admin
Please can anyone help me here? I've been so frustrated.:( If there is auto-created password
> for this auto-created postgres user, please anyone tell me what it is?? And also otherwise, how
> can I log-in using the "ident auth" method??
If you just getting started with postgresql you will want to change the user postgres ident to
"trust".
Then you should be able to log into postgresql using "psql -U postgres -d template1"
There you can change the postgres db-user password with
alter user postgres password 'password';
once completed then log out using "\q"
Now if you wanted to change you ident method back to md5 you will be able to use you new password.
This should work, but you would probably be better server by following the directions in the
postgresql documentation.
Regards,
Richard Broersma Jr.
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian!
2006-03-28 07:08 PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
2006-03-28 13:00 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Richard Broersma Jr <rabroersma@yahoo.com>
@ 2006-03-28 17:41 ` lmyho <lm_yho@yahoo.com>
2006-03-28 18:21 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Richard Broersma Jr <rabroersma@yahoo.com>
0 siblings, 1 reply; 8+ messages in thread
From: lmyho @ 2006-03-28 17:41 UTC (permalink / raw)
To: Richard Broersma Jr <rabroersma@yahoo.com>; pgsql-admin
Hi Rich,
Thank you very much!! Have some further question:
> Please can anyone help me here? I've been so frustrated.:( If there is
> auto-created password
> > for this auto-created postgres user, please anyone tell me what it is?? And
> also otherwise, how
> > can I log-in using the "ident auth" method??
>
> If you just getting started with postgresql you will want to change the user
> postgres ident to
> "trust".
How should I do this? The current auto-generated pg_hba.conf file read as:
"local all postgres ident sameuser"
on the first line, and the first line also after the # TYPE DATABASE....METHOD line.
Do you mean I should change the "ident sameuser" at the end to "trust"?
>
> Then you should be able to log into postgresql using "psql -U postgres -d
> template1"
Should I login by this way from command line?
THANK YOU!!
leo
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian!
2006-03-28 07:08 PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
2006-03-28 13:00 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Richard Broersma Jr <rabroersma@yahoo.com>
2006-03-28 17:41 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
@ 2006-03-28 18:21 ` Richard Broersma Jr <rabroersma@yahoo.com>
2006-03-28 22:51 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
0 siblings, 1 reply; 8+ messages in thread
From: Richard Broersma Jr @ 2006-03-28 18:21 UTC (permalink / raw)
To: lmyho <lm_yho@yahoo.com>; pgsql-admin
> How should I do this? The current auto-generated pg_hba.conf file read as:
> "local all postgres ident sameuser"
> on the first line, and the first line also after the # TYPE DATABASE....METHOD line.
>
>
> Do you mean I should change the "ident sameuser" at the end to "trust"?
Below is a snippet from:
http://www.postgresql.org/docs/8.0/static/client-authentication.html#EXAMPLE-PG-HBA.CONF
Some examples of pg_hba.conf entries are shown in Example 19-1. See the next section for details
on the different authentication methods.
Example 19-1. Example pg_hba.conf entries
# Allow any user on the local system to connect to any database under
# any user name using Unix-domain sockets (the default for local
# connections).
#
# TYPE DATABASE USER CIDR-ADDRESS METHOD
local all postgres trust
The above line will allow you to connect from the command line of your postgresql server. This
will get you started. I can't remember what type of connect pgadmin uses. It might be "TYPE"
host. If it is you will need to add another line to the conf file for that type. Also, there
is another postgres conf (I can't remember which on off the top of my head) file that will need
the optional "-I" set to allow you to connect from remote IP addresses. i.e. pgadmin. If all
else fails, read the help docs; the beginning sections are newbie friendly.
> Should I login by this way from command line?
yes
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian!
2006-03-28 07:08 PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
2006-03-28 13:00 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Richard Broersma Jr <rabroersma@yahoo.com>
2006-03-28 17:41 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
2006-03-28 18:21 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Richard Broersma Jr <rabroersma@yahoo.com>
@ 2006-03-28 22:51 ` lmyho <lm_yho@yahoo.com>
2006-03-28 23:54 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Chris Travers <chris@travelamericas.com>
0 siblings, 1 reply; 8+ messages in thread
From: lmyho @ 2006-03-28 22:51 UTC (permalink / raw)
To: Richard Broersma Jr <rabroersma@yahoo.com>; pgsql-admin
> > How should I do this? The current auto-generated pg_hba.conf file read as:
> > "local all postgres ident sameuser"
> > on the first line, and the first line also after the # TYPE DATABASE....METHOD
> line.
> >
> >
> > Do you mean I should change the "ident sameuser" at the end to "trust"?
>
> Below is a snippet from:
>
>
http://www.postgresql.org/docs/8.0/static/client-authentication.html#EXAMPLE-PG-HBA.CONF
>
> Some examples of pg_hba.conf entries are shown in Example 19-1. See the next
> section for details on the different authentication methods.
>
Thank you Richard!! I've made the changes and can login to the DBs through pgAdmin
now!:) Really appreciated your help!!! I am starting to learn about the postgresql
now.:))
>I can't remember what type of connect pgadmin uses. It might be "TYPE" host.
>If it is you will need to add another line to the conf file for that type.
Seems like the pgAdmin3 uses also the Unix socket pipe. I left only the first line
in the pg_hba.conf enabled as "local all postgres trust" and pgAdmin3 was able to
login.:)
> Also, there
> is another postgres conf (I can't remember which on off the top of my head) file
> that will need the optional "-I" set to allow you to connect from remote IP
> addresses. i.e. pgadmin. If all else fails, read the help docs; the beginning
sections are newbie friendly.
>
I am checking on this.;) If you got any more hints, please let me know. THANK
YOU!!!
leo
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian!
2006-03-28 07:08 PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
2006-03-28 13:00 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Richard Broersma Jr <rabroersma@yahoo.com>
2006-03-28 17:41 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
2006-03-28 18:21 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Richard Broersma Jr <rabroersma@yahoo.com>
2006-03-28 22:51 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
@ 2006-03-28 23:54 ` Chris Travers <chris@travelamericas.com>
2006-03-29 00:39 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
0 siblings, 1 reply; 8+ messages in thread
From: Chris Travers @ 2006-03-28 23:54 UTC (permalink / raw)
To: lmyho <lm_yho@yahoo.com>; +Cc: Richard Broersma Jr <rabroersma@yahoo.com>; pgsql-admin
lmyho wrote:
>
>
>>Some examples of pg_hba.conf entries are shown in Example 19-1. See the next
>>section for details on the different authentication methods.
>>
>>
>>
>Thank you Richard!! I've made the changes and can login to the DBs through pgAdmin
>now!:) Really appreciated your help!!! I am starting to learn about the postgresql
>now.:))
>
>
The authentication methods are handled between the libraries (libpq and
libpxx) and the server. They are transparent to the application.
identd sameuser means use the identd service to require look up the
owner of the process and log him/her in accordingly. This means that
you cannot change your login name but don't require a password (if you
are on the DB server-- do not trust it remotely).
For remote connections kerberos can be used instead, though this takes
more setup and knowledge of Kerberos as a system.
>
>
>>I can't remember what type of connect pgadmin uses. It might be "TYPE" host.
>>If it is you will need to add another line to the conf file for that type.
>>
>>
>Seems like the pgAdmin3 uses also the Unix socket pipe. I left only the first line
>in the pg_hba.conf enabled as "local all postgres trust" and pgAdmin3 was able to
>login.:)
>
>
Right. But passwords are ineffective with trust authentication. If you
need them you will need to use password, md5, or the like instead.
Best Wishes,
Chris Travers
Metatron Technology Consulting
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian!
2006-03-28 07:08 PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
2006-03-28 13:00 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Richard Broersma Jr <rabroersma@yahoo.com>
2006-03-28 17:41 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
2006-03-28 18:21 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Richard Broersma Jr <rabroersma@yahoo.com>
2006-03-28 22:51 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
2006-03-28 23:54 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Chris Travers <chris@travelamericas.com>
@ 2006-03-29 00:39 ` lmyho <lm_yho@yahoo.com>
2006-03-29 02:55 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Chris Travers <chris@travelamericas.com>
0 siblings, 1 reply; 8+ messages in thread
From: lmyho @ 2006-03-29 00:39 UTC (permalink / raw)
To: Chris Travers <chris@travelamericas.com>; +Cc: pgsql-admin
> >
> >
> >>Some examples of pg_hba.conf entries are shown in Example 19-1. See the next
> >>section for details on the different authentication methods.
> >>
> >
> The authentication methods are handled between the libraries (libpq and
> libpxx) and the server. They are transparent to the application.
>
> identd sameuser means use the identd service to require look up the
> owner of the process and log him/her in accordingly. This means that
> you cannot change your login name but don't require a password (if you
> are on the DB server-- do not trust it remotely).
>
> For remote connections kerberos can be used instead, though this takes
> more setup and knowledge of Kerberos as a system.
>
Really thank you Chris!! I really don't know these.:( Forgot what I tried last
night, but I ke[t using user postgres to try everytime as I was trying to login as
an admin user. So here you mean actually with the "ident sameuser", the other
username can also login if the access is issued from the user's own process? (not
sure how should I state it correctly, but hope you know what I mean):
> >
> >>I can't remember what type of connect pgadmin uses. It might be "TYPE" host.
> >>If it is you will need to add another line to the conf file for that type.
> >>
> >>
> >Seems like the pgAdmin3 uses also the Unix socket pipe. I left only the first
> >line in the pg_hba.conf enabled as "local all postgres trust" and pgAdmin3
> >was able to login.:)
> >
> >
> Right. But passwords are ineffective with trust authentication.
Thank you for this knowledge too!! So appreciated! otherwise I may end up with my
trust and passwd setting and going to real work!:( wish the doc mentioned it as
well.
Very kind regards,
leo
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian!
2006-03-28 07:08 PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
2006-03-28 13:00 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Richard Broersma Jr <rabroersma@yahoo.com>
2006-03-28 17:41 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
2006-03-28 18:21 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Richard Broersma Jr <rabroersma@yahoo.com>
2006-03-28 22:51 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
2006-03-28 23:54 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! Chris Travers <chris@travelamericas.com>
2006-03-29 00:39 ` Re: PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
@ 2006-03-29 02:55 ` Chris Travers <chris@travelamericas.com>
0 siblings, 0 replies; 8+ messages in thread
From: Chris Travers @ 2006-03-29 02:55 UTC (permalink / raw)
To: lmyho <lm_yho@yahoo.com>; +Cc: Chris Travers <chris@travelamericas.com>; pgsql-admin
lmyho wrote:
>>>
>>>
>>>
>>>
>>>>Some examples of pg_hba.conf entries are shown in Example 19-1. See the next
>>>>section for details on the different authentication methods.
>>>>
>>>>
>>>>
>>The authentication methods are handled between the libraries (libpq and
>>libpxx) and the server. They are transparent to the application.
>>
>>identd sameuser means use the identd service to require look up the
>>owner of the process and log him/her in accordingly. This means that
>>you cannot change your login name but don't require a password (if you
>>are on the DB server-- do not trust it remotely).
>>
>>For remote connections kerberos can be used instead, though this takes
>>more setup and knowledge of Kerberos as a system.
>>
>>
>>
>Really thank you Chris!! I really don't know these.:( Forgot what I tried last
>night, but I ke[t using user postgres to try everytime as I was trying to login as
>an admin user. So here you mean actually with the "ident sameuser", the other
>username can also login if the access is issued from the user's own process? (not
>sure how should I state it correctly, but hope you know what I mean):
>
>
Perhaps I wasn't clear.
With identd authentication a username is still specified. But you have
to own the process to login with that username. So generally speaking
(absent sudo and the like) you can generally login only with the same
username as your OS username.
The documentation of PostgreSQL goes into a bit of depth on
authentication, but if you want a little bit to get started, you might
find the following article helpful:
http://www.metatrontech.com/sql-ledger-wiki/index.php?UnderstandingPostgreSQLAuthentication
Best Wishes,
Chris Travers
Metatron Technology Consulting
^ permalink raw reply [nested|flat] 8+ messages in thread
end of thread, other threads:[~2006-03-29 02:55 UTC | newest]
Thread overview: 8+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2006-03-28 07:08 PostgreSQl newbie! -PLease help, pgAdmin3 on Debian! lmyho <lm_yho@yahoo.com>
2006-03-28 13:00 ` Richard Broersma Jr <rabroersma@yahoo.com>
2006-03-28 17:41 ` lmyho <lm_yho@yahoo.com>
2006-03-28 18:21 ` Richard Broersma Jr <rabroersma@yahoo.com>
2006-03-28 22:51 ` lmyho <lm_yho@yahoo.com>
2006-03-28 23:54 ` Chris Travers <chris@travelamericas.com>
2006-03-29 00:39 ` lmyho <lm_yho@yahoo.com>
2006-03-29 02:55 ` Chris Travers <chris@travelamericas.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox