nginx will return 499 when php is too busy

Maxim Dounin mdounin at mdounin.ru
Mon Apr 25 23:11:19 MSD 2011


Hello!

On Mon, Apr 25, 2011 at 05:03:36AM +0200, kalso k. wrote:

> 123.150.182.101 - - [24/Apr/2011:00:15:03 +0800] "GET
> /plus/qzhlove.php?do=1&t=0.7795113758845088 HTTP/1.1" 499 0
> "http://www.qzhlove.com/wenzhang/201119695.html" "-" -
> 
> 218.29.216.133 - - [24/Apr/2011:00:15:06 +0800] "GET /js/tuijian.php
> HTTP/1.1" 499 0 "-" "Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1;
> Trident/4.0; .NET CLR 2.0.50727; .NET CLR 3.0.04506.648; .NET CLR
> 3.5.21022; TheWorld)" -
> 
> 
> it seems that it's not because client closed the connection but php-cgi,
> can I rewrite this error code to 200 or can I request once more.

499 means "client closed the connection before it got something".  
In your case it's probably may be re-spelled as "client bored 
waiting for php to answer and went away".

There is nothing that can be done on server side here, except 
adding more backends and/or optimizing them to handle requests 
faster.

Maxim Dounin



More information about the nginx mailing list