Re: org.postgresql.util.PSQLException: An I/O error occured while sending to the backend

From: "Albretch Mueller" <lbrtchx(at)gmail(dot)com>
To: "Albe Laurenz *EXTERN*" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: org.postgresql.util.PSQLException: An I/O error occured while sending to the backend
Date: 2008-05-07 09:54:35
Message-ID: 9ef66fac0805070254w590c3e3crad0f7ea6031e5df2@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

OK this is what I got after making the changes you suggested to me:
~
// __
First I opened a window and run a little script in order to become the pguser:
~
#!/bin/bash

_G='web'
_PGDIR='/media/sda2/inst/sw/PG/8.3.1'
_USR='pgtest'

# creating pg user
groupadd $_G
adduser --quiet --home $_PGDIR --ingroup $_G --no-create-home
--disabled-password --disabled-login --shell "/bin/bash" $_USR
xhost local:$_USR # if you want to run x apps such as konqueror
su $_USR
~
sh-3.1# sh ./pgtest_user.sh
Changing the user information for pgtest
Enter the new value, or press ENTER for the default
Full Name []:
Room Number []:
Work Phone []:
Home Phone []:
Other []:
Is the information correct? [y/N] y
non-network local connections being added to access control list
pgtest(at)Knoppix:/media/sda2/inst/sw/PG$
~
// __
then I run the postmaster as pgtest user using another script and
tested that the table I set up was there (access was logged)
~
#!/bin/bash

_PGDATA='/media/sda2/inst/sw/PG/8.3.1/local/data'
_DATE=`date +%Y%m%d%H%M%S`
_LOGFL='/media/sda2/inst/sw/PG/8.3.1/local/logs/'$_DATE'_pg8.3.1.log'

postmaster -D $_PGDATA > $_LOGFL 2>&1 &
~
pgtest(at)Knoppix:~/bin$ sh ./pgpostmaster.sh
pgtest(at)Knoppix:~/bin$ ICE default IO error handler doing an exit(),
pid = 3911, errno = 0
pgtest(at)Knoppix:~/bin$ psql testdb
Welcome to psql 8.3.1, the PostgreSQL interactive terminal.

Type: \copyright for distribution terms
\h for help with SQL commands
\? for help with psql commands
\g or terminate with semicolon to execute query
\q to quit

testdb=# select current_timestamp;
now
-------------------------------
2008-05-07 05:19:47.818483-04
(1 row)

testdb=# select * from testtbl;
testid | usr | pw | usrid | ctm | laxtm
--------+-------+------+---------+---------------+---------------
1 | usr00 | pw00 | usrpw00 | 1068457566818 | 1068457579818
2 | usr02 | pw02 | usrpw02 | 1068455566818 | 1068455566999
3 | usr04 | pw04 | usrpw04 | 1068447566818 | 1068447566865
(3 rows)

testdb=#
~
// __
But then when I try my java code I get exactly the same error and
this is what gets logged
~
LOG: database system was shut down at 2008-05-06 23:51:37 EDT
LOG: autovacuum launcher started
LOG: database system is ready to accept connections
LOG: connection received: host=[local]
LOG: connection authorized: user=pgtest database=testdb
LOG: statement: select current_timestamp;
LOG: statement: select * from testtbl;
LOG: connection received: host=127.0.0.1 port=35036
LOG: connection authorized: user=pgtest database=testdb
LOG: execute <unnamed>: SELECT
n.nspname,c.relname,a.attname,a.atttypid,a.attnotnull,a.atttypmod,a.attlen,a.attnum,def.adsrc,dsc.description,t.typbasetype,t.typtype
FROM pg_catalog.pg_namespace n JOIN pg_catalog.pg_class c ON
(c.relnamespace = n.oid) JOIN pg_catalog.pg_attribute a ON
(a.attrelid=c.oid) JOIN pg_catalog.pg_type t ON (a.atttypid = t.oid)
LEFT JOIN pg_catalog.pg_attrdef def ON (a.attrelid=def.adrelid AND
a.attnum = def.adnum) LEFT JOIN pg_catalog.pg_description dsc ON
(c.oid=dsc.objoid AND a.attnum = dsc.objsubid) LEFT JOIN
pg_catalog.pg_class dc ON (dc.oid=dsc.classoid AND
dc.relname='pg_class') LEFT JOIN pg_catalog.pg_namespace dn ON
(dc.relnamespace=dn.oid AND dn.nspname='pg_catalog') WHERE a.attnum >
0 AND NOT a.attisdropped AND c.relname LIKE 'testtbl' ORDER BY
nspname,relname,attnum
LOG: disconnection: session time: 0:00:00.289 user=pgtest
database=testdb host=127.0.0.1 port=35036
~
Something I don't know about is this error:
~
pgtest(at)Knoppix:~/bin$ ICE default IO error handler doing an exit(),
pid = 3911, errno = 0
~
but then I accessed my testdb.testtbl without any problems
~
What exactly am I stumbling on? I wonder if knoppix is creating some problems
~
How can I fix this problem?
~
lbrtchx
~
PS: Well, yes it should be Albrecht (like Duerer's and Gisselle's)
AlbreTch I mangled (lbrtchx) as a way to easily tell myself apart an
an online persona

In response to

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Albe Laurenz *EXTERN* 2008-05-07 11:25:41 Re: org.postgresql.util.PSQLException: An I/O error occured while sending to the backend
Previous Message Albe Laurenz *EXTERN* 2008-05-07 06:59:05 Re: org.postgresql.util.PSQLException: An I/O error occured while sending to the backend