Re: [Zope-dev] More signal 11 restarts....

2001-12-08 Thread Joseph Wayne Norton


Daniel -

I have **not** tried this myself yet, but I plan to check this week.
Please take a look at the following URL:

  http://www.humanfactor.com/cgi-bin/cgi-delegate/apache-ML/nh/1998/Oct/0130.html

This mail is related to apache but the same analysis might apply to
zope.  I believe the truss command on the solaris platform is similiar
to strace command on the linux platform.

I'm facing similar problems on the solaris platform but the restart is
occuring maybe 2-3 times per day.

regards,

- j


At Mon, 26 Nov 2001 15:47:30 -0200,
Daniel Duclos wrote:
 
 
   I have a zope that is dumping signal 11 every 40 minutes or so. I have tried 
 recompile python 2.1.1 with-threads without-pymalloc, recompile Zope with it, 
 recompile ZPAtterns, recompile and instal MYSQL for Python 0.9.1, upgraded to 
 Zope 2.4.3, all this on a Debian Linux box.
   Nothing changed... still restarting...
   Anybody, please, has any ideia on this matter?
   Please, let me know if there's any relevant info that I forgot to mention 
 abot my case!
   Thanks in advance!!
 
 -- 
 daniel lobato duclos -- [EMAIL PROTECTED] -- http://www.hiperlogica.com.br
 -
 
 ___
 Zope-Dev maillist  -  [EMAIL PROTECTED]
 http://lists.zope.org/mailman/listinfo/zope-dev
 **  No cross posts or HTML encoding!  **
 (Related lists - 
  http://lists.zope.org/mailman/listinfo/zope-announce
  http://lists.zope.org/mailman/listinfo/zope )
 

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



With Oracle as well Re: [Zope-dev] More signal 11 restarts....

2001-12-07 Thread Dario Lopez-Kästen

Matt Kromer wrote:

 We have not been able to reproduce this problem in any deterministic way
 -- and the only people who seem to have it are those who are heavy MySQL
 users; it makes me think there is something in the adapter which is not
 behaving the same way under Python 2.1 than it did under Python 1.5.2.
  I have not looked at the adapter, so I'm making a few guesses as what
 is going wrong.

Well, sorry to disapoint everybody, but we have the same signal 11 restarts
here.

We are using DCO2 latest from CVS and have _very_ high Oracle database
usage.

We have yesterday changed from our solaris box to a linux box and
performance has increased dramatically (the linux box ia a 1.8 GHz P3 :).

also the threading problems we previously had seem to  have dissapeared.

Our current setup:

redhat 7.2
Oracle client 8.1.7
Python 2.1 source compiled --without-pymalloc
Zope 2.4.3 with transparent folders, formulator, replace support, localfs
lastest DCO2

Now, what can we do to pin down the problem. Is there anyone else that is a
heavy databse user on similar circumstances that can share information?

I am starting to suspect that there is some kind of DA problem here...

Also, for the record we usually get a bunch of these quite often:

2001-11-04T09:04:33 ERROR(200) ZServer uncaptured
  python exception, closing channel zhttp_channel connected
  XXX.XXX.XXX.XXX:2181 at fb4edc channel#: 2286 requests:4
  (socket.error:(32, 'Broken pipe')

[/usr/local/zope/dist/Zope-2.4.1/ZServer/medusa/asynchat.py|initiate_send|21
4] [/usr/local/zope/dist/Zope-2.4.1/ZServer/medusa/http_server.py|send|414]
[/usr/local/zope/sw/Python2.1.1/lib/python2.1/asyncore.py|send|330])


We were seeing the same error (asyncore.py|send|330, etc) on solaris.

Any thoughts?

/dario


___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: With Oracle as well Re: [Zope-dev] More signal 11 restarts....

2001-12-07 Thread Matthew T. Kromer

Dario Lopez-Kästen wrote:


Well, sorry to disapoint everybody, but we have the same signal 11 restarts
here.


Oh sure, go spoil my blame it on the other guy theory.

We are using DCO2 latest from CVS and have _very_ high Oracle database
usage.

We have yesterday changed from our solaris box to a linux box and
performance has increased dramatically (the linux box ia a 1.8 GHz P3 :).


That's to be expected with the clock speed differences.  Unless you use 
sun's CC, you get fairly poor SPARC code out of gcc, IMHO.


also the threading problems we previously had seem to  have dissapeared.


Yah!  I think that had to do with the rather *stupid* act of 
forgetfulness on my part to re-enable python threading around execute().



Now, what can we do to pin down the problem. Is there anyone else that is a
heavy databse user on similar circumstances that can share information?


I may see what I can do to try to write a script to be able to invoke 
gdb in the event of a crash.  Stay tuned.


I am starting to suspect that there is some kind of DA problem here...


Actually, since its a mysterious sig 11, it's a C module someplace... 
there is probably ONE module which is referring to an object after it 
has been deallocated.


Also, for the record we usually get a bunch of these quite often:

2001-11-04T09:04:33 ERROR(200) ZServer uncaptured
  python exception, closing channel zhttp_channel connected
  XXX.XXX.XXX.XXX:2181 at fb4edc channel#: 2286 requests:4
  (socket.error:(32, 'Broken pipe')

[/usr/local/zope/dist/Zope-2.4.1/ZServer/medusa/asynchat.py|initiate_send|21
4] [/usr/local/zope/dist/Zope-2.4.1/ZServer/medusa/http_server.py|send|414]
[/usr/local/zope/sw/Python2.1.1/lib/python2.1/asyncore.py|send|330])


We were seeing the same error (asyncore.py|send|330, etc) on solaris.

Any thoughts


Well, that means the browser user clicked 'stop'  -- Medusa is just 
telling you the channel went away on it.  Thats normal when the browser 
chops the tcp connection.




___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists -
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: With Oracle as well Re: [Zope-dev] More signal 11 restarts....

2001-12-07 Thread Dario Lopez-Kästen

 
 
 Well, that means the browser user clicked 'stop'  -- Medusa is just 
 telling you the channel went away on it.  Thats normal when the browser 
 chops the tcp connection.


*looong sigh of relief*

/dario


___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] More signal 11 restarts....

