Re: pl/perl error

From: Frank <archon(at)forbidden(dot)dough(dot)net>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: pl/perl error
Date: 2006-04-09 22:58:20
Message-ID: 20060409225820.GA99804@forbidden.dough.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Sun, Apr 09, 2006 at 06:22:40PM -0400, Tom Lane wrote:
> Frank <archon(at)forbidden(dot)dough(dot)net> writes:
> > I have a perl script running as a daemon. It's using DBD::Pg (1.43) to
> > connect to my Postgres server (8.0.7) running on the same box and talking
> > over a socket. When I start the server, it runs fine for about a day, and
> > then at some point I start getting this error repeatedly:
>
> > DBD::Pg::db do failed: server closed the connection unexpectedly
> > This probably means the server terminated abnormally
> > before or while processing the request.
>
> Do you see any complaint in the postmaster log when this happens? If so
> what?
>
> I'd personally wonder about a memory leak or something like that in your
> trigger functions.
>
> regards, tom lane
>

After running with debugging at level 2, I saw that the script died at
00:57:35. Attached is the log from that time. I noticed specifically the
following lines:

Apr 9 00:57:35 MYSERVER postgres[7881]: [511892-1] LOG: disconnection: session time: 9:33:45.60 user=dbuser database=mydb host=[local] port=
Apr 9 00:57:35 MYSERVER postgres[7874]: [13-1] DEBUG: server process (PID 7881) exited with exit code 0
Apr 9 00:57:35 MYSERVER postgres[7874]: [14-1] DEBUG: forked new backend, pid=10009 socket=7

I don't see those lines at all before the problems begin, but I notice them
very often afterwards. Would I see the memory leak in the postgres
footprint? I will attempt to monitor the server's memory usage. Any other
debugging tips?

Thanks,
Frank

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Michael Glaesemann 2006-04-10 00:49:35 Re: advice on schema for multilingual text
Previous Message Tom Lane 2006-04-09 22:22:40 Re: pl/perl error