Needling Threads

Needling Threads by pendragon David Whelan First, the server crashed . . . and crashed . . . . And then I reinstalled Plone, copied over my products and data.fs and got it working again. But it continued to grab all the available virtual memory (Windows 2000) until it no longer responded and then tanked. I did a number of the normal things but also noticed something odd about the threads on Windows that I haven’t seen documented anywhere else.

First, of course, I dumped a lot of the recently installed products that I’d been fooling around with.  This, after reading about some archetype and index-related tools that might cause memory leaks.  Then I cut a few more, to make sure my house was as clean as possible.

But I also noticed that, under the Windows task manager that lists processes, that Plone was holding 6 threads.  I make the uninformed assumption that those are the same threads that I can control in my /data/etc/zope.conf file, and it definitely didn’t say 6!  The default was 4 and I’d taken it, leaving the option commented out.  Then I changed it, so that it explicitly stated 4.  Still no effect, except a reboot once the virtual memory grab was about 900MB. 

The next change was to make Zope.conf show only 2 thread.  Once I saved and restarted the Plone, my thread count showed 4.  So I reduced it again, to 1 thread.  Now my Windows task manager showed “3” in the thread column.  I still haven’t figured out exactly what the discrepancy is (I know Plone/Zope is heavily supported by our German colleagues, but a US$ to Euro conversion for threads seems a bit off).  In any event, going to 1 thread on a Windows box does not seem to have done anything horrible to my performance (which is not stellar to begin with) and the memory problem has largely disappeared.  

Document Actions

Leave a Reply

Your email address will not be published. Required fields are marked *