From: | "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at> |
---|---|
To: | "Yvon Thoraval *EXTERN*" <yvon(dot)thoraval(at)gmail(dot)com>, <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: SQLSTATE[08006] [7] server closed the connection unexpectedly |
Date: | 2012-09-14 13:22:02 |
Message-ID: | D960CB61B694CF459DCFB4B0128514C2086C162D@exadv11.host.magwien.gv.at |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Yvon Thoraval wrote:
> I do have a strange probleme when connecting to a database thru php using PDO.
> When connecting to the php script thru a browser i get the following error :
> HTTP 500 (Internal Server Error)
>
>
> Not really informative, then i've tried the php script thru Command Line where i get :
> yt(at)D620 /home/yt/Sites/yt_tests $ php index.php
> PHP Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[08006] [7] server closed
> the connection unexpectedly
> This probably means the server terminated abnormally
> before or while processing the request.' in /home/yt/Sites/yt_tests/index.php:75
> Stack trace:
> #0 /home/yt/Sites/yt_tests/index.php(75): PDO->__construct('pgsql:dbname=yt...', 'yt', 'yvon5533')
> #1 {main}
> thrown in /home/yt/Sites/yt_tests/index.php on line 75
> zsh: exit 255 php index.php
>
>
> Line 75 being :
> $db = new PDO("pgsql:dbname=$dbname;host=$host;", $username, $password );
>
> I should say i do NOT have any prob when connecting directly to this database using :
> $ psql -h <IPV4 or IPV6 of the PostgreSQL server> -U yt -d yt_tests
>
> I'm stuck, i don't see any way to debugg that prob.
Is this repeatable?
That message normally means that the server process crashed.
What is in the PostgreSQL server log file?
You may want to set log_statement='all' in postgresql.conf
to get more context.
Yours,
Laurenz Albe
From | Date | Subject | |
---|---|---|---|
Next Message | xoip | 2012-09-14 13:34:13 | How to access the extension's operator installed with schema ? |
Previous Message | Merlin Moncure | 2012-09-14 13:10:59 | Re: Performance of pl/pgsql functions? |