Note that there are some explanatory texts on larger screens.

plurals
  1. POBad gateway 502 after small load test on fastcgi-mono-server through nginx and ServiceStack
    text
    copied!<p>I am trying to run a webservice API with ServiceStack under nginx and fastcgi-mono-server.</p> <p>The server starts fine and the API is up and running. I can see the response times in the browser through ServiceStack profiler and they run under 10ms.</p> <p>But as soon as I do a small load test using "siege" (only 500 requests using 10 connections), I start getting 502 Bad Gateway. And to recover, I have to restart the fastcgi-mono-server.</p> <p>The nginx server is fine. The fastcgi-mono-server is the one that stops responding after this small load.</p> <p>I've tried using both tcp and unix sockets (I am aware of a permissions problem with the unix socket, but I already fixed that). </p> <p>Here are my configurations:</p> <pre><code>server { listen 80; listen local-api.acme.com:80; server_name local-api.acme.com; location / { root /Users/admin/dev/acme/Acme.Api/; index index.html index.htm default.aspx Default.aspx; fastcgi_index Default.aspx; fastcgi_pass unix:/tmp/fastcgi.socket; include /usr/local/etc/nginx/fastcgi_params; } } </code></pre> <p>To start the fastcgi-mono-server:</p> <pre><code>sudo fastcgi-mono-server4 /applications=local-api.acme.com:/:/Users/admin/dev/acme/Acme.Api/ /socket=unix:/tmp/fastcgi.socket /multiplex=True /verbose=True /printlog=True </code></pre> <p>EDIT: I forgot to mention an important detail: I am running this on Mac OS X. </p> <p>I also tested all the possible web server configuration for Mono: console application, apache mod_mono, nginx fast_cgi and proxy_pass modules. All presented the same problem of crashing after a few requests under Mono 3.2.3 + Mac OS X.</p> <p>I was able to test the same configuration on a Linux machine and didn't have any problems there.</p> <p>So it seems it is a Mono/ASP.NET issue when running on Mac OS X.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload