aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2008-12-08 14:12:29 +0000
committerIgor Sysoev <igor@sysoev.ru>2008-12-08 14:12:29 +0000
commit38a2933b67a07fe1b1cff867ac1912f9ae60b132 (patch)
tree20221c3e47b5918a0eef73c9dab71f527e2af53b /src
parent4bc0dcf7017066c8921f80753e06a82b814898cb (diff)
downloadnginx-38a2933b67a07fe1b1cff867ac1912f9ae60b132.tar.gz
nginx-38a2933b67a07fe1b1cff867ac1912f9ae60b132.zip
log 503 error reason
Diffstat (limited to 'src')
-rw-r--r--src/http/modules/ngx_http_limit_zone_module.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/http/modules/ngx_http_limit_zone_module.c b/src/http/modules/ngx_http_limit_zone_module.c
index 824803d34..3fc4efada 100644
--- a/src/http/modules/ngx_http_limit_zone_module.c
+++ b/src/http/modules/ngx_http_limit_zone_module.c
@@ -189,6 +189,10 @@ ngx_http_limit_zone_handler(ngx_http_request_t *r)
ngx_shmtx_unlock(&shpool->mutex);
+ ngx_log_error(NGX_LOG_ERR, r->connection->log, 0,
+ "limiting connections by zone \"%V\"",
+ &lzcf->shm_zone->name);
+
return NGX_HTTP_SERVICE_UNAVAILABLE;
}
@@ -206,6 +210,11 @@ ngx_http_limit_zone_handler(ngx_http_request_t *r)
node = ngx_slab_alloc_locked(shpool, n);
if (node == NULL) {
ngx_shmtx_unlock(&shpool->mutex);
+
+ ngx_log_error(NGX_LOG_CRIT, r->connection->log, 0,
+ "could not allocate memory in zone \"%V\"",
+ &lzcf->shm_zone->name);
+
return NGX_HTTP_SERVICE_UNAVAILABLE;
}