[Mono-list] Some issues with mono 2.0

dugc dugald at dolce.co.uk
Tue Oct 19 05:59:34 EDT 2010

Hi All,

Sorry to reopen an old thread, but I updated my server over the summer and
am still experiencing problems.  My server has two quad core Opterons, 8GB
RAM and RAID 5 and is now running Ubuntu 10.04 and mono 2.4.4~svn151842.

I have split my customers into five groups and each group connects to their
own virtual server. I thought that this would insulate each group from the
others.   It seems that the real problem is that sometimes the 4000
preorders that the system receives between 8.50am and 9.10am (from at most
500 concurrent users) aren't spread out and can suddenly 'spike', going from
around 100 concurrent users to 300 or 400.  When this happens, the maximum
number of requests (which I had set at 150) becomes maxed out and the system
seems gridlocked.  New requests back up quickly and the system just sits
there doing nothing.  At this point restarting the processes etc is
pointless because I now have the full 500 users clicking away trying to
order.  Sometimes it is offline for up to 45 minutes. When it is struggling,
CPU and memory use remain fairly low.  Needless to say, business is

I am using mpm-worker, I have keep alive switched off, and have set the

MonoMaxActiveRequests 40
MonoMaxWaitingRequests 200
MonoMaxActiveRequests wcc1 20
MonoMaxWaitingRequests wcc1 200
MonoMaxActiveRequests wcc2 20
MonoMaxWaitingRequests wcc2 200
MonoMaxActiveRequests berks1 20
MonoMaxWaitingRequests berks1 200
MonoMaxActiveRequests berks2 20
MonoMaxWaitingRequests berks2 200

This seems to be working a bit better, but it has only been in place a few
days and I am worried that the next usage spikes (Friday morning probably)
that it will go down again.  I have set up the /mono page so that I can
watch the processes and see what is happening.  However, it always shows the
max waiting requests as identical to the max active, no matter what I set it
to e.g:

    * Restart Server
    * Stop Accepting Requests
    * 0 requests currently being processed; limit: 40; total: 44034
    * 0 requests currently waiting to be processed; limit: 40

That last limit should read '200' but only reads '40'.  Why is that? I would
like to set the MonoMaxActiveRequests even lower (to around 10) but I am
worried that this would also set the MonoMaxWaitingRequests to the same, and
the short queue would result in dropped requests.

On that subject of maximum active and waiting request limits (and on
THREADS_PER_CPU), I can't seem to find any consistent advice.  In the past I
have been told to reduce the THREADS_PER_CPU to 20 and remove all limits on
active and waiting requests, and the official mono page basically says the
opposite.  I think that these settings are the key to my problems but I am
losing business by playing around with them on a production server.  Can
anyone suggest where I am going wrong?
View this message in context: http://mono.1490590.n4.nabble.com/Some-issues-with-mono-2-0-tp1503708p3001819.html
Sent from the Mono - General mailing list archive at Nabble.com.

More information about the Mono-list mailing list