[Zope] Problem with Zodb connections pool

Peter Bengtsson peterbe at gmail.com
Wed Oct 14 07:00:55 EDT 2009


2009/10/14 Tres Seaver <tseaver at palladion.com>:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Claudio Battaglino wrote:
>> Hi all,
>> I've a system with Zope 2.8.8 that since some weeks is very slow.
>> The python process keeps busy the CPU (98-99%) and the memory used by
>> the process is growing up.
>> Every day a script makes a pack of the ZODB and restarts Zope so the
>> Data.fs size is stable (about 350MB).
>>
>> In the event.log I can see many of this warnings:
>> 2009-10-14T11:59:14 WARNING ZODB.DB DB.open() has 8 open connections
>> with a pool_size of 7
>>
>> What does it mean?
>
> Likely something in your application is leaking connections (and
> therefore RAM).  Normally each "worker" thread gets a connection from
> the pool at the start of the request, uses it, and then returns it to
> the pool at the end of the request.
>
> If you are using the default configuration for number of threads (4),
> then something has leaked four connections (assuming your server is busy
> at the time you see that log message).  You should examine the "Debug
> Information" page in the ZMI control panel to get information for
> diagnosing the leak.
>

Tres is right. Use the Debug Information. Especially look for requests
(the last big table) that take longer than 1 second.
The table will provide some information about what request is taking so long.
Additionally/Alternatively you can check out DeadlockDebugger which
you have to install manually for your Zope and you get the same
information but instead of information about the requests you get
tracebacks from within the code that is executing the requests.


>> I can see also some of these messages:
>> 2009-10-14T12:14:16 INFO ZODB.Conflict database conflict error...
>>
>> According to you, are the two messages related?
>
> No.  Conflict errors occur normally, whenever "simultaneous" requests
> cause writes to the same objects.  The request whose transaction commits
> "later" gets retried, up to three times;  if it still conflicts, then
> the request returns an error, and you see the message in your logfile.
>
>
> Tres.
> - --
> ===================================================================
> Tres Seaver          +1 540-429-0999          tseaver at palladion.com
> Palladion Software   "Excellence by Design"    http://palladion.com
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.9 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iEYEARECAAYFAkrVrT4ACgkQ+gerLs4ltQ5HagCeJ1X32zT+LOMasY90fzmBolzR
> Q6MAn3qHhkjENxxr7B24z54fsj4TCfQT
> =ETsW
> -----END PGP SIGNATURE-----
>
> _______________________________________________
> Zope maillist  -  Zope at zope.org
> https://mail.zope.org/mailman/listinfo/zope
> **   No cross posts or HTML encoding!  **
> (Related lists -
>  https://mail.zope.org/mailman/listinfo/zope-announce
>  https://mail.zope.org/mailman/listinfo/zope-dev )
>



-- 
Peter Bengtsson,
work www.fry-it.com
home www.peterbe.com
hobby www.issuetrackerproduct.com
fun crosstips.org


More information about the Zope mailing list