Re: JDBC connection problem

From: "Brian Tomaszewski" <brianbanjo(at)gmail(dot)com>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "Dave Cramer" <pg(at)fastcrypt(dot)com>, "Guy Rouillier" <guyr-ml1(at)burntmail(dot)com>, pgsql-jdbc(at)postgresql(dot)org
Subject: Re: JDBC connection problem
Date: 2008-02-05 21:21:50
Message-ID: 4df751bf0802051321l9ce663dm18590c9c7409fb9c@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

All,

Thanks for the time and tips. Turned out to be a really stupid error - there
was on old version of postres on the server that had taken port 5432, and my
app was trying to connect to it (hence why the database wasn't being found),
when it should have been connecting to the correct, newer instance of
postres

I found this out by doing this command as Tom recommended:

$ psql -h localhost -l
psql: could not connect to server: Connection refused
Is the server running on host "localhost" and accepting
TCP/IP connections on port 5433?

And noticing the 5433...

A colleague of mine also noticed the multiple ports, and we now have things
cleared up.

Thanks again everyone for the replies/comments

Brian

On Feb 5, 2008 12:27 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:

> "Brian Tomaszewski" <brianbanjo(at)gmail(dot)com> writes:
> > Does "it" refer to the postgres server? if so, how do I check that it is
> > listening on a TCPIP port? (sorry if this sounds trivial, I am
> relatively
> > new to postgres on linux)
>
> try psql -h localhost -l
>
> regards, tom lane
>

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Arie Ozarov 2008-02-05 21:42:36 Performance comparison to psql.
Previous Message Tom Lane 2008-02-05 17:27:46 Re: JDBC connection problem