2001-12-06 Thread Gilles Lavaux

Hello

Which config/tool make that your zope restart automatically???

Gilles
-Original Message-
From: Leonardo Rochael Almeida [EMAIL PROTECTED]
To: zope-dev [EMAIL PROTECTED]
Date: Wednesday, December 05, 2001 20:07
Subject: Re: [Zope-dev] More signal 11 restarts




Hi Harald,

On Wed, 2001-12-05 at 14:32, Harald Koschinski wrote:
 Daniel Duclos wrote:

   I have a zope that is dumping signal 11 every 40 minutes or so. I have
tried
 recompile python 2.1.1 with-threads without-pymalloc, recompile Zope
with it,
 recompile ZPAtterns, recompile and instal MYSQL for Python 0.9.1,
upgraded to
 Zope 2.4.3, all this on a Debian Linux box.
   Nothing changed... still restarting...
   Anybody, please, has any ideia on this matter?
   Please, let me know if there's any relevant info that I forgot to
mention
 abot my case!
   Thanks in advance!!
 

 I have the same problem since we are live :-(((

 I have the same versions running like you and I tried  the same to fix -
 but no change.

 What is your state with this problem. Fixed ? How?

It's not fixed, but we managed to make it bearable so as not to lose the
client.

by replacing LoginManager with exUserFolder we managed to bring down the
zope restart time from 5 min (we have a HUGE Data.fs) to 20 secs, and by
installing ZEO we brought down the restart time to between 2 and 8 secs.
By increasing the caching of requests we managed to increase the time
between restart from 15 min to 2 hours. That and a nicely formated
Apache error page for Proxy Errors, for the lucky bastards who happen to
hit the server in the exactly 2 seconds of restart, managed to calm down
the client enough for us to breath.

I'll try the requestprofiler tip Chris gave, but I don't have much hope,
since we use mysql for authentication and the site is authenticated
mostly everywhere.

We are seriously considering droping mysql for postgresql.

 Cheers, Leo

--
Ideas don't stay in some minds very long because they don't like
solitary confinement.



___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists -
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )





___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] More signal 11 restarts....

2001-12-06 Thread Leonardo Rochael Almeida

On Thu, 2001-12-06 at 08:43, Gilles Lavaux wrote:
 Hello
 
 Which config/tool make that your zope restart automatically???

Zope itself. Here is a snipet of Z2.py help text for your amusement :-)

  -Z path

