pg.ddx.io pgsql-jdbc@postgresql.org mailing list archive
help / color / mirror / Atom feedAn I/O error occured while sending to the backend.
27+ messages / 14 participants
[nested] [flat]
* An I/O error occured while sending to the backend.
@ 2005-01-14 21:59 Stephen McConnell <mcconnell_stephen@yahoo.com>
0 siblings, 1 reply; 27+ messages in thread
From: Stephen McConnell @ 2005-01-14 21:59 UTC (permalink / raw)
To: pgsql-jdbc
I am developing using the new PostgreSQL 8.0.0 rc5 under Windoz XP
(sorry).
I am also using Eclipse with the MyEclipseWorkbench and ACCESSING A
DATABASE ON localhost. In the code I make a valid connection and
immediately set up a prepared statement and execute a query.
The code is:
pstmt = connection.prepareStatement(SQL_GET_SEQUENCE);
pstmt.setString(1, this.name);
rs = pstmt.executeQuery();
The query is:
private static final String SQL_GET_SEQUENCE =
"SELECT " +
"seed " +
"FROM " +
"stocks.sequencer " +
"WHERE " +
"name = ?";
or
SELECT seed FROM stocks.sequencer WHEREname = 'test_sequence'
I am using the pg80b1.308jdbc3.jar jdbc driver.
The above query works through pgAdmin III and the MyEclipse Database
Explorer.... But when I run the above java code I receive the infamous
Exception: java.io.IOException: Stream closed
Stack Trace:
java.io.IOException: Stream closed
at sun.nio.cs.StreamEncoder.ensureOpen(StreamEncoder.java:38)
at sun.nio.cs.StreamEncoder.flush(StreamEncoder.java:151)
at java.io.OutputStreamWriter.flush(OutputStreamWriter.java:213)
at org.postgresql.core.PGStream.flush(PGStream.java:485)
at
org.postgresql.core.v3.QueryExecutorImpl.sendSync(QueryExecutorImpl.java:616)
at
org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:165)
at
org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:363)
at
org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:308)
at
org.postgresql.jdbc2.AbstractJdbc2Statement.executeQuery(AbstractJdbc2Statement.java:223)
at com.scawa.stockanalyzer.db.Sequencer.reseed(Sequencer.java:95)
at com.scawa.stockanalyzer.db.Sequencer.next(Sequencer.java:73)
at com.scawa.stockanalyzer.test.Tester.main(Tester.java:46)
Others have said this is a TCP/IP problem with a firewall, but it's
pretty apparent that since I'm accessing "localhost"
(jdbc:postgresql://localhost:5432/test_database) that It's not a
"firewall" problem UNLESS there's a problem with the Windoz XP
firewall.
Any ideas? Suggestions?
Stephen McConnell
=====
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend.
@ 2005-01-15 07:21 Oliver Jowett <oliver@opencloud.com>
parent: Stephen McConnell <mcconnell_stephen@yahoo.com>
0 siblings, 1 reply; 27+ messages in thread
From: Oliver Jowett @ 2005-01-15 07:21 UTC (permalink / raw)
To: Stephen McConnell <mcconnell_stephen@yahoo.com>; +Cc: pgsql-jdbc
Stephen McConnell wrote:
> Exception: java.io.IOException: Stream closed
> Stack Trace:
> java.io.IOException: Stream closed
> Others have said this is a TCP/IP problem with a firewall, but it's
> pretty apparent that since I'm accessing "localhost"
> (jdbc:postgresql://localhost:5432/test_database) that It's not a
> "firewall" problem UNLESS there's a problem with the Windoz XP
> firewall.
No, it doesn't look like a firewall problem -- that usually manifests as
a connection refused or a connection reset by peer. This looks like the
driver is closing the connection itself, but not invalidating the
connection. I'd suspect an earlier error on the connection is causing this.
Do you have a complete testcase I can try?
-O
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend.
@ 2005-01-15 19:57 Stephen McConnell <mcconnell_stephen@yahoo.com>
parent: Oliver Jowett <oliver@opencloud.com>
0 siblings, 0 replies; 27+ messages in thread
From: Stephen McConnell @ 2005-01-15 19:57 UTC (permalink / raw)
To: Oliver Jowett <oliver@opencloud.com>; +Cc: pgsql-jdbc
I'm gonna tell on myself on this one... and it embarrases me more than
I can say.
I had written a DBManager class that manages connections. It was a
first iteration and I was just using the simple
DriverManager.getConnection(....) method before tackling connection
pooling.
In the DBManager class where I had my "getConnection()" method, I had
my standard JDBC try... catch... finally.... block. I got the
connection, but in my finally block... like I ALWAYS do when I write a
try... catch... finally.... block, I closed the resources. One of
which was the "connection".... :(
Hence, the IO error.....
Thanks for the answer.... once I began looking at the code to give you
an example, I found it.
Stephen McConnell
--- Oliver Jowett <oliver@opencloud.com> wrote:
> Stephen McConnell wrote:
>
> > Exception: java.io.IOException: Stream closed
> > Stack Trace:
> > java.io.IOException: Stream closed
>
> > Others have said this is a TCP/IP problem with a firewall, but it's
> > pretty apparent that since I'm accessing "localhost"
> > (jdbc:postgresql://localhost:5432/test_database) that It's not a
> > "firewall" problem UNLESS there's a problem with the Windoz XP
> > firewall.
>
> No, it doesn't look like a firewall problem -- that usually manifests
> as
> a connection refused or a connection reset by peer. This looks like
> the
> driver is closing the connection itself, but not invalidating the
> connection. I'd suspect an earlier error on the connection is causing
> this.
>
> Do you have a complete testcase I can try?
>
> -O
>
=====
^ permalink raw reply [nested|flat] 27+ messages in thread
* An I/O error occured while sending to the backend
@ 2005-04-06 10:10 Anthony Chaffey <anthony@webmediaworks.co.uk>
0 siblings, 2 replies; 27+ messages in thread
From: Anthony Chaffey @ 2005-04-06 10:10 UTC (permalink / raw)
To: pgsql-jdbc
Hi,
I have developed an application using the postgresql-8.0-310.jdbc3
driver and connecting to a postgresql 8.0.1 database running on fedora
core 3. Everything was working fine until i started running the
application on the clients pc's. Randomly they receive an error, the
stack trace of which is below.
The only difference between my testing pc and the client's pc's is that
they use a wireless network card. Both my machine and the client's pc's
are running Windows XP with SP2. Similar problems have been posted on
this mailing list and people have suggested a firewall is clearing the
connection which makes sense as the client claims this problem only
occurs if the application is left idle for a short time but does anyone
have any more information that may help?
Thanks for any help.
Anthony.
Stack Trace:
org.postgresql.util.PSQLException: An I/O error occured while sending to
the backend.
at
org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:
201)
at
org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Stateme
nt.java:388)
at
org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdb
c2Statement.java:313)
at
org.postgresql.jdbc2.AbstractJdbc2Statement.executeQuery(AbstractJdbc2St
atement.java:220)
......
at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
at javax.swing.JToggleButton$ToggleButtonModel.setPressed(Unknown
Source)
at javax.swing.AbstractButton.doClick(Unknown Source)
at javax.swing.plaf.basic.BasicMenuItemUI.doClick(Unknown Source)
at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(Unknown
Source)
at java.awt.Component.processMouseEvent(Unknown Source)
at javax.swing.JComponent.processMouseEvent(Unknown Source)
at java.awt.Component.processEvent(Unknown Source)
at java.awt.Container.processEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Window.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown
Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
Caused by: java.io.EOFException
at org.postgresql.core.PGStream.ReceiveChar(PGStream.java:243)
at
org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImp
l.java:1122)
at
org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:
175)
... 35 more
--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.308 / Virus Database: 266.9.3 - Release Date: 05/04/2005
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2005-04-06 16:24 John R Pierce <pierce@hogranch.com>
parent: Anthony Chaffey <anthony@webmediaworks.co.uk>
1 sibling, 1 reply; 27+ messages in thread
From: John R Pierce @ 2005-04-06 16:24 UTC (permalink / raw)
To: anthony@webmediaworks.co.uk; +Cc: pgsql-jdbc
Anthony Chaffey wrote:
> Hi,
>
>
> I have developed an application using the postgresql-8.0-310.jdbc3
> driver and connecting to a postgresql 8.0.1 database running on fedora
> core 3. Everything was working fine until i started running the
> application on the clients pc's. Randomly they receive an error, the
> stack trace of which is below.
>
> The only difference between my testing pc and the client's pc's is that
> they use a wireless network card. Both my machine and the client's pc's
> are running Windows XP with SP2. Similar problems have been posted on
> this mailing list and people have suggested a firewall is clearing the
> connection which makes sense as the client claims this problem only
> occurs if the application is left idle for a short time but does anyone
> have any more information that may help?
its probaly exactly what you say, most firewalls, NAT routers, etc will time
out idle sockets after a certain number of minutes... They have to do this,
otherwise the firewall's connection tracking tables will fill up with old flug.
only good solution is to catch the exception, and attempt to reopen the
database connection, and retry the operation....
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2005-04-06 17:35 Scott Marlowe <smarlowe@g2switchworks.com>
parent: John R Pierce <pierce@hogranch.com>
0 siblings, 1 reply; 27+ messages in thread
From: Scott Marlowe @ 2005-04-06 17:35 UTC (permalink / raw)
To: John R Pierce <pierce@hogranch.com>; +Cc: anthony@webmediaworks.co.uk; pgsql-jdbc
On Wed, 2005-04-06 at 11:24, John R Pierce wrote:
> Anthony Chaffey wrote:
> > Hi,
> >
> >
> > I have developed an application using the postgresql-8.0-310.jdbc3
> > driver and connecting to a postgresql 8.0.1 database running on fedora
> > core 3. Everything was working fine until i started running the
> > application on the clients pc's. Randomly they receive an error, the
> > stack trace of which is below.
> >
> > The only difference between my testing pc and the client's pc's is that
> > they use a wireless network card. Both my machine and the client's pc's
> > are running Windows XP with SP2. Similar problems have been posted on
> > this mailing list and people have suggested a firewall is clearing the
> > connection which makes sense as the client claims this problem only
> > occurs if the application is left idle for a short time but does anyone
> > have any more information that may help?
>
> its probaly exactly what you say, most firewalls, NAT routers, etc will time
> out idle sockets after a certain number of minutes... They have to do this,
> otherwise the firewall's connection tracking tables will fill up with old flug.
>
> only good solution is to catch the exception, and attempt to reopen the
> database connection, and retry the operation....
Does setting a lower tcp_keepalive_time help these problems with NAT?
It certainly fixed the problems I've seen with non-NAT firewalls. (this
is a linux kernel setting, i'm sure there's an equivalent for other
unixes)
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2005-04-07 10:49 Markus Schaber <schabi@logix-tt.com>
parent: Scott Marlowe <smarlowe@g2switchworks.com>
0 siblings, 0 replies; 27+ messages in thread
From: Markus Schaber @ 2005-04-07 10:49 UTC (permalink / raw)
To: Scott Marlowe <smarlowe@g2switchworks.com>; +Cc: John R Pierce <pierce@hogranch.com>; anthony@webmediaworks.co.uk; pgsql-jdbc
Hi, Scott,
Scott Marlowe schrieb:
>>only good solution is to catch the exception, and attempt to reopen the
>>database connection, and retry the operation....
> Does setting a lower tcp_keepalive_time help these problems with NAT?
> It certainly fixed the problems I've seen with non-NAT firewalls. (this
> is a linux kernel setting, i'm sure there's an equivalent for other
> unixes)
java.net.Socket has some settings about timeouts and keepalives, maybe
those will help.
Markus
Attachments:
signature.asc (application/pgp-signature, 255B) download
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2005-04-07 11:34 Anthony Chaffey <anthony@webmediaworks.co.uk>
parent: Anthony Chaffey <anthony@webmediaworks.co.uk>
1 sibling, 0 replies; 27+ messages in thread
From: Anthony Chaffey @ 2005-04-07 11:34 UTC (permalink / raw)
To: pgsql-jdbc
Thanks to everyone for their responses.
I have now coded the application to catch the exception an determine
whether it is an i/o problem and attempts to re-connect to the database.
I will look into the socket time-out settings but I have realised that
my solution also holds up well when a network/internet connection is
lost entirely.
Thanks again.
--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.308 / Virus Database: 266.9.4 - Release Date: 06/04/2005
^ permalink raw reply [nested|flat] 27+ messages in thread
* An I/O error occured while sending to the backend
@ 2006-02-14 14:26 Radek Jíra <jira@iiprg.cz>
0 siblings, 0 replies; 27+ messages in thread
From: Radek Jíra @ 2006-02-14 14:26 UTC (permalink / raw)
To: pgsql-jdbc
Hello,
I have a problem that I am not able to solve. I have this exception:
org.postgresql.util.PSQLException: An I/O error occured while sending to
the backend.
at
org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:216)
at
org.postgresql.jdbc2.AbstractJdbc2Connection.executeTransactionCommand(AbstractJdbc2Connection.java:649)
at
org.postgresql.jdbc2.AbstractJdbc2Connection.rollback(AbstractJdbc2Connection.java:686)
at com.evermind._id.rollback(.:196)
at com.evermind._ja.rollback(.:104)
at com.evermind._bs._gbc(.:118)
at com.evermind.server.ApplicationServerTransaction._gcc(.:334)
at com.evermind.server.ApplicationServerTransaction._gbc(.:296)
at com.evermind.server.ApplicationServerTransaction.rollback(.:279)
at
com.evermind.server.ApplicationServerTransactionManager.rollback(.:285)
at
cz.iiprg.util.importer.ejb.ImporterEJB.rollbackTransaction(ImporterEJB.java:173)
at
Importer_StatefulSessionBeanWrapper34.rollbackTransaction(Importer_StatefulSessionBeanWrapper34.java:416)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at com.evermind._bt._uab(.:79)
at com.evermind._bf.run(.:62)
Caused by: java.io.IOException: Stream closed
at sun.nio.cs.StreamEncoder.ensureOpen(StreamEncoder.java:38)
at sun.nio.cs.StreamEncoder.flush(StreamEncoder.java:151)
at java.io.OutputStreamWriter.flush(OutputStreamWriter.java:213)
at org.postgresql.core.PGStream.flush(PGStream.java:501)
at
org.postgresql.core.v3.QueryExecutorImpl.sendSync(QueryExecutorImpl.java:674)
at
org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:189)
... 17 more
It is strange that it occurs randomly and only when the server is loaded.
Radek
^ permalink raw reply [nested|flat] 27+ messages in thread
* An I/O error occured while sending to the backend.
@ 2010-04-06 01:41 Breno BF <brenobfernandes@bsd.com.br>
0 siblings, 1 reply; 27+ messages in thread
From: Breno BF @ 2010-04-06 01:41 UTC (permalink / raw)
To: pgsql-jdbc
Hi,
I am running PostgreSQL version 8.3 with this conf[1].
The Operating System is a GNU/Linux x86_64 Kernel 2.6.28-11-server,
Distribution: Ubuntu SMP.
Some sysctl I think it's important to relate[2]
Memory and Proc information [3].
The log error is [4].
Aditional information:
I am getting this error using glassfish and postgresql: " Caused by:
org.postgresql.util.PSQLException: An I/O error occured while sending to the
backend."
Both glassfish and pgsql are localhost. The connection is made using JPA
(using localhost to connect)[5].
There's no firewall filtering or blocking it.
I have other environment but CentOS using the same version of pgsql and
glassfish with no errors.
What can it be? No errors in pgsql logs.
[1] - postgresql.conf
data_directory = '/var/lib/postgresql/8.3/main'
hba_file = '/etc/postgresql/8.3/main/pg_hba.conf'
ident_file = '/etc/postgresql/8.3/main/pg_ident.conf'
external_pid_file = '/var/run/postgresql/8.3-main.pid'
port = 5432
max_connections = 500
shared_buffers = 32MB
max_fsm_pages = 204800
log_min_messages = error
log_min_error_statement = error
debug_print_parse = off
debug_print_rewritten = off
debug_print_plan = off
debug_pretty_print = off
log_connections = on
log_disconnections = on
log_line_prefix = '%t '
log_statement = 'all'
datestyle = 'iso, mdy'
lc_messages = 'en_US.UTF-8'
lc_monetary = 'en_US.UTF-8'
lc_numeric = 'en_US.UTF-8'
lc_time = 'en_US.UTF-8'
default_text_search_config = 'pg_catalog.english'
[2] sysctl
vm.overcommit_memory = 0
vm.panic_on_oom = 0
vm.oom_kill_allocating_task = 0
vm.oom_dump_tasks = 0
vm.overcommit_ratio = 50
vm.page-cluster = 3
vm.dirty_background_ratio = 40
vm.dirty_ratio = 40
vm.dirty_writeback_centisecs = 500
vm.dirty_expire_centisecs = 3000
vm.nr_pdflush_threads = 2
vm.swappiness = 60
vm.nr_hugepages = 0
vm.hugetlb_shm_group = 0
vm.hugepages_treat_as_movable = 0
vm.nr_overcommit_hugepages = 0
vm.lowmem_reserve_ratio = 256 256 32
vm.drop_caches = 0
vm.min_free_kbytes = 9939
vm.percpu_pagelist_fraction = 0
vm.max_map_count = 65536
vm.laptop_mode = 0
vm.block_dump = 0
vm.vfs_cache_pressure = 100
vm.legacy_va_layout = 0
vm.stat_interval = 1
vm.mmap_min_addr = 65536
kernel.shmmax = 68719476736
kernel.shmmni = 4096
[3] - Proc / Mem Info
Proc 16 cores:
model name : Intel(R) Xeon(R) CPU E5520 @ 2.27GHz
cpu MHz : 2260.929
cache size : 8192 KB
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca
cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx
rdtscp l
m constant_tsc arch_perfmon pebs bts rep_good xtopology pni dtes64 monitor
ds_cpl vmx est tm2 ssse3 cx16 xtpr pdcm dca sse4_1 sse4_2 lahf_lm ida
tpr_shadow v
nmi flexpriority ept vpid
bogomips : 4521.85
clflush size : 64
cache_alignment : 64
address sizes : 40 bits physical, 48 bits virtual
Mem:
total used free shared buffers cached
Mem: 6023960 4969208 1054752 0 156176 3833340
-/+ buffers/cache: 979692 5044268
Swap: 3903784 47752 3856032
[4] Log error:
http://pastebin.com/qjUbaFmM
[5] Connection:
<property name="toplink.jdbc.driver" value="org.postgresql.Driver" />
<property name="toplink.jdbc.url"
value="jdbc:postgresql://localhost:5432/hidden" />
<property name="toplink.jdbc.user" value="tcpmexico" />
<property name="toplink.jdbc.password" value="MY_PASSWD" />
Any ideas will be welcome!
Let me know if I need to post more information or if this is not the
adequated place for the post.
Thanks
-B
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend.
@ 2010-04-06 04:09 Craig Ringer <craig@postnewspapers.com.au>
parent: Breno BF <brenobfernandes@bsd.com.br>
0 siblings, 1 reply; 27+ messages in thread
From: Craig Ringer @ 2010-04-06 04:09 UTC (permalink / raw)
To: Breno BF <brenobfernandes@bsd.com.br>; +Cc: pgsql-jdbc
Breno BF wrote:
> I am getting this error using glassfish and postgresql: " Caused by:
> org.postgresql.util.PSQLException: An I/O error occured while sending to
> the backend."
Further in the exception log, you'll see:
Caused by: java.net.SocketException: Socket closed
In other words, the pgsql backend has "hung up" on the client. Most
likely the Pg backend terminated for some reason, which you should see
in the PostgreSQL logs.
> log_min_messages = error
> log_min_error_statement = error
Turn these down to at least 'info', restart PostgreSQL, and see if you
get anything informative in the logs.
--
Craig Ringer
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend.
@ 2010-04-06 15:01 Breno BF <brenobfernandes@bsd.com.br>
parent: Craig Ringer <craig@postnewspapers.com.au>
0 siblings, 2 replies; 27+ messages in thread
From: Breno BF @ 2010-04-06 15:01 UTC (permalink / raw)
To: Craig Ringer <craig@postnewspapers.com.au>; +Cc: pgsql-jdbc
Hi,
Craig, since I changed it to info, I could not see nothing in postgres logs
when the problem occurs.
log_min_messages = info
log_min_error_statement = info
should I change it to debug?
-B
2010/4/6 Craig Ringer <craig@postnewspapers.com.au>
> Breno BF wrote:
>
> > I am getting this error using glassfish and postgresql: " Caused by:
> > org.postgresql.util.PSQLException: An I/O error occured while sending to
> > the backend."
>
> Further in the exception log, you'll see:
>
> Caused by: java.net.SocketException: Socket closed
>
> In other words, the pgsql backend has "hung up" on the client. Most
> likely the Pg backend terminated for some reason, which you should see
> in the PostgreSQL logs.
>
> > log_min_messages = error
> > log_min_error_statement = error
>
> Turn these down to at least 'info', restart PostgreSQL, and see if you
> get anything informative in the logs.
>
> --
> Craig Ringer
>
--
- breno bf
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend.
@ 2010-04-07 10:58 Breno BF <brenobfernandes@bsd.com.br>
parent: Breno BF <brenobfernandes@bsd.com.br>
1 sibling, 0 replies; 27+ messages in thread
From: Breno BF @ 2010-04-07 10:58 UTC (permalink / raw)
To: pgsql-jdbc
None ?
2010/4/6 Breno BF <brenobfernandes@bsd.com.br>
> Hi,
>
> Craig, since I changed it to info, I could not see nothing in postgres logs
> when the problem occurs.
>
> log_min_messages = info
> log_min_error_statement = info
>
> should I change it to debug?
>
> -B
>
> 2010/4/6 Craig Ringer <craig@postnewspapers.com.au>
>
> Breno BF wrote:
>>
>> > I am getting this error using glassfish and postgresql: " Caused by:
>> > org.postgresql.util.PSQLException: An I/O error occured while sending to
>> > the backend."
>>
>> Further in the exception log, you'll see:
>>
>> Caused by: java.net.SocketException: Socket closed
>>
>> In other words, the pgsql backend has "hung up" on the client. Most
>> likely the Pg backend terminated for some reason, which you should see
>> in the PostgreSQL logs.
>>
>> > log_min_messages = error
>> > log_min_error_statement = error
>>
>> Turn these down to at least 'info', restart PostgreSQL, and see if you
>> get anything informative in the logs.
>>
>> --
>> Craig Ringer
>>
>
>
>
> --
> - breno bf
>
--
- breno bf
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend.
@ 2010-04-07 12:54 Craig Ringer <craig@postnewspapers.com.au>
parent: Breno BF <brenobfernandes@bsd.com.br>
1 sibling, 0 replies; 27+ messages in thread
From: Craig Ringer @ 2010-04-07 12:54 UTC (permalink / raw)
To: Breno BF <brenobfernandes@bsd.com.br>; +Cc: pgsql-jdbc
On 6/04/2010 11:01 PM, Breno BF wrote:
> Hi,
>
> Craig, since I changed it to info, I could not see nothing in postgres
> logs when the problem occurs.
>
> log_min_messages = info
> log_min_error_statement = info
>
> should I change it to debug?
Er... sure.
Given that both client and server are on the local host I'd really
expect _some_ kind of indication that a backend was going away and
leaving the client without a connection. Clearly the connection pool
behind JPA expects the connection to still be active, and without any
network-layer issues to get in the way, it really must be the backend
dying for some reason.
--
Craig Ringer
^ permalink raw reply [nested|flat] 27+ messages in thread
* An I/O error occured while sending to the backend
@ 2012-06-09 11:25 wbrana <wbrana@gmail.com>
0 siblings, 1 reply; 27+ messages in thread
From: wbrana @ 2012-06-09 11:25 UTC (permalink / raw)
To: pgsql-jdbc
public Connection getConn(){
if (conn == null) {
try {
Class.forName("org.postgresql.Driver"); //load the driver
conn = DriverManager.getConnection("jdbc:postgresql://localhost/forum?loglevel=1","forum","forum");
} catch (Exception e) {
if (debug) {
e.printStackTrace();
}
}
}
return conn;
}
forum.ViewsThread.run:
public void run() {
Connection conn = new Jdbc().getConn();
try {
conn.setAutoCommit(false);
conn.prepareStatement("analyze forum_cats").executeUpdate();
conn.prepareStatement("analyze forums").executeUpdate();
conn.prepareStatement("analyze groups").executeUpdate();
conn.prepareStatement("analyze posts").executeUpdate(); // Line 77
conn.prepareStatement("analyze threads").executeUpdate();
conn.prepareStatement("analyze user_groups").executeUpdate();
conn.prepareStatement("analyze users").executeUpdate();
conn.commit();
2012-06-09 12:43:52.654 CEST,,,2285,"",4fd328e8.8ed,1,"",2012-06-09
12:43:52 CEST,,0,LOG,00000,"connection received: host=127.0.0.1
port=55770",,,,,,,,,""
2012-06-09 12:43:52.656
CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,2,"authentication",2012-06-09
12:43:52 CEST,10/151,0,LOG,00000,"connection authorized: user=forum
database=forum",,,,,,,,,""
2012-06-09 12:43:52.658
CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,3,"SET",2012-06-09
12:43:52 CEST,10/152,0,LOG,00000,"execute <unnamed>: SET
extra_float_digits = 3",,,,,,,,,""
2012-06-09 12:43:52.668
CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,4,"BEGIN",2012-06-09
12:43:52 CEST,10/153,0,LOG,00000,"execute S_1: BEGIN",,,,,,,,,""
2012-06-09 12:43:52.668
CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,5,"ANALYZE",2012-06-09
12:43:52 CEST,10/153,0,LOG,00000,"execute <unnamed>: analyze
forum_cats",,,,,,,,,""
2012-06-09 12:43:52.670
CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,6,"ANALYZE",2012-06-09
12:43:52 CEST,10/153,6274,LOG,00000,"execute <unnamed>: analyze
forums",,,,,,,,,""
2012-06-09 12:43:52.671
CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,7,"ANALYZE",2012-06-09
12:43:52 CEST,10/153,6274,LOG,00000,"execute <unnamed>: analyze
groups",,,,,,,,,""
2012-06-09 12:43:52.671
CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,8,"ANALYZE",2012-06-09
12:43:52 CEST,10/153,6274,LOG,00000,"execute <unnamed>: analyze
posts",,,,,,,,,""
2012-06-09 12:43:52.691
CEST,"forum","forum",2228,"127.0.0.1:55758",4fd328e4.8b4,8,"SELECT",2012-06-09
12:43:48 CEST,2/184,0,LOG,00000,"execute <unnamed>: SELECT forum_id,
cat_id, cat_name, forum_description, forum_name, login, post_count,
post_created, thread_count, thread_name FROM v_forums",,,,,,,,,""
2012-06-09 12:43:52.696
CEST,"forum","forum",2228,"127.0.0.1:55758",4fd328e4.8b4,9,"SET",2012-06-09
12:43:48 CEST,2/185,0,LOG,00000,"execute <unnamed>: SET
application_name = ''",,,,,,,,,""
2012-06-09 12:43:53.080
CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,9,"idle in
transaction",2012-06-09 12:43:52 CEST,,0,LOG,00000,"disconnection:
session time: 0:00:00.425 user=forum database=forum host=127.0.0.1
port=55770",,,,,,,,,""
Launching GlassFish on Felix platform
INFO: Running GlassFish Version: GlassFish Server Open Source Edition
3.1.2 (build 23)
INFO: Grizzly Framework 1.9.46 started in: 33ms - bound to [0.0.0.0:8181]
INFO: Grizzly Framework 1.9.46 started in: 29ms - bound to [0.0.0.0:4848]
INFO: Grizzly Framework 1.9.46 started in: 47ms - bound to [0.0.0.0:8080]
INFO: Grizzly Framework 1.9.46 started in: 22ms - bound to [0.0.0.0:3700]
INFO: Grizzly Framework 1.9.46 started in: 15ms - bound to [0.0.0.0:7676]
INFO: The Admin Console is already installed, but not yet loaded.
INFO: Registered
org.glassfish.ha.store.adapter.cache.ShoalBackingStoreProxy for
persistence-type = replicated in BackingStoreFactoryRegistry
INFO: Created EjbThreadPoolExecutor with thread-core-pool-size 16
thread-max-pool-size 32 thread-keep-alive-seconds 60
thread-queue-capacity 2147483647 allow-core-thread-timeout false
INFO: SEC1002: Security Manager is OFF.
INFO: SEC1010: Entering Security Startup Service
INFO: SEC1143: Loading policy provider
com.sun.enterprise.security.provider.PolicyWrapper.
INFO: SEC1115: Realm [admin-realm] of classtype
[com.sun.enterprise.security.auth.realm.file.FileRealm] successfully
created.
INFO: SEC1115: Realm [file] of classtype
[com.sun.enterprise.security.auth.realm.file.FileRealm] successfully
created.
INFO: SEC1115: Realm [certificate] of classtype
[com.sun.enterprise.security.auth.realm.certificate.CertificateRealm]
successfully created.
INFO: SEC1115: Realm [jdbcDigestRealm] of classtype
[com.sun.enterprise.security.auth.realm.jdbc.JDBCRealm] successfully
created.
INFO: SEC1011: Security Service(s) Started Successfully
INFO: WEB0169: Created HTTP listener [http-listener-1] on host/port
[0.0.0.0:8080]
INFO: WEB0169: Created HTTP listener [http-listener-2] on host/port
[0.0.0.0:8181]
INFO: WEB0169: Created HTTP listener [admin-listener] on host/port
[0.0.0.0:4848]
INFO: WEB0171: Created virtual server [server]
INFO: WEB0171: Created virtual server [__asadmin]
INFO: WEB0172: Virtual server [server] loaded default web module []
INFO: Hibernate Validator 4.2.0.Final
INFO: EclipseLink, version: Eclipse Persistence Services -
2.3.2.v20111125-r10461
INFO: file:/home/x/NetBeansProjects/forum/build/web/WEB-INF/classes/_forumPU
login successful
WARNING: Multiple [2] JMX MBeanServer instances exist, we will use the
server at index [0] :
[com.sun.enterprise.v3.admin.DynamicInterceptor@1816407].
WARNING: JMX MBeanServer in use:
[com.sun.enterprise.v3.admin.DynamicInterceptor@1816407] from index
[0]
WARNING: JMX MBeanServer in use:
[com.sun.jmx.mbeanserver.JmxMBeanServer@1e2a099] from index [1]
INFO: EJB5181:Portable JNDI names for EJB ThreadsFacade:
[java:global/forum/ThreadsFacade,
java:global/forum/ThreadsFacade!forum.ThreadsFacade]
INFO: EJB5181:Portable JNDI names for EJB UsersFacade:
[java:global/forum/UsersFacade,
java:global/forum/UsersFacade!forum.UsersFacade]
INFO: EJB5181:Portable JNDI names for EJB ForumsPageFacade:
[java:global/forum/ForumsPageFacade,
java:global/forum/ForumsPageFacade!forum.ForumsPageFacade]
INFO: EJB5181:Portable JNDI names for EJB GroupsFacade:
[java:global/forum/GroupsFacade,
java:global/forum/GroupsFacade!forum.GroupsFacade]
INFO: EJB5181:Portable JNDI names for EJB VPostsFacade:
[java:global/forum/VPostsFacade!forum.VPostsFacade,
java:global/forum/VPostsFacade]
INFO: EJB5181:Portable JNDI names for EJB VThreads2Facade:
[java:global/forum/VThreads2Facade,
java:global/forum/VThreads2Facade!forum.VThreads2Facade]
INFO: EJB5181:Portable JNDI names for EJB VThreadsFacade:
[java:global/forum/VThreadsFacade,
java:global/forum/VThreadsFacade!forum.VThreadsFacade]
INFO: EJB5181:Portable JNDI names for EJB PostsFacade:
[java:global/forum/PostsFacade,
java:global/forum/PostsFacade!forum.PostsFacade]
INFO: EJB5181:Portable JNDI names for EJB ForumCatsFacade:
[java:global/forum/ForumCatsFacade,
java:global/forum/ForumCatsFacade!forum.ForumCatsFacade]
INFO: EJB5181:Portable JNDI names for EJB UserGroupsFacade:
[java:global/forum/UserGroupsFacade!forum.UserGroupsFacade,
java:global/forum/UserGroupsFacade]
INFO: EJB5181:Portable JNDI names for EJB VPostsFacade2:
[java:global/forum/VPostsFacade2!forum.VPostsFacade2,
java:global/forum/VPostsFacade2]
INFO: EJB5181:Portable JNDI names for EJB VUserRoleFacade:
[java:global/forum/VUserRoleFacade!forum.VUserRoleFacade,
java:global/forum/VUserRoleFacade]
INFO: EJB5181:Portable JNDI names for EJB AuthBackingBeanFacade:
[java:global/forum/AuthBackingBeanFacade!forum.AuthBackingBeanFacade,
java:global/forum/AuthBackingBeanFacade]
INFO: WELD-000900 1.1.4 (Final)
INFO: Initializing Mojarra 2.1.7 (SNAPSHOT 20120206) for context '/forum'
WARNING: JSF1074: Managed bean named 'customerCRUD' has already been
registered. Replacing existing managed bean class type
forum.CustomerCRUD with forum.CustomerCRUD.
INFO: Monitoring jndi:/server/forum/WEB-INF/faces-config.xml for modifications
INFO: WEB0671: Loading application [forum] at [/forum]
INFO: CORE10010: Loading application forum done in 5,708 ms
INFO: GlassFish Server Open Source Edition 3.1.2 (23) startup time :
Felix (1,031ms), startup services(6,263ms), total(7,294ms)
INFO: JMX005: JMXStartupService had Started JMXConnector on JMXService
URL service:jmx:rmi://localhost:8686/jndi/rmi://localhost:8686/jmxrmi
INFO: Initiating Jersey application, version 'Jersey: 1.11 12/09/2011 10:27 AM'
INFO: WEB0169: Created HTTP listener [http-listener-1] on host/port
[0.0.0.0:8080]
INFO: Grizzly Framework 1.9.46 started in: 1ms - bound to [0.0.0.0:8080]
INFO: 12:43:52.653 (9) PostgreSQL 9.2devel JDBC4 (build 1000)
INFO: getConnection returning org.postgresql.Driver
INFO: REST00001: Listening to REST requests at context: /management/domain
INFO: The Admin Console is already installed, but not yet loaded.
INFO: The Admin Console is starting. Please wait.
INFO: org.postgresql.util.PSQLException: An I/O error occured while
sending to the backend.
INFO: at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:281)
INFO: at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:553)
INFO: at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:415)
INFO: at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:361)
INFO: at forum.ViewsThread.run(ViewsThread.java:77)
INFO: SQLException: SQLState(08006)
SEVERE: org.postgresql.util.PSQLException: An I/O error occured while
sending to the backend.
at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:281)
at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:553)
at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:415)
at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:361)
at forum.ViewsThread.run(ViewsThread.java:77)
Caused by: java.net.SocketException: Socket closed
at java.net.SocketInputStream.socketRead0(Native Method)
at java.net.SocketInputStream.read(SocketInputStream.java:150)
at java.net.SocketInputStream.read(SocketInputStream.java:121)
at org.postgresql.core.VisibleBufferedInputStream.readMore(VisibleBufferedInputStream.java:143)
at org.postgresql.core.VisibleBufferedInputStream.ensureBytes(VisibleBufferedInputStream.java:112)
at org.postgresql.core.VisibleBufferedInputStream.read(VisibleBufferedInputStream.java:71)
at org.postgresql.core.PGStream.ReceiveChar(PGStream.java:272)
at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1700)
at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:255)
... 4 more
SEVERE: at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:281)
SEVERE: at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:553)
SEVERE: at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:415)
SEVERE: at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:361)
SEVERE: at forum.ViewsThread.run(ViewsThread.java:77)
SEVERE: Caused by: java.net.SocketException: Socket closed
SEVERE: at java.net.SocketInputStream.socketRead0(Native Method)
SEVERE: at java.net.SocketInputStream.read(SocketInputStream.java:150)
SEVERE: at java.net.SocketInputStream.read(SocketInputStream.java:121)
SEVERE: at org.postgresql.core.VisibleBufferedInputStream.readMore(VisibleBufferedInputStream.java:143)
SEVERE: at org.postgresql.core.VisibleBufferedInputStream.ensureBytes(VisibleBufferedInputStream.java:112)
SEVERE: at org.postgresql.core.VisibleBufferedInputStream.read(VisibleBufferedInputStream.java:71)
SEVERE: at org.postgresql.core.PGStream.ReceiveChar(PGStream.java:272)
SEVERE: at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1700)
SEVERE: at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:255)
SEVERE: ... 4 more
INFO: org.postgresql.util.PSQLException: This connection has been closed.
INFO: at org.postgresql.jdbc2.AbstractJdbc2Connection.checkClosed(AbstractJdbc2Connection.java:823)
INFO: at org.postgresql.jdbc2.AbstractJdbc2Connection.rollback(AbstractJdbc2Connection.java:840)
INFO: at forum.ViewsThread.run(ViewsThread.java:86)
INFO: SQLException: SQLState(08003)
SEVERE: org.postgresql.util.PSQLException: This connection has been closed.
at org.postgresql.jdbc2.AbstractJdbc2Connection.checkClosed(AbstractJdbc2Connection.java:823)
at org.postgresql.jdbc2.AbstractJdbc2Connection.rollback(AbstractJdbc2Connection.java:840)
at forum.ViewsThread.run(ViewsThread.java:86)
SEVERE: at org.postgresql.jdbc2.AbstractJdbc2Connection.checkClosed(AbstractJdbc2Connection.java:823)
SEVERE: at org.postgresql.jdbc2.AbstractJdbc2Connection.rollback(AbstractJdbc2Connection.java:840)
SEVERE: at forum.ViewsThread.run(ViewsThread.java:86)
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2012-06-11 02:28 Craig Ringer <ringerc@ringerc.id.au>
0 siblings, 1 reply; 27+ messages in thread
From: Craig Ringer @ 2012-06-11 02:28 UTC (permalink / raw)
To: wbrana@gmail.com; pgsql-jdbc
On 06/10/2012 05:05 PM, wbrana@gmail.com wrote:
> The following bug has been logged on the website:
>
> Bug reference: 6684
> Logged by: wbrana
> Email address: wbrana@gmail.com
> PostgreSQL version: 9.1.4
> Operating system: Linux
> Description:
>
> I tried to post this to pgsql-jdbc, but it was blocked.
Check the PostgreSQL *server* logs, see if the connection got closed
server-side and if so why.
--
Craig Ringer
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2012-06-11 10:14 wbrana <wbrana@gmail.com>
parent: Craig Ringer <ringerc@ringerc.id.au>
0 siblings, 0 replies; 27+ messages in thread
From: wbrana @ 2012-06-11 10:14 UTC (permalink / raw)
To: Craig Ringer <ringerc@ringerc.id.au>; +Cc: pgsql-jdbc
On Mon, Jun 11, 2012 at 4:28 AM, Craig Ringer <ringerc@ringerc.id.au> wrote:
>
>
> Check the PostgreSQL *server* logs, see if the connection got closed
> server-side and if so why.
>
> --
> Craig Ringer
2012-06-11 11:36:55.511
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,54,"PARSE",2012-06-11
11:36:55 CEST,10/3,6291,DEBUG,00000,"parse <unnamed>: analyze
posts",,,,,,"analyze posts",,"exec_parse_message, postgres.c:1146",""
2012-06-11 11:36:55.511
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,55,"PARSE",2012-06-11
11:36:55 CEST,10/3,6291,DEBUG,00000,"StartTransactionCommand",,,,,,"analyze
posts",,"start_xact_command, postgres.c:2426",""
2012-06-11 11:36:55.511
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,56,"PARSE",2012-06-11
11:36:55 CEST,10/3,6291,DEBUG,00000,"bind <unnamed> to
<unnamed>",,,,,,,,"exec_bind_message, postgres.c:1429",""
2012-06-11 11:36:55.511
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,57,"ANALYZE",2012-06-11
11:36:55 CEST,10/3,6291,LOG,00000,"execute <unnamed>: analyze
posts",,,,,,,,"exec_execute_message, postgres.c:1940",""
2012-06-11 11:36:55.511
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,58,"ANALYZE",2012-06-11
11:36:55 CEST,10/3,6291,DEBUG,00000,"ProcessUtility",,,,,,"analyze
posts",,"PortalRunUtility, pquery.c:1153",""
2012-06-11 11:36:55.511
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,59,"ANALYZE",2012-06-11
11:36:55 CEST,10/3,6291,DEBUG,00000,"analyzing
""forum.posts""",,,,,,"analyze posts",,"do_analyze_rel,
analyze.c:292",""
2012-06-11 11:36:55.532
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,91,"PARSE",2012-06-11
11:36:49 CEST,2/0,0,DEBUG,00000,"parse <unnamed>: SELECT forum_id,
cat_id, cat_name, forum_description, forum_name, login, post_count,
post_created, thread_count, thread_name FROM v_forums",,,,,,"SELECT
forum_id, cat_id, cat_name, forum_description, forum_name, login,
post_count, post_created, thread_count, thread_name FROM
v_forums",,"exec_parse_message, postgres.c:1146",""
2012-06-11 11:36:55.532
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,92,"PARSE",2012-06-11
11:36:49 CEST,2/0,0,DEBUG,00000,"StartTransactionCommand",,,,,,"SELECT
forum_id, cat_id, cat_name, forum_description, forum_name, login,
post_count, post_created, thread_count, thread_name FROM
v_forums",,"start_xact_command, postgres.c:2426",""
2012-06-11 11:36:55.532
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,93,"PARSE",2012-06-11
11:36:49 CEST,2/14,0,DEBUG,00000,"StartTransaction",,,,,,"SELECT
forum_id, cat_id, cat_name, forum_description, forum_name, login,
post_count, post_created, thread_count, thread_name FROM
v_forums",,"ShowTransactionState, xact.c:4316",""
2012-06-11 11:36:55.532
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,94,"PARSE",2012-06-11
11:36:49 CEST,2/14,0,DEBUG,00000,"name: unnamed; blockState:
DEFAULT; state: INPROGR, xid/subid/cid: 0/1/0, nestlvl: 1, children:
",,,,,,"SELECT forum_id, cat_id, cat_name, forum_description,
forum_name, login, post_count, post_created, thread_count, thread_name
FROM v_forums",,"ShowTransactionStateRec, xact.c:4354",""
2012-06-11 11:36:55.535
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,95,"PARSE",2012-06-11
11:36:49 CEST,2/14,0,DEBUG,00000,"bind <unnamed> to
<unnamed>",,,,,,,,"exec_bind_message, postgres.c:1429",""
2012-06-11 11:36:55.535
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,96,"SELECT",2012-06-11
11:36:49 CEST,2/14,0,LOG,00000,"execute <unnamed>: SELECT forum_id,
cat_id, cat_name, forum_description, forum_name, login, post_count,
post_created, thread_count, thread_name FROM
v_forums",,,,,,,,"exec_execute_message, postgres.c:1940",""
2012-06-11 11:36:55.535
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,97,"SELECT",2012-06-11
11:36:49 CEST,2/14,0,DEBUG,00000,"CommitTransactionCommand",,,,,,,,"finish_xact_command,
postgres.c:2450",""
2012-06-11 11:36:55.535
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,98,"SELECT",2012-06-11
11:36:49 CEST,2/14,0,DEBUG,00000,"CommitTransaction",,,,,,,,"ShowTransactionState,
xact.c:4316",""
2012-06-11 11:36:55.535
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,99,"SELECT",2012-06-11
11:36:49 CEST,2/14,0,DEBUG,00000,"name: unnamed; blockState:
STARTED; state: INPROGR, xid/subid/cid: 0/1/0, nestlvl: 1, children:
",,,,,,,,"ShowTransactionStateRec, xact.c:4354",""
2012-06-11 11:36:55.539
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,100,"PARSE",2012-06-11
11:36:49 CEST,2/0,0,DEBUG,00000,"parse <unnamed>: SET application_name
= ''",,,,,,"SET application_name = ''",,"exec_parse_message,
postgres.c:1146",""
2012-06-11 11:36:55.539
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,101,"PARSE",2012-06-11
11:36:49 CEST,2/0,0,DEBUG,00000,"StartTransactionCommand",,,,,,"SET
application_name = ''",,"start_xact_command, postgres.c:2426",""
2012-06-11 11:36:55.540
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,102,"PARSE",2012-06-11
11:36:49 CEST,2/15,0,DEBUG,00000,"StartTransaction",,,,,,"SET
application_name = ''",,"ShowTransactionState, xact.c:4316",""
2012-06-11 11:36:55.540
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,103,"PARSE",2012-06-11
11:36:49 CEST,2/15,0,DEBUG,00000,"name: unnamed; blockState:
DEFAULT; state: INPROGR, xid/subid/cid: 0/1/0, nestlvl: 1, children:
",,,,,,"SET application_name = ''",,"ShowTransactionStateRec,
xact.c:4354",""
2012-06-11 11:36:55.540
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,104,"PARSE",2012-06-11
11:36:49 CEST,2/15,0,DEBUG,00000,"bind <unnamed> to
<unnamed>",,,,,,,,"exec_bind_message, postgres.c:1429",""
2012-06-11 11:36:55.540
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,105,"SET",2012-06-11
11:36:49 CEST,2/15,0,LOG,00000,"execute <unnamed>: SET
application_name = ''",,,,,,,,"exec_execute_message,
postgres.c:1940",""
2012-06-11 11:36:55.540
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,106,"SET",2012-06-11
11:36:49 CEST,2/15,0,DEBUG,00000,"ProcessUtility",,,,,,"SET
application_name = ''",,"PortalRunUtility, pquery.c:1153",""
2012-06-11 11:36:55.540
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,107,"SET",2012-06-11
11:36:49 CEST,2/15,0,DEBUG,00000,"CommitTransactionCommand",,,,,,,,"finish_xact_command,
postgres.c:2450",""
2012-06-11 11:36:55.540
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,108,"SET",2012-06-11
11:36:49 CEST,2/15,0,DEBUG,00000,"CommitTransaction",,,,,,,,"ShowTransactionState,
xact.c:4316",""
2012-06-11 11:36:55.540
CEST,"forum","forum",5275,"127.0.0.1:40359",4fd5bc31.149b,109,"SET",2012-06-11
11:36:49 CEST,2/15,0,DEBUG,00000,"name: unnamed; blockState:
STARTED; state: INPROGR, xid/subid/cid: 0/1/0, nestlvl: 1, children:
",,,,,,,,"ShowTransactionStateRec, xact.c:4354",""
2012-06-11 11:36:55.614
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,60,"ANALYZE",2012-06-11
11:36:55 CEST,10/3,6291,DEBUG,00000,"""posts"": scanned 12763 of 12763
pages, containing 1200000 live rows and 27 dead rows; 30000 rows in
sample, 1200000 estimated total rows",,,,,,"analyze
posts",,"acquire_sample_rows, analyze.c:1244",""
2012-06-11 11:36:55.868
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,61,"ANALYZE",2012-06-11
11:36:55 CEST,10/3,6291,DEBUG,00000,"tsvector_stats: target # mces =
1000, bucket width = 144285, # lexemes = 45311, hashtable size =
29291, usable entries = 1483",,,,,,"analyze
posts",,"compute_tsvector_stats, ts_typanalyze.c:330",""
2012-06-11 11:36:55.868
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,62,"ANALYZE",2012-06-11
11:36:55 CEST,10/3,6291,LOG,08006,"could not send data to client:
Broken pipe",,,,,,"analyze posts",,"internal_flush, pqcomm.c:1245",""
2012-06-11 11:36:55.873
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,63,"ANALYZE",2012-06-11
11:36:55 CEST,10/3,6291,DEBUG,00000,"CommitTransactionCommand",,,,,,,,"finish_xact_command,
postgres.c:2450",""
2012-06-11 11:36:55.873
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,64,"idle in
transaction",2012-06-11 11:36:55
CEST,10/3,6291,DEBUG,00000,"shmem_exit(0): 7 callbacks to
make",,,,,,,,"shmem_exit, ipc.c:211",""
2012-06-11 11:36:55.873
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,65,"idle in
transaction",2012-06-11 11:36:55 CEST,,0,DEBUG,00000,"proc_exit(0): 4
callbacks to make",,,,,,,,"proc_exit_prepare, ipc.c:183",""
2012-06-11 11:36:55.873
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,66,"idle in
transaction",2012-06-11 11:36:55 CEST,,0,LOG,00000,"disconnection:
session time: 0:00:00.376 user=forum database=forum host=127.0.0.1
port=40370",,,,,,,,"log_disconnections, postgres.c:4375",""
2012-06-11 11:36:55.873
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,67,"idle in
transaction",2012-06-11 11:36:55
CEST,,0,DEBUG,00000,"exit(0)",,,,,,,,"proc_exit, ipc.c:135",""
2012-06-11 11:36:55.873
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,68,"idle in
transaction",2012-06-11 11:36:55 CEST,,0,DEBUG,00000,"shmem_exit(-1):
0 callbacks to make",,,,,,,,"shmem_exit, ipc.c:211",""
2012-06-11 11:36:55.873
CEST,"forum","forum",5345,"127.0.0.1:40370",4fd5bc37.14e1,69,"idle in
transaction",2012-06-11 11:36:55 CEST,,0,DEBUG,00000,"proc_exit(-1): 0
callbacks to make",,,,,,,,"proc_exit_prepare, ipc.c:183",""
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2012-06-11 15:57 Dave Cramer <pg@fastcrypt.com>
parent: wbrana <wbrana@gmail.com>
0 siblings, 0 replies; 27+ messages in thread
From: Dave Cramer @ 2012-06-11 15:57 UTC (permalink / raw)
To: wbrana <wbrana@gmail.com>; +Cc: pgsql-jdbc
Any chance we can see the server logs ?
do you have statement timeout set on the server ?
Dave Cramer
dave.cramer(at)credativ(dot)ca
http://www.credativ.ca
On Sat, Jun 9, 2012 at 7:25 AM, wbrana <wbrana@gmail.com> wrote:
> public Connection getConn(){
> if (conn == null) {
> try {
> Class.forName("org.postgresql.Driver"); //load the driver
> conn = DriverManager.getConnection("jdbc:postgresql://localhost/forum?loglevel=1","forum","forum");
> } catch (Exception e) {
> if (debug) {
> e.printStackTrace();
> }
> }
> }
> return conn;
> }
>
> forum.ViewsThread.run:
> public void run() {
> Connection conn = new Jdbc().getConn();
> try {
> conn.setAutoCommit(false);
> conn.prepareStatement("analyze forum_cats").executeUpdate();
> conn.prepareStatement("analyze forums").executeUpdate();
> conn.prepareStatement("analyze groups").executeUpdate();
> conn.prepareStatement("analyze posts").executeUpdate(); // Line 77
> conn.prepareStatement("analyze threads").executeUpdate();
> conn.prepareStatement("analyze user_groups").executeUpdate();
> conn.prepareStatement("analyze users").executeUpdate();
> conn.commit();
>
> 2012-06-09 12:43:52.654 CEST,,,2285,"",4fd328e8.8ed,1,"",2012-06-09
> 12:43:52 CEST,,0,LOG,00000,"connection received: host=127.0.0.1
> port=55770",,,,,,,,,""
> 2012-06-09 12:43:52.656
> CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,2,"authentication",2012-06-09
> 12:43:52 CEST,10/151,0,LOG,00000,"connection authorized: user=forum
> database=forum",,,,,,,,,""
> 2012-06-09 12:43:52.658
> CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,3,"SET",2012-06-09
> 12:43:52 CEST,10/152,0,LOG,00000,"execute <unnamed>: SET
> extra_float_digits = 3",,,,,,,,,""
> 2012-06-09 12:43:52.668
> CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,4,"BEGIN",2012-06-09
> 12:43:52 CEST,10/153,0,LOG,00000,"execute S_1: BEGIN",,,,,,,,,""
> 2012-06-09 12:43:52.668
> CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,5,"ANALYZE",2012-06-09
> 12:43:52 CEST,10/153,0,LOG,00000,"execute <unnamed>: analyze
> forum_cats",,,,,,,,,""
> 2012-06-09 12:43:52.670
> CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,6,"ANALYZE",2012-06-09
> 12:43:52 CEST,10/153,6274,LOG,00000,"execute <unnamed>: analyze
> forums",,,,,,,,,""
> 2012-06-09 12:43:52.671
> CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,7,"ANALYZE",2012-06-09
> 12:43:52 CEST,10/153,6274,LOG,00000,"execute <unnamed>: analyze
> groups",,,,,,,,,""
> 2012-06-09 12:43:52.671
> CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,8,"ANALYZE",2012-06-09
> 12:43:52 CEST,10/153,6274,LOG,00000,"execute <unnamed>: analyze
> posts",,,,,,,,,""
> 2012-06-09 12:43:52.691
> CEST,"forum","forum",2228,"127.0.0.1:55758",4fd328e4.8b4,8,"SELECT",2012-06-09
> 12:43:48 CEST,2/184,0,LOG,00000,"execute <unnamed>: SELECT forum_id,
> cat_id, cat_name, forum_description, forum_name, login, post_count,
> post_created, thread_count, thread_name FROM v_forums",,,,,,,,,""
> 2012-06-09 12:43:52.696
> CEST,"forum","forum",2228,"127.0.0.1:55758",4fd328e4.8b4,9,"SET",2012-06-09
> 12:43:48 CEST,2/185,0,LOG,00000,"execute <unnamed>: SET
> application_name = ''",,,,,,,,,""
> 2012-06-09 12:43:53.080
> CEST,"forum","forum",2285,"127.0.0.1:55770",4fd328e8.8ed,9,"idle in
> transaction",2012-06-09 12:43:52 CEST,,0,LOG,00000,"disconnection:
> session time: 0:00:00.425 user=forum database=forum host=127.0.0.1
> port=55770",,,,,,,,,""
>
> Launching GlassFish on Felix platform
> INFO: Running GlassFish Version: GlassFish Server Open Source Edition
> 3.1.2 (build 23)
> INFO: Grizzly Framework 1.9.46 started in: 33ms - bound to [0.0.0.0:8181]
> INFO: Grizzly Framework 1.9.46 started in: 29ms - bound to [0.0.0.0:4848]
> INFO: Grizzly Framework 1.9.46 started in: 47ms - bound to [0.0.0.0:8080]
> INFO: Grizzly Framework 1.9.46 started in: 22ms - bound to [0.0.0.0:3700]
> INFO: Grizzly Framework 1.9.46 started in: 15ms - bound to [0.0.0.0:7676]
> INFO: The Admin Console is already installed, but not yet loaded.
> INFO: Registered
> org.glassfish.ha.store.adapter.cache.ShoalBackingStoreProxy for
> persistence-type = replicated in BackingStoreFactoryRegistry
> INFO: Created EjbThreadPoolExecutor with thread-core-pool-size 16
> thread-max-pool-size 32 thread-keep-alive-seconds 60
> thread-queue-capacity 2147483647 allow-core-thread-timeout false
> INFO: SEC1002: Security Manager is OFF.
> INFO: SEC1010: Entering Security Startup Service
> INFO: SEC1143: Loading policy provider
> com.sun.enterprise.security.provider.PolicyWrapper.
> INFO: SEC1115: Realm [admin-realm] of classtype
> [com.sun.enterprise.security.auth.realm.file.FileRealm] successfully
> created.
> INFO: SEC1115: Realm [file] of classtype
> [com.sun.enterprise.security.auth.realm.file.FileRealm] successfully
> created.
> INFO: SEC1115: Realm [certificate] of classtype
> [com.sun.enterprise.security.auth.realm.certificate.CertificateRealm]
> successfully created.
> INFO: SEC1115: Realm [jdbcDigestRealm] of classtype
> [com.sun.enterprise.security.auth.realm.jdbc.JDBCRealm] successfully
> created.
> INFO: SEC1011: Security Service(s) Started Successfully
> INFO: WEB0169: Created HTTP listener [http-listener-1] on host/port
> [0.0.0.0:8080]
> INFO: WEB0169: Created HTTP listener [http-listener-2] on host/port
> [0.0.0.0:8181]
> INFO: WEB0169: Created HTTP listener [admin-listener] on host/port
> [0.0.0.0:4848]
> INFO: WEB0171: Created virtual server [server]
> INFO: WEB0171: Created virtual server [__asadmin]
> INFO: WEB0172: Virtual server [server] loaded default web module []
> INFO: Hibernate Validator 4.2.0.Final
> INFO: EclipseLink, version: Eclipse Persistence Services -
> 2.3.2.v20111125-r10461
> INFO: file:/home/x/NetBeansProjects/forum/build/web/WEB-INF/classes/_forumPU
> login successful
> WARNING: Multiple [2] JMX MBeanServer instances exist, we will use the
> server at index [0] :
> [com.sun.enterprise.v3.admin.DynamicInterceptor@1816407].
> WARNING: JMX MBeanServer in use:
> [com.sun.enterprise.v3.admin.DynamicInterceptor@1816407] from index
> [0]
> WARNING: JMX MBeanServer in use:
> [com.sun.jmx.mbeanserver.JmxMBeanServer@1e2a099] from index [1]
> INFO: EJB5181:Portable JNDI names for EJB ThreadsFacade:
> [java:global/forum/ThreadsFacade,
> java:global/forum/ThreadsFacade!forum.ThreadsFacade]
> INFO: EJB5181:Portable JNDI names for EJB UsersFacade:
> [java:global/forum/UsersFacade,
> java:global/forum/UsersFacade!forum.UsersFacade]
> INFO: EJB5181:Portable JNDI names for EJB ForumsPageFacade:
> [java:global/forum/ForumsPageFacade,
> java:global/forum/ForumsPageFacade!forum.ForumsPageFacade]
> INFO: EJB5181:Portable JNDI names for EJB GroupsFacade:
> [java:global/forum/GroupsFacade,
> java:global/forum/GroupsFacade!forum.GroupsFacade]
> INFO: EJB5181:Portable JNDI names for EJB VPostsFacade:
> [java:global/forum/VPostsFacade!forum.VPostsFacade,
> java:global/forum/VPostsFacade]
> INFO: EJB5181:Portable JNDI names for EJB VThreads2Facade:
> [java:global/forum/VThreads2Facade,
> java:global/forum/VThreads2Facade!forum.VThreads2Facade]
> INFO: EJB5181:Portable JNDI names for EJB VThreadsFacade:
> [java:global/forum/VThreadsFacade,
> java:global/forum/VThreadsFacade!forum.VThreadsFacade]
> INFO: EJB5181:Portable JNDI names for EJB PostsFacade:
> [java:global/forum/PostsFacade,
> java:global/forum/PostsFacade!forum.PostsFacade]
> INFO: EJB5181:Portable JNDI names for EJB ForumCatsFacade:
> [java:global/forum/ForumCatsFacade,
> java:global/forum/ForumCatsFacade!forum.ForumCatsFacade]
> INFO: EJB5181:Portable JNDI names for EJB UserGroupsFacade:
> [java:global/forum/UserGroupsFacade!forum.UserGroupsFacade,
> java:global/forum/UserGroupsFacade]
> INFO: EJB5181:Portable JNDI names for EJB VPostsFacade2:
> [java:global/forum/VPostsFacade2!forum.VPostsFacade2,
> java:global/forum/VPostsFacade2]
> INFO: EJB5181:Portable JNDI names for EJB VUserRoleFacade:
> [java:global/forum/VUserRoleFacade!forum.VUserRoleFacade,
> java:global/forum/VUserRoleFacade]
> INFO: EJB5181:Portable JNDI names for EJB AuthBackingBeanFacade:
> [java:global/forum/AuthBackingBeanFacade!forum.AuthBackingBeanFacade,
> java:global/forum/AuthBackingBeanFacade]
> INFO: WELD-000900 1.1.4 (Final)
> INFO: Initializing Mojarra 2.1.7 (SNAPSHOT 20120206) for context '/forum'
> WARNING: JSF1074: Managed bean named 'customerCRUD' has already been
> registered. Replacing existing managed bean class type
> forum.CustomerCRUD with forum.CustomerCRUD.
> INFO: Monitoring jndi:/server/forum/WEB-INF/faces-config.xml for modifications
> INFO: WEB0671: Loading application [forum] at [/forum]
> INFO: CORE10010: Loading application forum done in 5,708 ms
> INFO: GlassFish Server Open Source Edition 3.1.2 (23) startup time :
> Felix (1,031ms), startup services(6,263ms), total(7,294ms)
> INFO: JMX005: JMXStartupService had Started JMXConnector on JMXService
> URL service:jmx:rmi://localhost:8686/jndi/rmi://localhost:8686/jmxrmi
> INFO: Initiating Jersey application, version 'Jersey: 1.11 12/09/2011 10:27 AM'
> INFO: WEB0169: Created HTTP listener [http-listener-1] on host/port
> [0.0.0.0:8080]
> INFO: Grizzly Framework 1.9.46 started in: 1ms - bound to [0.0.0.0:8080]
> INFO: 12:43:52.653 (9) PostgreSQL 9.2devel JDBC4 (build 1000)
>
> INFO: getConnection returning org.postgresql.Driver
>
> INFO: REST00001: Listening to REST requests at context: /management/domain
> INFO: The Admin Console is already installed, but not yet loaded.
> INFO: The Admin Console is starting. Please wait.
> INFO: org.postgresql.util.PSQLException: An I/O error occured while
> sending to the backend.
>
> INFO: at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:281)
>
> INFO: at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:553)
>
> INFO: at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:415)
>
> INFO: at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:361)
>
> INFO: at forum.ViewsThread.run(ViewsThread.java:77)
>
> INFO: SQLException: SQLState(08006)
>
> SEVERE: org.postgresql.util.PSQLException: An I/O error occured while
> sending to the backend.
> at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:281)
> at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:553)
> at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:415)
> at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:361)
> at forum.ViewsThread.run(ViewsThread.java:77)
> Caused by: java.net.SocketException: Socket closed
> at java.net.SocketInputStream.socketRead0(Native Method)
> at java.net.SocketInputStream.read(SocketInputStream.java:150)
> at java.net.SocketInputStream.read(SocketInputStream.java:121)
> at org.postgresql.core.VisibleBufferedInputStream.readMore(VisibleBufferedInputStream.java:143)
> at org.postgresql.core.VisibleBufferedInputStream.ensureBytes(VisibleBufferedInputStream.java:112)
> at org.postgresql.core.VisibleBufferedInputStream.read(VisibleBufferedInputStream.java:71)
> at org.postgresql.core.PGStream.ReceiveChar(PGStream.java:272)
> at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1700)
> at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:255)
> ... 4 more
>
> SEVERE: at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:281)
> SEVERE: at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:553)
> SEVERE: at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:415)
> SEVERE: at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:361)
> SEVERE: at forum.ViewsThread.run(ViewsThread.java:77)
> SEVERE: Caused by: java.net.SocketException: Socket closed
> SEVERE: at java.net.SocketInputStream.socketRead0(Native Method)
> SEVERE: at java.net.SocketInputStream.read(SocketInputStream.java:150)
> SEVERE: at java.net.SocketInputStream.read(SocketInputStream.java:121)
> SEVERE: at org.postgresql.core.VisibleBufferedInputStream.readMore(VisibleBufferedInputStream.java:143)
> SEVERE: at org.postgresql.core.VisibleBufferedInputStream.ensureBytes(VisibleBufferedInputStream.java:112)
> SEVERE: at org.postgresql.core.VisibleBufferedInputStream.read(VisibleBufferedInputStream.java:71)
> SEVERE: at org.postgresql.core.PGStream.ReceiveChar(PGStream.java:272)
> SEVERE: at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1700)
> SEVERE: at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:255)
> SEVERE: ... 4 more
> INFO: org.postgresql.util.PSQLException: This connection has been closed.
>
> INFO: at org.postgresql.jdbc2.AbstractJdbc2Connection.checkClosed(AbstractJdbc2Connection.java:823)
>
> INFO: at org.postgresql.jdbc2.AbstractJdbc2Connection.rollback(AbstractJdbc2Connection.java:840)
>
> INFO: at forum.ViewsThread.run(ViewsThread.java:86)
>
> INFO: SQLException: SQLState(08003)
>
> SEVERE: org.postgresql.util.PSQLException: This connection has been closed.
> at org.postgresql.jdbc2.AbstractJdbc2Connection.checkClosed(AbstractJdbc2Connection.java:823)
> at org.postgresql.jdbc2.AbstractJdbc2Connection.rollback(AbstractJdbc2Connection.java:840)
> at forum.ViewsThread.run(ViewsThread.java:86)
>
> SEVERE: at org.postgresql.jdbc2.AbstractJdbc2Connection.checkClosed(AbstractJdbc2Connection.java:823)
> SEVERE: at org.postgresql.jdbc2.AbstractJdbc2Connection.rollback(AbstractJdbc2Connection.java:840)
> SEVERE: at forum.ViewsThread.run(ViewsThread.java:86)
>
> --
> Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-jdbc
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2012-06-11 21:22 wbrana <wbrana@gmail.com>
0 siblings, 1 reply; 27+ messages in thread
From: wbrana @ 2012-06-11 21:22 UTC (permalink / raw)
To: pgsql-jdbc
I reproduced error with 64-bit Java.
java version "1.7.0_04"
Java(TM) SE Runtime Environment (build 1.7.0_04-b20)
Java HotSpot(TM) 64-Bit Server VM (build 23.0-b21, mixed mode)
Logs, config, application uploaded
http://www.mediafire.com/?5rnw1v4c0wygqya
Application steps: scroll, click and wait, error occurred in less than
30 seconds
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2012-06-11 21:55 Dave Cramer <pg@fastcrypt.com>
parent: wbrana <wbrana@gmail.com>
0 siblings, 3 replies; 27+ messages in thread
From: Dave Cramer @ 2012-06-11 21:55 UTC (permalink / raw)
To: wbrana <wbrana@gmail.com>; +Cc: pgsql-jdbc
How about a tar file for the downloads. I certainly don't run windows.
Dave Cramer
dave.cramer(at)credativ(dot)ca
http://www.credativ.ca
On Mon, Jun 11, 2012 at 5:22 PM, wbrana <wbrana@gmail.com> wrote:
> I reproduced error with 64-bit Java.
> java version "1.7.0_04"
> Java(TM) SE Runtime Environment (build 1.7.0_04-b20)
> Java HotSpot(TM) 64-Bit Server VM (build 23.0-b21, mixed mode)
> Logs, config, application uploaded
> http://www.mediafire.com/?5rnw1v4c0wygqya
> Application steps: scroll, click and wait, error occurred in less than
> 30 seconds
>
> --
> Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-jdbc
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2012-06-11 22:02 wbrana <wbrana@gmail.com>
parent: Dave Cramer <pg@fastcrypt.com>
2 siblings, 0 replies; 27+ messages in thread
From: wbrana @ 2012-06-11 22:02 UTC (permalink / raw)
To: Dave Cramer <pg@fastcrypt.com>; +Cc: pgsql-jdbc
On Mon, Jun 11, 2012 at 11:55 PM, Dave Cramer <pg@fastcrypt.com> wrote:
> How about a tar file for the downloads. I certainly don't run windows.
trace.7z was created on Linux.
tar.bz2: http://www.mediafire.com/?813ndtzt4o4bmyb
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2012-06-11 22:13 Dave Cramer <pg@fastcrypt.com>
parent: Dave Cramer <pg@fastcrypt.com>
2 siblings, 0 replies; 27+ messages in thread
From: Dave Cramer @ 2012-06-11 22:13 UTC (permalink / raw)
To: wbrana <wbrana@gmail.com>; +Cc: pgsql-jdbc
This
2012-06-11 22:39:24.243
CEST forum forum 26187 127.0.0.1:33646 4fd65776.664b 99 idle 2012-06-11
22:39:18 CEST 0 LOG 0 disconnection: session time: 0:00:06.080
user=forum database=forum host=127.0.0.1
port=33646 log_disconnections, postgres.c:4375
Line shows that someone does a disconnect. Looks like con.close() is
being called by someone.
dave.cramer(at)credativ(dot)ca
http://www.credativ.ca
On Mon, Jun 11, 2012 at 5:55 PM, Dave Cramer <pg@fastcrypt.com> wrote:
> How about a tar file for the downloads. I certainly don't run windows.
>
> Dave Cramer
>
> dave.cramer(at)credativ(dot)ca
> http://www.credativ.ca
>
>
> On Mon, Jun 11, 2012 at 5:22 PM, wbrana <wbrana@gmail.com> wrote:
>> I reproduced error with 64-bit Java.
>> java version "1.7.0_04"
>> Java(TM) SE Runtime Environment (build 1.7.0_04-b20)
>> Java HotSpot(TM) 64-Bit Server VM (build 23.0-b21, mixed mode)
>> Logs, config, application uploaded
>> http://www.mediafire.com/?5rnw1v4c0wygqya
>> Application steps: scroll, click and wait, error occurred in less than
>> 30 seconds
>>
>> --
>> Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org)
>> To make changes to your subscription:
>> http://www.postgresql.org/mailpref/pgsql-jdbc
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2012-06-12 08:04 Craig Ringer <ringerc@ringerc.id.au>
parent: Dave Cramer <pg@fastcrypt.com>
2 siblings, 3 replies; 27+ messages in thread
From: Craig Ringer @ 2012-06-12 08:04 UTC (permalink / raw)
To: Dave Cramer <pg@fastcrypt.com>; +Cc: wbrana <wbrana@gmail.com>; pgsql-jdbc
On 06/12/2012 05:55 AM, Dave Cramer wrote:
> How about a tar file for the downloads. I certainly don't run windows.
Just for the future: 7zip works well on Linux. In fact, I strongly
prefer it to tar+gzip. It offers better compression ratios and much more
robust archive files.
yum install p7zip
apt-get install p7zip-full
Handily, as well as its own native high-compression-ratio archive
format, 7zip deals with all those annoying RARs and ARJs and all that
mess that people send around.
(Digressing somewhat:)
I don't understand why *nix users stick to tar. As a long-time Linux
user, I avoid it and think tar files are obsolete. Creating an archive
then compressing it with a stream cypher means that a one-bit error
renders the archive completely destroyed after the error bit, so it's
not good for backups. The compression ratio offered by tar+gzip is poor,
so it isn't much good for file exchange unless you ditch gzip for bzip2,
which is _really_ slow and still doesn't offer great compression ratios.
Better IMO to stick to zip files, or 7zip when compression ratio
matters. IMO about the only use for tar is if you need to archive device
nodes, POSIX ACLs, xattrs, etc, in which case `star' or GNU tar are
better choices.
--
Craig Ringer
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2012-06-12 09:07 John Lister <john.lister@kickstone.com>
parent: Craig Ringer <ringerc@ringerc.id.au>
2 siblings, 0 replies; 27+ messages in thread
From: John Lister @ 2012-06-12 09:07 UTC (permalink / raw)
To: pgsql-jdbc
On 12/06/2012 09:04, Craig Ringer wrote:
> (Digressing somewhat:)
>
> I don't understand why *nix users stick to tar. As a long-time Linux
> user, I avoid it and think tar files are obsolete. Creating an archive
> then compressing it with a stream cypher means that a one-bit error
> renders the archive completely destroyed after the error bit, so it's
> not good for backups. The compression ratio offered by tar+gzip is
> poor, so it isn't much good for file exchange unless you ditch gzip
> for bzip2, which is _really_ slow and still doesn't offer great
> compression ratios.
>
> Better IMO to stick to zip files, or 7zip when compression ratio
> matters. IMO about the only use for tar is if you need to archive
> device nodes, POSIX ACLs, xattrs, etc, in which case `star' or GNU tar
> are better choices.
>
The only reason I use tar is it preserves user information and
permissions, which AFAIK the others don't (although never used p7zip)
John
--
Get the PriceGoblin Browser Addon
www.pricegoblin.co.uk
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2012-06-12 11:02 wbrana <wbrana@gmail.com>
parent: Craig Ringer <ringerc@ringerc.id.au>
2 siblings, 0 replies; 27+ messages in thread
From: wbrana @ 2012-06-12 11:02 UTC (permalink / raw)
To: pgsql-jdbc
It seems to be Gentoo specific problem.
I can't reproduce with client and server running on OpenSuse 12.1 32-bit or
server running on Gentoo 64-bit and client running on Ubuntu 10.04
32-bit VirtualBox virtual machine.
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2012-06-12 14:16 Glenn Holmer <gholmer@weycogroup.com>
parent: Craig Ringer <ringerc@ringerc.id.au>
2 siblings, 1 reply; 27+ messages in thread
From: Glenn Holmer @ 2012-06-12 14:16 UTC (permalink / raw)
To: pgsql-jdbc
On Tue, 2012-06-12 at 16:04 +0800, Craig Ringer wrote:
> Just for the future: 7zip works well on Linux.
Not to veer *too* far off-topic, but I don't trust any piece of software
whose man page includes something like "CAUTION: this flag does not do
what you think, avoid using it".
--
Glenn Holmer
Weyco Group, Inc.
phone: 414-908-1809
fax: 414-908-1601
^ permalink raw reply [nested|flat] 27+ messages in thread
* Re: An I/O error occured while sending to the backend
@ 2012-06-13 02:17 Craig Ringer <ringerc@ringerc.id.au>
parent: Glenn Holmer <gholmer@weycogroup.com>
0 siblings, 0 replies; 27+ messages in thread
From: Craig Ringer @ 2012-06-13 02:17 UTC (permalink / raw)
To: Glenn Holmer <gholmer@weycogroup.com>; +Cc: pgsql-jdbc
On 06/12/2012 10:16 PM, Glenn Holmer wrote:
> On Tue, 2012-06-12 at 16:04 +0800, Craig Ringer wrote:
>> Just for the future: 7zip works well on Linux.
> Not to veer *too* far off-topic, but I don't trust any piece of software
> whose man page includes something like "CAUTION: this flag does not do
> what you think, avoid using it".
Yikes. I'd never noticed that before; good point.
--
Craig Ringer
^ permalink raw reply [nested|flat] 27+ messages in thread
end of thread, other threads:[~2012-06-13 02:17 UTC | newest]
Thread overview: 27+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2005-01-14 21:59 An I/O error occured while sending to the backend. Stephen McConnell <mcconnell_stephen@yahoo.com>
2005-01-15 07:21 ` Oliver Jowett <oliver@opencloud.com>
2005-01-15 19:57 ` Stephen McConnell <mcconnell_stephen@yahoo.com>
2005-04-06 10:10 An I/O error occured while sending to the backend Anthony Chaffey <anthony@webmediaworks.co.uk>
2005-04-06 16:24 ` Re: An I/O error occured while sending to the backend John R Pierce <pierce@hogranch.com>
2005-04-06 17:35 ` Re: An I/O error occured while sending to the backend Scott Marlowe <smarlowe@g2switchworks.com>
2005-04-07 10:49 ` Re: An I/O error occured while sending to the backend Markus Schaber <schabi@logix-tt.com>
2005-04-07 11:34 ` Re: An I/O error occured while sending to the backend Anthony Chaffey <anthony@webmediaworks.co.uk>
2006-02-14 14:26 An I/O error occured while sending to the backend Radek Jíra <jira@iiprg.cz>
2010-04-06 01:41 An I/O error occured while sending to the backend. Breno BF <brenobfernandes@bsd.com.br>
2010-04-06 04:09 ` Craig Ringer <craig@postnewspapers.com.au>
2010-04-06 15:01 ` Breno BF <brenobfernandes@bsd.com.br>
2010-04-07 10:58 ` Breno BF <brenobfernandes@bsd.com.br>
2010-04-07 12:54 ` Craig Ringer <craig@postnewspapers.com.au>
2012-06-09 11:25 An I/O error occured while sending to the backend wbrana <wbrana@gmail.com>
2012-06-11 15:57 ` Re: An I/O error occured while sending to the backend Dave Cramer <pg@fastcrypt.com>
2012-06-11 02:28 Re: An I/O error occured while sending to the backend Craig Ringer <ringerc@ringerc.id.au>
2012-06-11 10:14 ` Re: An I/O error occured while sending to the backend wbrana <wbrana@gmail.com>
2012-06-11 21:22 Re: An I/O error occured while sending to the backend wbrana <wbrana@gmail.com>
2012-06-11 21:55 ` Re: An I/O error occured while sending to the backend Dave Cramer <pg@fastcrypt.com>
2012-06-11 22:02 ` Re: An I/O error occured while sending to the backend wbrana <wbrana@gmail.com>
2012-06-11 22:13 ` Re: An I/O error occured while sending to the backend Dave Cramer <pg@fastcrypt.com>
2012-06-12 08:04 ` Re: An I/O error occured while sending to the backend Craig Ringer <ringerc@ringerc.id.au>
2012-06-12 09:07 ` Re: An I/O error occured while sending to the backend John Lister <john.lister@kickstone.com>
2012-06-12 11:02 ` Re: An I/O error occured while sending to the backend wbrana <wbrana@gmail.com>
2012-06-12 14:16 ` Re: An I/O error occured while sending to the backend Glenn Holmer <gholmer@weycogroup.com>
2012-06-13 02:17 ` Re: An I/O error occured while sending to the backend Craig Ringer <ringerc@ringerc.id.au>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox