Failure to connect remotely to postgresql with JDBC

Поиск
Список
Период
Сортировка
От Kelvin SIN
Тема Failure to connect remotely to postgresql with JDBC
Дата
Msg-id Pine.GSO.3.95.980730001620.2860A-100000@cat.cs.mu.OZ.AU
обсуждение исходный текст
Ответы Re: [INTERFACES] Failure to connect remotely to postgresql with JDBC  (Peter T Mount <peter@retep.org.uk>)
Список pgsql-interfaces
Hi,

I am using Postgresql 6.3.2 running on a Sun Solaris. The interface I am
using is JDBC.

When I connect, I received the following error messages:

java.sql.SQLException: User authentication failed
        at postgresql.Connection.<init>(Connection.java:229)
        at postgresql.Driver.connect(Driver.java:87)
        at java.sql.DriverManager.getConnection(DriverManager.java:91)
        at java.sql.DriverManager.getConnection(DriverManager.java:134)
        at ConLayer.Select(ConLayer.java:149)
        at ConLayerTest.main(ConLayerTest.java:82)
java.lang.NullPointerException
        at ConLayer.Select(ConLayer.java:165)
        at ConLayerTest.main(ConLayerTest.java:82)

The url is:

jdbc:postgresql://holly.cs.mu.oz.au:5432/conlayer?user=me&password=abc&
auth=password

conlayer is the database name.

That is, the server is holly.cs.mu.oz.au and the port is 5432. postmaster
is definitely running on holly. The environment variables PGHOST has been
set to holly.cs.mu.oz.au and PGPORT has been set to 5432. PGLIB and
PGDATA has also been set correctly. The pg_hba.conf has been set to accept
all users from anywhere but this doesn't helps. Can someone please help?

Thanks in advance
Kelvin
------------------------------------------------------------------------------
When you are stuck at work, think of this:
"Do not worry about your mathematics difficulties.
I can assure you that mine are still greater." - Einstein
------------------------------------------------------------------------------
Kelvin Sin

University of Melbourne
BSc (Mathematics) / BE (Software) undergraduate

Project homepage: http://www.cs.mu.oz.au/SE-projects/440-team
Personal homepage: http://www.ecr.mu.oz.au/~ksin

Email:  ksin@ecr.mu.oz.au
        ksin@students.cs.mu.oz.au
------------------------------------------------------------------------------


В списке pgsql-interfaces по дате отправления:

Предыдущее
От: "Sergey V. Kryaczevskih"
Дата:
Сообщение: Re: [GENERAL] Old ODBC Driver references on website
Следующее
От: Tom Lane
Дата:
Сообщение: Re: [HACKERS] Coping with backend crash in libpq