Unix only! This option is ignored on windows.

If this option is specified, a separate managemnt process will
be created that restarts Zope after a shutdown (or crash).
The path must point to a pid file that the process will record its
process id in. The path may be relative, in which case it will be
relative to the Zope location.

To prevent use of a separate management process, provide an
empty string: -Z ''




___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: hooking up gdb (was Re: [Zope-dev] More signal 11 restarts....)

2001-12-06 Thread Andy Dustman

On Wed, 2001-12-05 at 15:41, Matthew T. Kromer wrote:
 Leonardo Rochael Almeida wrote:
 
 We aren't getting any core files, even after setting ulimit correctly
 (although we could be setting it uncorrectly. I'll look into that
 further). Anyway, someone else in this list said that core dumps for
 threaded apps in Linux were mostly useless, so we aren't investing much
 energy in it anyway.
 
 With the short restart times we have, I'd prever a solution that didn't
 involve keeping a dead site dead for too long (as in, debugging with
 gdb). We are working in a ZEO scheme that would switch over the
 accelerator to proxy another zeo client, but we are not there yet.
 
 It would be ideal if we could instruct python to grab the SIG11, invoke
 gdb, get a C stacktrace for all threads and let Zope die in peace. If it
 all happend in a few seconds, we will still keep the client happy.
 
 Well largely, ALL I want is the backtrace -- and I'm wondering if I 
 could cobble something together that could get it.  The problem is it 
 needs to look at the symbol table, and I dont know how to get at that 
 via C -- ie, gdb doesnt have an interface that I know of that you can 
 link in to grab a stack trace and exit.

If you don't think a core dump is going to be useful, gdb isn't going to
be either.

I know I have gotten Zope to dump core before, and I think I did this
with -Z '', i.e. don't start a management process. Then you need some
other way to start Zope when it dies.

As for ZMySQLDA/MySQLdb, I do know that the MySQL client libraries will
crash if you try use the same connection more than once simultaneously
in two different threads. I have never quite been sure whether or not
there is some kind of locking in Zope to prevent threads from
simultaneously using two database connections, since I expect this would
cause problems on virtually all implementations.

-- 
Andy Dustman PGP: 0x930B8AB6
@   .net http://dustman.net/andy
You can have my keys when you pry them from my dead, cold neurons.


___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: hooking up gdb (was Re: [Zope-dev] More signal 11 restarts....)

2001-12-06 Thread Matthew T. Kromer

Andy Dustman wrote:


If you don't think a core dump is going to be useful, gdb isn't going to
be either.


Well, the problem is on Linux, the core file is from the process that 
received the SIG11, not the one that caused it, in most cases (due to 
the way Linux implements threads).  To the best of my knowledge, the 
core does NOT contain the necessary registers of the remaining threads; 
thus gdb can't show you which thread dumped core.

However, attaching gdb to the running zope usually does work, since gdb 
can inspect the processes when they are running to get the thread 
information.





___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] More signal 11 restarts....

2001-12-05 Thread Harald Koschinski

Daniel Duclos wrote:

   I have a zope that is dumping signal 11 every 40 minutes or so. I have tried 
recompile python 2.1.1 with-threads without-pymalloc, recompile Zope with it, 
recompile ZPAtterns, recompile and instal MYSQL for Python 0.9.1, upgraded to 
Zope 2.4.3, all this on a Debian Linux box.
   Nothing changed... still restarting...
   Anybody, please, has any ideia on this matter?
   Please, let me know if there's any relevant info that I forgot to mention 
abot my case!
   Thanks in advance!!


