[Mongrel] Mongrel spinning on read_multipart
Ian C. Blenke
ian at blenke.com
Fri Sep 22 13:04:39 EDT 2006
Zed Shaw wrote:
> On Thu, 2006-09-21 at 20:57 -0400, Ian C. Blenke wrote:
>> On Zed's suggestion, I caught two new spinning mongrels and sent a
>> SIGUSR2. The code appears to be stuck in read_multipart for both processes:
> Hey Ian, can you give me some more information on this?
> 1) What is being uploaded and what are the average sizes and content
XML encapsulated HTML pages from various public websites. Browser
extensions are uploading the pages to a Rails server using a RESTful
JSON based multi-part MIME API post. Some are pretty large, most are
> 2) Does the process stay pegged for a long time (like never ends) or is
> it possible that the mime processing is just taking longer than you
The processes stay pegged for a long time, they never seem to end.
> 3) How often does this happen?
During the early development cycle of the browser extensions, this was a
huge problem, as the developers were sending malformed multi-part MIME
boundaries. Regardless of the size of the submitted webpage, mongrel
would go into a tight spin. After giving each developer a local VMWare
player runtime with the entire application environment to beat up
against, they cleaned up their bugs and the problem "went away".
Today, we're only getting this problem occasionally. On a low volume
site, a couple times a day. It "feels like" the extensions are getting
interrupted midway through their posts to the server (TCP streams reset,
etc), but I haven't verified this conclusively yet.
> 4) Operating system particulars, and Ruby version.
Multicore AMD64X2 4G whitebox servers, a Debian woody based homegrown
distro with many many backports (virtually sarge), linux 2.6.13 kernel.
backported Ruby 1.8.4 (-1, not the newer buggier builds). Rails 1.1.6
- Ian C. Blenke <ian at blenke.com> http://ian.blenke.com/
More information about the Mongrel-users