Обсуждение: Authentication Failed - new user installation

Поиск
Список
Период
Сортировка

Authentication Failed - new user installation

От
ray
Дата:
I have installed 8.2 on a Windows 2000 laptop.

I think it is installed.  From the pgAdmin, it shows "Servers (1)" and
it is named PostgreSQL Database Server 8.2 (localhost:5432).  Right
clicking for  says I can stop services or disconnect so I am guessing
that it is running.

Is that correct?

Under that, there is a Databases(1) folder with the component
"postgres".  Right clicking on it does not give a choice to start or
stop.  What is this telling me?

On the file menu, when I select "add server" and fill in the boxes, I
get an error message "An error has occurred:  Error connecting to the
server:  FATAL:  password authentication failed for user
myadminaccnt."

When I setup 8.3, I used my myadminaccnt password for the
installation, I used it again on the next request for a password.  So
I have used only it for all the requested passwords.

I don't know if this has any relationship, but when I installed 8.3, I
tried to use myadminaccnt as the user name but it said that was
missing a right so I elected to let 8.3 build a user "postgreadmin"
with the same password.

How can I go forward?  When I build this again on another machine, how
do I avoid this problem?

TIA,
Ray






Re: Authentication Failed - new user installation

От
Scott Mead
Дата:


On Sat, Mar 28, 2009 at 3:51 AM, ray <Ray.Joseph@cdicorp.com> wrote:
I have installed 8.2 on a Windows 2000 laptop.

I think it is installed.  From the pgAdmin, it shows "Servers (1)" and
it is named PostgreSQL Database Server 8.2 (localhost:5432).  Right
clicking for  says I can stop services or disconnect so I am guessing
that it is running.

Is that correct?

   That is correct.  If you saw a red 'X' over the icon next to " PostgreSQL Database Server 8.2 (localhost:5432)" then the server would be offline.



Under that, there is a Databases(1) folder with the component
"postgres".  Right clicking on it does not give a choice to start or
stop.  What is this telling me?

   Nothing :)  A server (aka database cluster) can be started or stopped.  Once started, a database server has multiple databases that you can connect to within it.  If you drill-down beyond the 'postgres' database, you will see 'schemas'.  Drill down further and you will see 'tables' etc...
 


On the file menu, when I select "add server" and fill in the boxes, I
get an error message "An error has occurred:  Error connecting to the
server:  FATAL:  password authentication failed for user
myadminaccnt."

  The username / password will not be the same as your windows logon.  It will be the postgres database username / password.


When I setup 8.3, I used my myadminaccnt password for the
installation, I used it again on the next request for a password.  So
I have used only it for all the requested passwords.

   Try the username 'postgres' when connecting to another server. 

 To be honest though, I don't think you need to do this, it sounds like you just need to drill further into the 'postgres' database in the tree.


I don't know if this has any relationship, but when I installed 8.3, I
tried to use myadminaccnt as the user name but it said that was
missing a right so I elected to let 8.3 build a user "postgreadmin"
with the same password.

 That is a user that was created in the operating system.

  Postgres has 2 types of users:

  *) OS user
     There is only one of these (in your case).  When postgres starts (look at the services control panel) it uses that windows logon to run the service.  Postgres cannot be run as a 'root' or 'admin' user for security reasons, so the installer creates a user for you.

*) Database users
   These are users inside the database cluster that have privileges on each table / object within the database.  These users can be named the same as OS users, but for all intensive purposes, are in no way releated to windows users.
 


How can I go forward?  When I build this again on another machine, how
do I avoid this problem?

  I'm not really sure you have a problem, just spend some more time clicking '+' signs in pgAdmin :)

--Scott
 


TIA,
Ray






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

Re: Authentication Failed - new user installation

От
Dave Page
Дата:
On Sat, Mar 28, 2009 at 4:21 PM, Scott Mead
<scott.lists@enterprisedb.com> wrote:
>
>
> On Sat, Mar 28, 2009 at 3:51 AM, ray <Ray.Joseph@cdicorp.com> wrote:
>>
>> I have installed 8.2 on a Windows 2000 laptop.
>>
>> I think it is installed.  From the pgAdmin, it shows "Servers (1)" and
>> it is named PostgreSQL Database Server 8.2 (localhost:5432).  Right
>> clicking for  says I can stop services or disconnect so I am guessing
>> that it is running.
>>
>> Is that correct?
>
>    That is correct.  If you saw a red 'X' over the icon next to " PostgreSQL
> Database Server 8.2 (localhost:5432)" then the server would be offline.

Err, no - a red cross means pgAdmin hasn't connected to that server
yet. For a windows server, on the local machine the presence of the
Stop Service option means it's running (it'll also have a 'Running'
value in the properties list). On other platforms it's a bit more
complex and depends on whether the user has configured service control
scripts for pgAdmin to use.


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

Re: Authentication Failed - new user installation

От
ray
Дата:
On Mar 28, 12:57 pm, dp...@pgadmin.org (Dave Page) wrote:
> On Sat, Mar 28, 2009 at 4:21 PM, Scott Mead
>
>
>
>
>
> <scott.li...@enterprisedb.com> wrote:
>
> > On Sat, Mar 28, 2009 at 3:51 AM, ray <Ray.Jos...@cdicorp.com> wrote:
>
> >> I have installed 8.2 on a Windows 2000 laptop.
>
> >> I think it is installed.  From the pgAdmin, it shows "Servers (1)" and
> >> it is named PostgreSQL Database Server 8.2 (localhost:5432).  Right
> >> clicking for  says I can stop services or disconnect so I am guessing
> >> that it is running.
>
> >> Is that correct?
>
> >    That is correct.  If you saw a red 'X' over the icon next to " PostgreSQL
> > Database Server 8.2 (localhost:5432)" then the server would be offline.
>
> Err, no - a red cross means pgAdmin hasn't connected to that server
> yet. For a windows server, on the local machine the presence of the
> Stop Service option means it's running (it'll also have a 'Running'
> value in the properties list). On other platforms it's a bit more
> complex and depends on whether the user has configured service control
> scripts for pgAdmin to use.
>
> --
> Dave Page
> EnterpriseDB UK:  http://www.enterprisedb.com

Thank you for all the input.  This is giving me a much better
understanding of the systems.

I found that if I logoff the OS as admin and logon as postgres, all
functionality is provided.  It looks like I just need to do my admin
work from the postgres account.

Ray