agora inbox for pljava-dev@postgresql.org
help / color / mirror / Atom feedR: Re: [Pljava-dev] crash due to huge load?
7+ messages / 0 participants
[nested] [flat]
* R: Re: [Pljava-dev] crash due to huge load?
@ 2005-10-29 06:45
2005-10-29 08:35 ` R: Re: [Pljava-dev] crash due to huge load?
0 siblings, 1 reply; 7+ messages in thread
From: @ 2005-10-29 06:45 UTC (permalink / raw)
Thomas,
thanks for your reply. Sorry but I would disagree with your hipotesys
about Log4J: I have used it without any problem (in PLJava Trigger).
The evidence is the fact that if I use my PLJ/Trigger a lot of time (the
same .SQL
script execute, via PSQL, 20 times), without complex-thread behaviour, the
Log4J logs are correctly produced.
But if I enable complex-thread behaviour the pgsrv crash at the
second psql-session execution.
TIA
Roberto Colmegna
---- Messaggio originale ----
Data: Fri Oct 28 20:38:07 CEST 2005
Da: Thomas Hallgren<thomas at tada.se>
A: rcolmegna at tiscali.it
Cc: pljava-dev at gborg.postgresql.org
Ccn:
Ogg.: Re: [Pljava-dev] crash due to huge load?
Roberto,
You have to supply the backend log. This doesn't tell me anything. And
I'm not sure its such a good idea to use log4j with PL/Java. The
standard Java logger (java.util.logging) is configured to use the
backend logging utilities. Use that.
Regards,
Thomas Hallgren
rcolmegna at tiscali.it wrote:
> Hi,
>
> I'm using a recompiled last CVS-checkout of PLJAVA on PG8.0.3 and JDK1.5.0.
>
> I build a thread-oriented trigger (make a thread which build a connection
> to another
> PG).
>
> I obtain frequently this error msg:
>
> server closed the connection unexpectedly
> This probably means the server terminated abnormally
> before or while processing the request.
>
> But I haven't any exception on thread-handled logs (LOG4J).
>
> TIA
> Roberto Colmegna
>
>
> __________________________________________________________________
> TISCALI ADSL
> Solo con Tiscali Adsl navighi senza limiti e telefoni senza canone
> Telecom a partire da 19,95 Euro/mese.
> Attivala subito, I PRIMI DUE MESI SONO GRATIS! CLICCA QUI:
> http://abbonati.tiscali.it/adsl/sa/1e25flat_tc/
>
>
>
> _______________________________________________
> Pljava-dev mailing list
> Pljava-dev at gborg.postgresql.org
> http://gborg.postgresql.org/mailman/listinfo/pljava-dev
>
__________________________________________________________________
TISCALI ADSL
Solo con Tiscali Adsl navighi senza limiti e telefoni senza canone
Telecom a partire da 19,95 Euro/mese.
Attivala subito, I PRIMI DUE MESI SONO GRATIS! CLICCA QUI:
http://abbonati.tiscali.it/adsl/sa/1e25flat_tc/
^ permalink raw reply [nested|flat] 7+ messages in thread
* R: Re: [Pljava-dev] crash due to huge load?
2005-10-29 06:45 R: Re: [Pljava-dev] crash due to huge load?
@ 2005-10-29 08:35 `
0 siblings, 0 replies; 7+ messages in thread
From: @ 2005-10-29 08:35 UTC (permalink / raw)
rcolmegna at tiscali.it wrote:
> Thomas,
>
> thanks for your reply. Sorry but I would disagree with your hipotesys
> about Log4J: I have used it without any problem (in PLJava Trigger).
>
> The evidence is the fact that if I use my PLJ/Trigger a lot of time (the
> same .SQL
> script execute, via PSQL, 20 times), without complex-thread behaviour, the
>
> Log4J logs are correctly produced.
>
>
Yes of course log4j will produce output. That's not what I meant. What I
mean is that:
- the java.util.logging package is well integrated with the PostgreSQL
backend and you can control it using the log_min_messages,
client_min_messages etc. in the postgresql.conf.
- the output will not conflict with the output from the PostgreSQL
logger since one uses the other.
- by setting client_min_messages, you can actually propagate logging to
the client.
- the java.util.logging does pretty much the same tasks as the log4j
logger so you have a lot of redundant code in your backend for no
apparent reason.
- if you want log4j to output to a file, you must use the untrusted
language handler, the trusted handler will not allow log4j to open a file.
> But if I enable complex-thread behaviour the pgsrv crash at the
> second psql-session execution.
>
>
Again, please send the backend log. If you don't want to disclose the
content on this mailing list, send it to me directly.
Regards,
Thomas Hallgren
^ permalink raw reply [nested|flat] 7+ messages in thread
* R: Re: [Pljava-dev] crash due to huge load?
@ 2005-10-29 07:25
0 siblings, 0 replies; 7+ messages in thread
From: @ 2005-10-29 07:25 UTC (permalink / raw)
Hi,
I discovered the critical-point. I systematically obtain a pgsrv-crash if
I launch the same
psql-script two times in the same time.
The crash appear when the two-instance of PL/Java trigger execute a thread.
TIA
Roberto Colmegna
__________________________________________________________________
TISCALI ADSL
Solo con Tiscali Adsl navighi senza limiti e telefoni senza canone
Telecom a partire da 19,95 Euro/mese.
Attivala subito, I PRIMI DUE MESI SONO GRATIS! CLICCA QUI:
http://abbonati.tiscali.it/adsl/sa/1e25flat_tc/
^ permalink raw reply [nested|flat] 7+ messages in thread
* R: Re: [Pljava-dev] crash due to huge load?
@ 2005-10-29 08:43
2005-10-29 08:59 ` R: Re: [Pljava-dev] crash due to huge load?
0 siblings, 1 reply; 7+ messages in thread
From: @ 2005-10-29 08:43 UTC (permalink / raw)
I agree: my implementation isn't a "peferct" mechanism (but 2PC isn't implemented
in PG ;) ) but is acceptable for my needs.
As you request, you could find PG-log attacched.
Thanks a lot for your support.
Regards,
Roberto Colmegna
---- Messaggio originale ----
Data: Sat Oct 29 10:26:39 CEST 2005
Da: Thomas Hallgren<thomas at tada.se>
A: rcolmegna at tiscali.it
Cc: pljava-dev at gborg.postgresql.org
Ccn:
Ogg.: Re: [Pljava-dev] crash due to huge load?
Roberto,
You can never guarantee coherence between two databases unless you use
2-phase commits.
Think "what if I pull the plug at precisely this moment" (i.e. between
#1 and #2 for instance).
Regarding the crash, I would really like to help you find the cause, but
you will have to provide the backend log.
Regards,
Thomas Hallgren
__________________________________________________________________
TISCALI ADSL
Solo con Tiscali Adsl navighi senza limiti e telefoni senza canone
Telecom a partire da 19,95 Euro/mese.
Attivala subito, I PRIMI DUE MESI SONO GRATIS! CLICCA QUI:
http://abbonati.tiscali.it/adsl/sa/1e25flat_tc/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: postgresql-Sat.log
Type: application/octet-stream
Size: 23121 bytes
Desc: not available
URL: <http://lists.pgfoundry.org/pipermail/pljava-dev/attachments/20051029/63afb032/attachment.obj;
^ permalink raw reply [nested|flat] 7+ messages in thread
* R: Re: [Pljava-dev] crash due to huge load?
2005-10-29 08:43 R: Re: [Pljava-dev] crash due to huge load?
@ 2005-10-29 08:59 `
0 siblings, 0 replies; 7+ messages in thread
From: @ 2005-10-29 08:59 UTC (permalink / raw)
Roberto,
Some of you problems stems from the following lines:
ERROR: XX000: java.lang.NoClassDefFoundError:
org/postgresql/core/StartupPacket
ERROR: XX000: java.lang.NoClassDefFoundError:
it/robcol/distribdb/util/SQLIntrospector
You need to find the cause of these errors. You also get a warning from
PL/Java:
WARNING: 01000: 29 Oct 05 09:35:14
org.postgresql.pljava.jdbc.Invocation Closing 1 "forgotten" statement
this indicates that you have prepared statements that you don't close.
Please set the log_min_messages in your postgresql.conf to DEBUG1. That
will reveal some more info.
Regards,
Thomas Hallgren
rcolmegna at tiscali.it wrote:
> I agree: my implementation isn't a "peferct" mechanism (but 2PC isn't implemented
> in PG ;) ) but is acceptable for my needs.
>
> As you request, you could find PG-log attacched.
>
> Thanks a lot for your support.
>
> Regards,
> Roberto Colmegna
>
>
>
> ---- Messaggio originale ----
> Data: Sat Oct 29 10:26:39 CEST 2005
> Da: Thomas Hallgren<thomas at tada.se>
> A: rcolmegna at tiscali.it
> Cc: pljava-dev at gborg.postgresql.org
> Ccn:
> Ogg.: Re: [Pljava-dev] crash due to huge load?
>
> Roberto,
> You can never guarantee coherence between two databases unless you use
> 2-phase commits.
> Think "what if I pull the plug at precisely this moment" (i.e. between
> #1 and #2 for instance).
>
> Regarding the crash, I would really like to help you find the cause, but
>
> you will have to provide the backend log.
>
> Regards,
> Thomas Hallgren
>
>
> __________________________________________________________________
> TISCALI ADSL
> Solo con Tiscali Adsl navighi senza limiti e telefoni senza canone
> Telecom a partire da 19,95 Euro/mese.
> Attivala subito, I PRIMI DUE MESI SONO GRATIS! CLICCA QUI:
> http://abbonati.tiscali.it/adsl/sa/1e25flat_tc/
>
>
>
>
^ permalink raw reply [nested|flat] 7+ messages in thread
* R: Re: [Pljava-dev] crash due to huge load?
@ 2005-10-29 12:09
2005-10-29 12:27 ` R: Re: [Pljava-dev] crash due to huge load?
0 siblings, 1 reply; 7+ messages in thread
From: @ 2005-10-29 12:09 UTC (permalink / raw)
As you requested I sent you other logs.
Note that errors appear only under huge load.
TIA
Roberto Colmegna
---- Messaggio originale ----
Data: Sat Oct 29 10:59:47 CEST 2005
Da: Thomas Hallgren<thomas at tada.se>
A: rcolmegna at tiscali.it
Cc: pljava-dev at gborg.postgresql.org
Ccn:
Ogg.: Re: R: Re: [Pljava-dev] crash due to huge load?
Roberto,
Some of you problems stems from the following lines:
ERROR: XX000: java.lang.NoClassDefFoundError:
org/postgresql/core/StartupPacket
ERROR: XX000: java.lang.NoClassDefFoundError:
it/robcol/distribdb/util/SQLIntrospector
You need to find the cause of these errors. You also get a warning from
PL/Java:
WARNING: 01000: 29 Oct 05 09:35:14
org.postgresql.pljava.jdbc.Invocation Closing 1 "forgotten" statement
this indicates that you have prepared statements that you don't close.
Please set the log_min_messages in your postgresql.conf to DEBUG1. That
will reveal some more info.
Regards,
Thomas Hallgren
__________________________________________________________________
TISCALI ADSL
Solo con Tiscali Adsl navighi senza limiti e telefoni senza canone
Telecom a partire da 19,95 Euro/mese.
Attivala subito, I PRIMI DUE MESI SONO GRATIS! CLICCA QUI:
http://abbonati.tiscali.it/adsl/sa/1e25flat_tc/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: postgresql-Sat.zip
Type: application/x-zip-compressed
Size: 8199 bytes
Desc: not available
URL: <http://lists.pgfoundry.org/pipermail/pljava-dev/attachments/20051029/6da76283/attachment.bin;
^ permalink raw reply [nested|flat] 7+ messages in thread
* R: Re: [Pljava-dev] crash due to huge load?
2005-10-29 12:09 R: Re: [Pljava-dev] crash due to huge load?
@ 2005-10-29 12:27 `
0 siblings, 0 replies; 7+ messages in thread
From: @ 2005-10-29 12:27 UTC (permalink / raw)
Roberto,
Thank you for the logs. Now it starts to get interesting. You get
several normal process terminations from instances that use PL/Java (I
see a couple of _destroyJavaVM which indicates of a normal shutdown) yet
the postmaster consider them crashed processes. I'm not sure why that
happens. You say it only happens under heavy load. Perhaps it's the Java
VM shutdown in itself that crashes somehow. I'll have to investigate
that further. A couple of questions.
1. Are you now using the latest CVS? I.e. if I provide patches, will
you be able to try them out?
2. What kind of system are you on?
3. Would it be possible for you to include a pid or session id included
in the backend trace (use a log_line_prefix with %p in it)? You use
several instances here and it's hard to tell which trace that origins
from which session.
Regards,
Thomas Hallgren
rcolmegna at tiscali.it wrote:
> As you requested I sent you other logs.
>
> Note that errors appear only under huge load.
>
> TIA
> Roberto Colmegna
>
> ---- Messaggio originale ----
> Data: Sat Oct 29 10:59:47 CEST 2005
> Da: Thomas Hallgren<thomas at tada.se>
> A: rcolmegna at tiscali.it
> Cc: pljava-dev at gborg.postgresql.org
> Ccn:
> Ogg.: Re: R: Re: [Pljava-dev] crash due to huge load?
>
> Roberto,
> Some of you problems stems from the following lines:
>
> ERROR: XX000: java.lang.NoClassDefFoundError:
> org/postgresql/core/StartupPacket
> ERROR: XX000: java.lang.NoClassDefFoundError:
> it/robcol/distribdb/util/SQLIntrospector
>
> You need to find the cause of these errors. You also get a warning from
> PL/Java:
>
> WARNING: 01000: 29 Oct 05 09:35:14
> org.postgresql.pljava.jdbc.Invocation Closing 1 "forgotten" statement
>
> this indicates that you have prepared statements that you don't close.
>
> Please set the log_min_messages in your postgresql.conf to DEBUG1. That
> will reveal some more info.
>
> Regards,
> Thomas Hallgren
>
>
>
> __________________________________________________________________
> TISCALI ADSL
> Solo con Tiscali Adsl navighi senza limiti e telefoni senza canone
> Telecom a partire da 19,95 Euro/mese.
> Attivala subito, I PRIMI DUE MESI SONO GRATIS! CLICCA QUI:
> http://abbonati.tiscali.it/adsl/sa/1e25flat_tc/
>
>
>
>
^ permalink raw reply [nested|flat] 7+ messages in thread
end of thread, other threads:[~2005-10-29 12:27 UTC | newest]
Thread overview: 7+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2005-10-29 06:45 R: Re: [Pljava-dev] crash due to huge load?
2005-10-29 08:35 `
2005-10-29 07:25 R: Re: [Pljava-dev] crash due to huge load?
2005-10-29 08:43 R: Re: [Pljava-dev] crash due to huge load?
2005-10-29 08:59 `
2005-10-29 12:09 R: Re: [Pljava-dev] crash due to huge load?
2005-10-29 12:27 `
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox