Oh, I just found that you corrected this in 1.3.x version. Sorry for this redundant post.by leki75 - Nginx Mailing List - English
Hi, I found that giving prefix as command line parameter and the prefix does not start with '/' you append a '/' to prefix (version: 1.2.3): $ /usr/sbin/nginx -p prefix -c nginx.conf nginx: open() "prefix/nginx.conf" failed (2: No such file or directory) $ /usr/sbin/nginx -p prefix/ -c nginx.conf nginx: open() "prefix//nginx.conf" failed (2: No such file or directoby leki75 - Nginx Mailing List - English
Dear Maxim, thank you for your suggestions. Analyzing the code the following turned out about http_write_filter: 1. it is able to buffer output (eg. postpone_output) 2. can delay response before sending bytes (limit <= 0) 3. delays response after sending bytes (nsent - sent) As you mentioned we delay sending the last byte of the response and only do millisecond calculation when sendingby leki75 - Nginx Mailing List - English
Dear Maxim, thank you for your reply. I changed the code you suggested: 1. changed ngx_cached_time to ngx_timeofday() 2. added 1ms to send some bytes at request start --- src/http/ngx_http_write_filter_module.c 2012-01-18 16:07:43.000000000 +0100 +++ src/http/ngx_http_write_filter_module.c.new 2012-07-31 16:38:11.074836346 +0200 @@ -211,8 +211,17 @@ } if (r->limit_rate)by leki75 - Nginx Mailing List - English
Do you mean that requesting /testing/something.php tries to use /home/ian/websites/coachmaster/htsecure/something.php instead of /home/ian/websites/coachmaster/testing/something.php? In the regexp location the document_root is inherited from the server context. I think this would help you: map $reseller $reseller_path { default /home/ian/websites/coachmaster/htsecure; testing /home/ianby leki75 - Nginx Mailing List - English
Hi! We use nginx rate limiting function but realized that it does not work for files smaller than the limit specified in limit_rate directive. Analyzing the source code it turned out that forcing the limit is second based. We modified the source to be able to rate limit more precisely and it also works for smaller files. Here is the patch: leki@szunyog:~/src/agwlimit/nginx-1.2.2$ diff -u srby leki75 - Nginx Mailing List - English
I configured nginx with webdav support. After I try to use davfs access log shows that method is not allowed. Do you plan to support HTTP OPTIONS method? Mount command: # mount -t davfs -o ro,nosuid,nodev,noexec,noaskauth,uid=www-data,gid=www-data \ http://server/data1 /tmp/data1 /sbin/mount.davfs: Mounting failed. 405 Not Allowed access.log: 172.17.172.6 - - [13/Apr/2010by leki75 - Nginx Mailing List - English
Dear Igor, Thanks for your rapid response.by leki75 - Nginx Mailing List - English
Hi all, We would like to use nginx (0.8.15) as a proxy/cache for downloading big files. Wihtout configuring proxy_cache we got '206 Partial Content' for range requests. With proxy_cache the first range request (which is not in cache) will be a '200 OK' and all subsequent range requests (served by cache) are normal '206 Partial Content' responses. Is it possible to have all requests (proxied orby leki75 - Nginx Mailing List - English
Dear Maxim, It works! Thanks very much for your and Igor's help.by leki75 - Nginx Mailing List - English
Dear Igor, I think you misunderstand me. Not the log output is the problem if I want to use eg. proxy_cache than I need to remove the query parameters before caching the content. The request flow should be (so the origin server wont get any query parameters): GET /uri?params HTTP/1.x -> nginx -> GET /uri HTTP/1.x -> origin server More on this, is it possible to modify the requeby leki75 - Nginx Mailing List - English
Hello Igor, I run some tests but it seems that after setting r->args.len=0 and r->args.data=NULL and returning NGX_OK the request arrives at the origin server untouched. Logs on the original server: 172.27.134.40 - - [22/Sep/2009:14:17:42 +0200] "GET /index.html?test=4ab8c062 HTTP/1.0" 404 169 "-" "-" Expected result: 172.27.134.40 - - [22/Sep/2009:1by leki75 - Nginx Mailing List - English
I missed proxy_pass before http://test so the correct line is proxy_pass http://testby leki75 - Nginx Mailing List - English
Hello, I try to write a nginx http module which decides to enable or forbid a HTTP request sent in the request parameters (r->args). At the end of decision I would like to clear the whole args or just a part of it, so won't appear in access.log of the origin server. Is this solution correct without freeing args before? static ngx_int_t ngx_http_leki_test_handler(ngx_http_request_t *r)by leki75 - Nginx Mailing List - English