I have the same problem since we are live :-(((

I have the same versions running like you and I tried  the same to fix - 
but no change.

What is your state with this problem. Fixed ? How?

regards

Harald




___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] More signal 11 restarts....

2001-12-05 Thread Chris McDonough

You folks should turn on big M logging (via -M) and see if you see a
pattern to when the system dumps core.  You can use the
utilities/requestprofiler script to analyze the big M log.

- Original Message -
From: Harald Koschinski [EMAIL PROTECTED]
To: Daniel Duclos [EMAIL PROTECTED]; zope-dev
[EMAIL PROTECTED]
Sent: Wednesday, December 05, 2001 11:32 AM
Subject: Re: [Zope-dev] More signal 11 restarts


 Daniel Duclos wrote:

  I have a zope that is dumping signal 11 every 40 minutes or so. I
have tried
 recompile python 2.1.1 with-threads without-pymalloc, recompile
Zope with it,
 recompile ZPAtterns, recompile and instal MYSQL for Python 0.9.1,
upgraded to
 Zope 2.4.3, all this on a Debian Linux box.
  Nothing changed... still restarting...
  Anybody, please, has any ideia on this matter?
  Please, let me know if there's any relevant info that I forgot to
mention
 abot my case!
  Thanks in advance!!
 

 I have the same problem since we are live :-(((

 I have the same versions running like you and I tried  the same to
fix -
 but no change.

 What is your state with this problem. Fixed ? How?

 regards

 Harald




 ___
 Zope-Dev maillist  -  [EMAIL PROTECTED]
 http://lists.zope.org/mailman/listinfo/zope-dev
 **  No cross posts or HTML encoding!  **
 (Related lists -
  http://lists.zope.org/mailman/listinfo/zope-announce
  http://lists.zope.org/mailman/listinfo/zope )



___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] More signal 11 restarts....

2001-12-05 Thread Leonardo Rochael Almeida

Hi Harald,

On Wed, 2001-12-05 at 14:32, Harald Koschinski wrote:
 Daniel Duclos wrote:
 
  I have a zope that is dumping signal 11 every 40 minutes or so. I have tried 
 recompile python 2.1.1 with-threads without-pymalloc, recompile Zope with it, 
 recompile ZPAtterns, recompile and instal MYSQL for Python 0.9.1, upgraded to 
 Zope 2.4.3, all this on a Debian Linux box.
  Nothing changed... still restarting...
  Anybody, please, has any ideia on this matter?
  Please, let me know if there's any relevant info that I forgot to mention 
 abot my case!
  Thanks in advance!!
 
 
 I have the same problem since we are live :-(((
 
 I have the same versions running like you and I tried  the same to fix - 
 but no change.
 
 What is your state with this problem. Fixed ? How?

It's not fixed, but we managed to make it bearable so as not to lose the
client.

by replacing LoginManager with exUserFolder we managed to bring down the
zope restart time from 5 min (we have a HUGE Data.fs) to 20 secs, and by
installing ZEO we brought down the restart time to between 2 and 8 secs.
By increasing the caching of requests we managed to increase the time
between restart from 15 min to 2 hours. That and a nicely formated
Apache error page for Proxy Errors, for the lucky bastards who happen to
hit the server in the exactly 2 seconds of restart, managed to calm down
the client enough for us to breath.

I'll try the requestprofiler tip Chris gave, but I don't have much hope,
since we use mysql for authentication and the site is authenticated
mostly everywhere.

We are seriously considering droping mysql for postgresql.

Cheers, Leo

-- 
Ideas don't stay in some minds very long because they don't like
solitary confinement.



___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] More signal 11 restarts....

2001-12-05 Thread Leonardo Rochael Almeida

Sorry, I made an incorrect statement. see below.

On Wed, 2001-12-05 at 17:26, Leonardo Rochael Almeida wrote:
 Hi Harald,
 
 On Wed, 2001-12-05 at 14:32, Harald Koschinski wrote:
  Daniel Duclos wrote:
  
 I have a zope that is dumping signal 11 every 40 minutes or so. I have tried 
  recompile python 2.1.1 with-threads without-pymalloc, recompile Zope with it, 
  recompile ZPAtterns, recompile and instal MYSQL for Python 0.9.1, upgraded to 
  Zope 2.4.3, all this on a Debian Linux box.
 Nothing changed... still restarting...
 Anybody, please, has any ideia on this matter?
 Please, let me know if there's any relevant info that I forgot to mention 
  abot my case!
 Thanks in advance!!
  
  
  I have the same problem since we are live :-(((
  
  I have the same versions running like you and I tried  the same to fix - 
  but no change.
  
  What is your state with this problem. Fixed ? How?
 
 It's not fixed, but we managed to make it bearable so as not to lose the
 client.
 
 by replacing LoginManager with exUserFolder we managed to bring down the
 zope restart time from 5 min (we have a HUGE Data.fs) to 20 secs, and by
 installing ZEO we brought down the restart time to between 2 and 8 secs.
 By increasing the caching of requests we managed to increase the time
 between restart from 15 min to 2 hours.

that is incorrect. by recompiling Python without pymalloc we increased
the time between restart from 15 min to 40 min, and by caching SQL
requests we increased the time further to 2h between restarts.

 That and a nicely formated
 Apache error page for Proxy Errors, for the lucky bastards who happen to
 hit the server in the exactly 2 seconds of restart, managed to calm down
 the client enough for us to breath.
 
 I'll try the requestprofiler tip Chris gave, but I don't have much hope,
 since we use mysql for authentication and the site is authenticated
 mostly everywhere.
 
 We are seriously considering droping mysql for postgresql.
 

-- 
Ideas don't stay in some minds very long because they don't like
solitary confinement.



___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] More signal 11 restarts....

2001-12-05 Thread Matthew T. Kromer

Leonardo Rochael Almeida wrote:


It's not fixed, but we managed to make it bearable so as not to lose the
client.

by replacing LoginManager with exUserFolder we managed to bring down the
zope restart time from 5 min (we have a HUGE Data.fs) to 20 secs, and by
installing ZEO we brought down the restart time to between 2 and 8 secs.
By increasing the caching of requests we managed to increase the time
between restart from 15 min to 2 hours. That and a nicely formated
Apache error page for Proxy Errors, for the lucky bastards who happen to
hit the server in the exactly 2 seconds of restart, managed to calm down
the client enough for us to breath.

I'll try the requestprofiler tip Chris gave, but I don't have much hope,
since we use mysql for authentication and the site is authenticated
mostly everywhere.

We are seriously considering droping mysql for postgresql.

   Cheers, Leo



Leo,

Are you comfortable with hooking up gdb to Zope to try to catch this?  I 
suspect, but do not know, that the MySQL python adapter is probably  not 
doing something right w.r.t. memory management.  Unfortunately, it is 
probably also the case that the problem only occurs with high-volume 
traffic -- particularly if it is a timing related bug.

We have not been able to reproduce this problem in any deterministic way 
-- and the only people who seem to have it are those who are heavy MySQL 
users; it makes me think there is something in the adapter which is not 
behaving the same way under Python 2.1 than it did under Python 1.5.2. 
 I have not looked at the adapter, so I'm making a few guesses as what 
is going wrong.


___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



hooking up gdb (was Re: [Zope-dev] More signal 11 restarts....)

2001-12-05 Thread Leonardo Rochael Almeida

Well, one of the things I was going to ask next was for some help doing
postmortem.

We aren't getting any core files, even after setting ulimit correctly
(although we could be setting it uncorrectly. I'll look into that
further). Anyway, someone else in this list said that core dumps for
threaded apps in Linux were mostly useless, so we aren't investing much
energy in it anyway.

With the short restart times we have, I'd prever a solution that didn't
involve keeping a dead site dead for too long (as in, debugging with
gdb). We are working in a ZEO scheme that would switch over the
accelerator to proxy another zeo client, but we are not there yet.

It would be ideal if we could instruct python to grab the SIG11, invoke
gdb, get a C stacktrace for all threads and let Zope die in peace. If it
all happend in a few seconds, we will still keep the client happy.

So, to answer your question, yes, I am confortable hooking up gdb. I'd
just prefer if it could be done in as little time as possible.

Cheers, Leo

On Wed, 2001-12-05 at 18:10, Matthew T. Kromer wrote:
 
 Leo,
 
 Are you comfortable with hooking up gdb to Zope to try to catch this?  I 
 suspect, but do not know, that the MySQL python adapter is probably  not 
 doing something right w.r.t. memory management.  Unfortunately, it is 
 probably also the case that the problem only occurs with high-volume 
 traffic -- particularly if it is a timing related bug.
 
 We have not been able to reproduce this problem in any deterministic way 
 -- and the only people who seem to have it are those who are heavy MySQL 
 users; it makes me think there is something in the adapter which is not 
 behaving the same way under Python 2.1 than it did under Python 1.5.2. 
  I have not looked at the adapter, so I'm making a few guesses as what 
 is going wrong.
 
 
-- 
Ideas don't stay in some minds very long because they don't like
solitary confinement.



___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: hooking up gdb (was Re: [Zope-dev] More signal 11 restarts....)

2001-12-05 Thread Matthew T. Kromer

Leonardo Rochael Almeida wrote:

Well, one of the things I was going to ask next was for some help doing
postmortem.

We aren't getting any core files, even after setting ulimit correctly
(although we could be setting it uncorrectly. I'll look into that
further). Anyway, someone else in this list said that core dumps for
threaded apps in Linux were mostly useless, so we aren't investing much
energy in it anyway.

With the short restart times we have, I'd prever a solution that didn't
involve keeping a dead site dead for too long (as in, debugging with
gdb). We are working in a ZEO scheme that would switch over the
accelerator to proxy another zeo client, but we are not there yet.

It would be ideal if we could instruct python to grab the SIG11, invoke
gdb, get a C stacktrace for all threads and let Zope die in peace. If it
all happend in a few seconds, we will still keep the client happy.

So, to answer your question, yes, I am confortable hooking up gdb. I'd
just prefer if it could be done in as little time as possible.

   Cheers, Leo



Well largely, ALL I want is the backtrace -- and I'm wondering if I 
could cobble something together that could get it.  The problem is it 
needs to look at the symbol table, and I dont know how to get at that 
via C -- ie, gdb doesnt have an interface that I know of that you can 
link in to grab a stack trace and exit.

Its been a while since I prowled the gdb source.  I may not be able to 
do anything automatic like you want -- but I sure wish that tool was 
available!



___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: hooking up gdb (was Re: [Zope-dev] More signal 11 restarts....)

2001-12-05 Thread Dieter Maurer

Matthew T. Kromer writes:
  ...
  Well largely, ALL I want is the backtrace -- and I'm wondering if I 
  could cobble something together that could get it.  The problem is it 
  needs to look at the symbol table, and I dont know how to get at that 
  via C -- ie, gdb doesnt have an interface that I know of that you can 
  link in to grab a stack trace and exit.
I seem to remember that one can define gdb commands that are executed
whenever the program stops.

It this were true, we could activate such a definition in a .gdbinit
file and then run the program.
When the Python stops due to a signal, the command would be activated.
It would make a backtrace followed by a quit.

Not sure, it will work, though...


Dieter

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] More signal 11 restarts....

2001-11-27 Thread Matthew T. Kromer

The only real suggestion I have is to attach the debugger to a running 
thread and hope it hits the fault while the debugger is attached.  Linux 
core files are difficult to impossible to debug when threading is 
active.  The 2.4 kernels may have addressed this some but I dont know 
that gdb has caught up.


On Monday, November 26, 2001, at 12:47 PM, Daniel Duclos wrote:


   I have a zope that is dumping signal 11 every 40 minutes or so. I 
 have tried
 recompile python 2.1.1 with-threads without-pymalloc, recompile Zope 
 with it,
 recompile ZPAtterns, recompile and instal MYSQL for Python 0.9.1, 
 upgraded to
 Zope 2.4.3, all this on a Debian Linux box.
   Nothing changed... still restarting...
   Anybody, please, has any ideia on this matter?
   Please, let me know if there's any relevant info that I forgot to 
 mention
 abot my case!
   Thanks in advance!!

 --
 daniel lobato duclos -- [EMAIL PROTECTED] -- 
 http://www.hiperlogica.com.br
 -

 ___
 Zope-Dev maillist  -  [EMAIL PROTECTED]
 http://lists.zope.org/mailman/listinfo/zope-dev
 **  No cross posts or HTML encoding!  **
 (Related lists -
  http://lists.zope.org/mailman/listinfo/zope-announce
  http://lists.zope.org/mailman/listinfo/zope )


___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] More signal 11 restarts....

2001-11-27 Thread Dieter Maurer

Daniel Duclos writes:
   I have a zope that is dumping signal 11 every 40 minutes or so. I have tried 
  recompile python 2.1.1 with-threads without-pymalloc, recompile Zope with it, 
  recompile ZPAtterns, recompile and instal MYSQL for Python 0.9.1, upgraded to 
  Zope 2.4.3, all this on a Debian Linux box.
   Nothing changed... still restarting...
   Anybody, please, has any ideia on this matter?
I would enable core writing (if they are not already enabled),
this is done with the ulimit/limit shell command.

Then, the SIG 11 will create core files that can be analysed with
a debugger. This may help localize the problem...


Dieter

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )