Thread: psql: server closed the connection unexpetedly

psql: server closed the connection unexpetedly

From
Phil Thornhill
Date:
Hi,

I can't connect to a new installation of PostgreSQL 8.1 on a XP SP1 laptop.

Im trying to connect using psql in the laptop's command prompt. i keep
getting the following error message:

psql: server closed the connection unexplectedly
        this probably means the server terminated
        abnormally before or while processing the request


I can start & stop the postgresql service with no problems. and if i try
to connect while postgresql is not running i get the expected error:

psql: could not connect to server: Connection refused (0x0000274D/10061)
        Is the server running on host "???" and accepting
        TCP/IP connections on port 5432?


the laptop has a trendmicro firewall installed, but this is set to allow
all connections from the localhost. plus i have other XP machines with
the same setup and postgresql installation working perfectly.

has anyone else ever come across the problem? or any suggestions as to
what the problem may be?

thanks in advance

phil..






Re: psql: server closed the connection unexpetedly

From
Sean Davis
Date:
On 8/24/05 7:24 AM, "Phil Thornhill" <phil@roadrunner.uk.com> wrote:

>
> Hi,
>
> I can't connect to a new installation of PostgreSQL 8.1 on a XP SP1 laptop.
>
> Im trying to connect using psql in the laptop's command prompt. i keep
> getting the following error message:
>
> psql: server closed the connection unexplectedly
>       this probably means the server terminated
>       abnormally before or while processing the request
>
>
> I can start & stop the postgresql service with no problems. and if i try
> to connect while postgresql is not running i get the expected error:
>
> psql: could not connect to server: Connection refused (0x0000274D/10061)
>       Is the server running on host "???" and accepting
>       TCP/IP connections on port 5432?
>
>
> the laptop has a trendmicro firewall installed, but this is set to allow
> all connections from the localhost. plus i have other XP machines with
> the same setup and postgresql installation working perfectly.
>
> has anyone else ever come across the problem? or any suggestions as to
> what the problem may be?

I'm not sure what the problem is, but have you looked at the log file?
Also, you ARE running 8.1 (which isn't even in Beta testing yet)?

Sean


Re: psql: server closed the connection unexpetedly

From
Phil Thornhill
Date:
Sean Davis wrote:
On 8/24/05 7:24 AM, "Phil Thornhill" <phil@roadrunner.uk.com> wrote:
 
Hi,

I can't connect to a new installation of PostgreSQL 8.1 on a XP SP1 laptop.

Im trying to connect using psql in the laptop's command prompt. i keep
getting the following error message:

psql: server closed the connection unexplectedly     this probably means the server terminated     abnormally before or while processing the request


I can start & stop the postgresql service with no problems. and if i try
to connect while postgresql is not running i get the expected error:

psql: could not connect to server: Connection refused (0x0000274D/10061)     Is the server running on host "???" and accepting     TCP/IP connections on port 5432?


the laptop has a trendmicro firewall installed, but this is set to allow
all connections from the localhost. plus i have other XP machines with
the same setup and postgresql installation working perfectly.

has anyone else ever come across the problem? or any suggestions as to
what the problem may be?   
I'm not sure what the problem is, but have you looked at the log file?
Also, you ARE running 8.1 (which isn't even in Beta testing yet)?

Sean
 
my apologies i'm using 8.0.1

I have had a look at the XP event Viewer , but that only has entries regarding the installation process.

where else should i be looking and should i be changing anything in the postgresql.conf file to ensure connection attempts are logged?

thanks

phil..

Re: psql: server closed the connection unexpetedly

From
Tom Lane
Date:
Phil Thornhill <phil@roadrunner.uk.com> writes:
> psql: could not connect to server: Connection refused (0x0000274D/10061)
>         Is the server running on host "???" and accepting
>         TCP/IP connections on port 5432?

> the laptop has a trendmicro firewall installed, but this is set to allow
> all connections from the localhost. plus i have other XP machines with
> the same setup and postgresql installation working perfectly.

"Connection refused" is a kernel-level rejection, so I'd say the
firewall setup is probably to blame.  Better double-check it.

            regards, tom lane