# NGINX

**URL:** https://www.ruby-forum.com/c/server/nginx/21.md?page=44

[Latest](https://www.ruby-forum.com/latest.md) · [Categories](https://www.ruby-forum.com/categories.md) · [Tags](https://www.ruby-forum.com/tags.md)

**Page:** 45

---

## [Upstream prematurely closed connection while reading response header from upstream](https://www.ruby-forum.com/t/upstream-prematurely-closed-connection-while-reading-response-header-from-upstream/232568)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 9\
**Last updated:** [December 5, 2014, 10:14am UTC](https://www.ruby-forum.com/t/upstream-prematurely-closed-connection-while-reading-response-header-from-upstream/232568 "2014-12-05T10:14:17Z")

</div>

Hi list, we are seeing sporadic nginx errors “upstream prematurely closed connection while reading response header from upstream” with nginx/1.6.2 which seems to be some kind of race condition. For debugging purposes…

---

## [Need help setting up cache for failover](https://www.ruby-forum.com/t/need-help-setting-up-cache-for-failover/233319)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 3\
**Last updated:** [December 4, 2014, 8:26pm UTC](https://www.ruby-forum.com/t/need-help-setting-up-cache-for-failover/233319 "2014-12-04T20:26:10Z")

</div>

I’m trying to configure my sites to failover to fastcgi\_cache when backends are unavailable – but at the same time I want to return nginx errors (hiding backend errors) Here’s a simplified version of my current confi…

---

## [Custom compilation flag for an nginx module](https://www.ruby-forum.com/t/custom-compilation-flag-for-an-nginx-module/234861)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 4\
**Last updated:** [December 4, 2014, 3:09pm UTC](https://www.ruby-forum.com/t/custom-compilation-flag-for-an-nginx-module/234861 "2014-12-04T15:09:14Z")

</div>

Hi all, Is it possible for an nginx module to define custom compilation switches that add external libs / preprocessor macros ? Is there some example of a module that does it ? Specifically, what I’m trying to do is…

---

## [Nginx-build](https://www.ruby-forum.com/t/nginx-build/233316)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 0\
**Last updated:** [December 3, 2014, 6:46pm UTC](https://www.ruby-forum.com/t/nginx-build/233316 "2014-12-03T18:46:24Z")

</div>

Hello! As I developed a convenient build-tool for nginx, I will introduce it. nginx-build provides a command to nginx seamlessly. If you are interested in it, please see the slide below. – Tatsuhiko Kubo E-Mail…

---

## [What HTTP headers does nginx send to SCGI and FastCGI application servers?](https://www.ruby-forum.com/t/what-http-headers-does-nginx-send-to-scgi-and-fastcgi-application-servers/233301)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 4\
**Last updated:** [December 3, 2014, 3:53pm UTC](https://www.ruby-forum.com/t/what-http-headers-does-nginx-send-to-scgi-and-fastcgi-application-servers/233301 "2014-12-03T15:53:57Z")

</div>

I’ve looked through the nginx source code and couldn’t find a specific list of HTTP headers that nginx passes through to SCGI and FastCGI application servers. I’m writing a simple SCGI and FastCGI application server i…

---

## [Ngx\_cache\_purge-2.2](https://www.ruby-forum.com/t/ngx-cache-purge-2-2/234877)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 0\
**Last updated:** [December 3, 2014, 9:13am UTC](https://www.ruby-forum.com/t/ngx-cache-purge-2-2/234877 "2014-12-03T09:13:43Z")

</div>

Version 2.2 is now available at: http://labs.frickle.com/nginx\_ngx\_cache\_purge/ GitHub repository is available at: Changes: 2014-12-02 VERSION 2.2 \* Fix compatibility with nginx-1.7.8+. 2014-05-19 \* Fix build …

---

## [Nginx-1.7.8](https://www.ruby-forum.com/t/nginx-1-7-8/233297)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 1\
**Last updated:** [December 3, 2014, 8:24am UTC](https://www.ruby-forum.com/t/nginx-1-7-8/233297 "2014-12-03T08:24:09Z")

</div>

Changes with nginx 1.7.8 02 Dec 2014 \*) Change: now the "If-Modified-Since", "If-Range", etc. client request header lines are passed to a backend while caching if nginx knows …

---

## [NGINX module reporting 0 time to access.log](https://www.ruby-forum.com/t/nginx-module-reporting-0-time-to-access-log/233295)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 3\
**Last updated:** [December 2, 2014, 11:17pm UTC](https://www.ruby-forum.com/t/nginx-module-reporting-0-time-to-access-log/233295 "2014-12-02T23:17:37Z")

</div>

Hey all, We’ve written a module to connect NGINX / OpenResty with ZMQ endpoints (GitHub - neloe/ngx\_zmq: An upstream ZeroMQ module for nginx), but all requests through the module report a 0.000 time back to access.log…

---

## [Buffering image in nginx memory server](https://www.ruby-forum.com/t/buffering-image-in-nginx-memory-server/234874)

<div class="topic-metadata">

**Author:** [@alcina](https://www.ruby-forum.com/u/alcina)\
**Replies:** 0\
**Last updated:** [December 2, 2014, 5:44pm UTC](https://www.ruby-forum.com/t/buffering-image-in-nginx-memory-server/234874 "2014-12-02T17:44:25Z")

</div>

I have use case where my multi image upload api should be authenticated (from authentication server )before sending request to concern backend server. But during authentication images remains in memory of nginx server …

---

## [What is wrong live stream http conf](https://www.ruby-forum.com/t/what-is-wrong-live-stream-http-conf/224275)

<div class="topic-metadata">

**Author:** [@aris](https://www.ruby-forum.com/u/aris)\
**Replies:** 1\
**Last updated:** [December 2, 2014, 12:10am UTC](https://www.ruby-forum.com/t/what-is-wrong-live-stream-http-conf/224275 "2014-12-02T00:10:52Z")

</div>

have created the following simple conf … #user nobody; worker\_processes 1; #error\_log logs/error.log; #error\_log logs/error.log notice; #error\_log logs/error.log info; pid logs/nginx.pid; events { wo…

---

## [$time\_iso8601 is not set for invalid HTTP?](https://www.ruby-forum.com/t/time-iso8601-is-not-set-for-invalid-http/233271)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 5\
**Last updated:** [December 1, 2014, 6:41pm UTC](https://www.ruby-forum.com/t/time-iso8601-is-not-set-for-invalid-http/233271 "2014-12-01T18:41:36Z")

</div>

I use the if trick to get timestamped log names: if ($time\_iso8601 ~ “^(\\d{4})-(\\d{2})”) { set $year $1; set $month $2; } access\_log …/access-$year-$month.log combined; However, with nginx/1.4.6 (Ubuntu) I see that…

---

## [Domain Names and directory configuration](https://www.ruby-forum.com/t/domain-names-and-directory-configuration/233216)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 2\
**Last updated:** [November 28, 2014, 7:21pm UTC](https://www.ruby-forum.com/t/domain-names-and-directory-configuration/233216 "2014-11-28T19:21:46Z")

</div>

I’m starting out with nginx and I’m stumbling at something I thought simple, but that I haven’t been able to figure out, yet. I need to map three domain names, each one to its own subdirectory under the document roo…

---

## [NGINX using 100% of the server CPU when testing with Blitz.io](https://www.ruby-forum.com/t/nginx-using-100-of-the-server-cpu-when-testing-with-blitz-io/233246)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 10\
**Last updated:** [November 28, 2014, 3:33pm UTC](https://www.ruby-forum.com/t/nginx-using-100-of-the-server-cpu-when-testing-with-blitz-io/233246 "2014-11-28T15:33:35Z")

</div>

I’m facing an issue here and after six days of looking around I decided to ask for some help here, after all a million heads can think a lot better than one. I have a Ubuntu 14.04 server setup with NGINX, HHVM, PHP5-…

---

## [How to block excluding specific url in nginx?](https://www.ruby-forum.com/t/how-to-block-excluding-specific-url-in-nginx/233242)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 7\
**Last updated:** [November 28, 2014, 1:10am UTC](https://www.ruby-forum.com/t/how-to-block-excluding-specific-url-in-nginx/233242 "2014-11-28T01:10:20Z")

</div>

hi. i have a trouble and question! my current configuration in nginx is like … only “/blah/” url can access… ================================ server { location / { return 403; } location ^~ /blah/ { proxy\_pass h…

---

## [Syslog files per server entry](https://www.ruby-forum.com/t/syslog-files-per-server-entry/233255)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 1\
**Last updated:** [November 28, 2014, 12:09am UTC](https://www.ruby-forum.com/t/syslog-files-per-server-entry/233255 "2014-11-28T00:09:11Z")

</div>

Hi, We use the following: error\_log syslog:server=127.0.0.1,facility=local4,tag=nginx warn; access\_log syslog:server=127.0.0.1,facility=local5,tag=nginx,severity=info main; Just with the default combined format. If…

---

## [Nginx rewrite non-existent files under sub directory with rewrite rules](https://www.ruby-forum.com/t/nginx-rewrite-non-existent-files-under-sub-directory-with-rewrite-rules/233241)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 3\
**Last updated:** [November 27, 2014, 8:22pm UTC](https://www.ruby-forum.com/t/nginx-rewrite-non-existent-files-under-sub-directory-with-rewrite-rules/233241 "2014-11-27T20:22:00Z")

</div>

Hi everyone, I am trying to move a site with a large number (93) of .htaccess files from Apache to Nginx. There are over 800 rewrite rules to convert. To optimize performance, I have decided to place the rules unde…

---

## [Validate Client certificate SDN fields (CN, OU, O, etc..) at Nginx](https://www.ruby-forum.com/t/validate-client-certificate-sdn-fields-cn-ou-o-etc-at-nginx/233221)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 3\
**Last updated:** [November 27, 2014, 9:10am UTC](https://www.ruby-forum.com/t/validate-client-certificate-sdn-fields-cn-ou-o-etc-at-nginx/233221 "2014-11-27T09:10:51Z")

</div>

Hi friends, I’m trying to validate my client certificate SDN fields (CN, OU, O, etc…) at Nginx server. I find so many internet resources for Apache but not Nginx. Does Nginx support validating SDN fields. BTW, I’m us…

---

## [Upgrading mysql and configurating my custom 404.html page](https://www.ruby-forum.com/t/upgrading-mysql-and-configurating-my-custom-404-html-page/233213)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 5\
**Last updated:** [November 26, 2014, 9:24pm UTC](https://www.ruby-forum.com/t/upgrading-mysql-and-configurating-my-custom-404-html-page/233213 "2014-11-26T21:24:27Z")

</div>

I have two problems : Upgrading mysql and configurating my custom 404.html page. I wanted to install an admin page, but need to the consistency of mysql and php version, so I wanted upgrade mysql as the same version …

---

## [Issues with HttpChunkinModule](https://www.ruby-forum.com/t/issues-with-httpchunkinmodule/233235)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 2\
**Last updated:** [November 26, 2014, 4:45pm UTC](https://www.ruby-forum.com/t/issues-with-httpchunkinmodule/233235 "2014-11-26T16:45:30Z")

</div>

Hi, I am trying to set up a nginx server to support chunking. I followed the steps mentioned in the below webpage to use the feature http://wiki.nginx.org/HttpChunkinModule My nginx version is 1.4.1. According to the…

---

## [Default answer at proxy timeout](https://www.ruby-forum.com/t/default-answer-at-proxy-timeout/233243)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 1\
**Last updated:** [November 26, 2014, 3:49pm UTC](https://www.ruby-forum.com/t/default-answer-at-proxy-timeout/233243 "2014-11-26T15:49:23Z")

</div>

Hi together, we have a nginx Server serving our requests. Based on our SLAs we need to answer always in 7ms time. Behind the nginx Server, there is a Java Backend, which we proxy through the nginx. The requirement is…

---

## [How can I forward an IP to a directory](https://www.ruby-forum.com/t/how-can-i-forward-an-ip-to-a-directory/233240)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 1\
**Last updated:** [November 26, 2014, 1:48pm UTC](https://www.ruby-forum.com/t/how-can-i-forward-an-ip-to-a-directory/233240 "2014-11-26T13:48:04Z")

</div>

Hello Folks. I installed Nginx and Elasticsearch and Kibana and my Linux box IP is 192.168.1.1 but when I enter this IP in browser it show me Nginx start page and I must enter “192.168.1.1/kibana” to show the Kibana …

---

## [Escape slashes in log output for JSON format](https://www.ruby-forum.com/t/escape-slashes-in-log-output-for-json-format/233209)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 1\
**Last updated:** [November 26, 2014, 11:51am UTC](https://www.ruby-forum.com/t/escape-slashes-in-log-output-for-json-format/233209 "2014-11-26T11:51:31Z")

</div>

I would like to add “json” option for additional escape for backslash character. So it will be: access\_log path format json; The initial patch for 1.6.2 looks like: — ./src/http/modules/ngx\_http\_log\_module.c.orig ++…

---

## [Serve content from a wget mirror](https://www.ruby-forum.com/t/serve-content-from-a-wget-mirror/233206)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 3\
**Last updated:** [November 25, 2014, 10:53pm UTC](https://www.ruby-forum.com/t/serve-content-from-a-wget-mirror/233206 "2014-11-25T22:53:25Z")

</div>

Hi, I’m trying to create an archive based on a current site which is due to be taken down, I’ve used “wget -m” to mirror the site and all seems well except I’m having trouble with what I think are arguments in the url…

---

## [Worker Connections not being released](https://www.ruby-forum.com/t/worker-connections-not-being-released/233227)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 0\
**Last updated:** [November 25, 2014, 9:46pm UTC](https://www.ruby-forum.com/t/worker-connections-not-being-released/233227 "2014-11-25T21:46:06Z")

</div>

Hello all, I have been developing an nginx module that allows the sending of zeromq messages through nginx (inspired by GitHub - FRiCKLE/ngx\_zeromq: ZeroMQ transport for nginx). The code base for this can be found he…

---

## [Proxy buffering](https://www.ruby-forum.com/t/proxy-buffering/237479)

<div class="topic-metadata">

**Author:** [@musicdenotation](https://www.ruby-forum.com/u/musicdenotation)\
**Replies:** 11\
**Last updated:** [November 25, 2014, 8:41pm UTC](https://www.ruby-forum.com/t/proxy-buffering/237479 "2014-11-25T20:41:47Z")

</div>

Hello all, I’ve configured nginx as a load balancing proxy for my backend servers. My backend is expecting multi-part uploads for large files in small chunks (5-15mb). The issue I’m encountering, is that I would like…

---

## [Vpn-ws a VPN over websockets (behind nginx)](https://www.ruby-forum.com/t/vpn-ws-a-vpn-over-websockets-behind-nginx/233224)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 0\
**Last updated:** [November 25, 2014, 4:26pm UTC](https://www.ruby-forum.com/t/vpn-ws-a-vpn-over-websockets-behind-nginx/233224 "2014-11-25T16:26:12Z")

</div>

Hi all, i have released a tool for building VPNs (with various operational modes) using only websockets as a transport. The server-side delegates all the authentication, authorization and proxy part to nginx: i ho…

---

## [Understanding nginx proxy magic](https://www.ruby-forum.com/t/understanding-nginx-proxy-magic/233214)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 2\
**Last updated:** [November 25, 2014, 2:21pm UTC](https://www.ruby-forum.com/t/understanding-nginx-proxy-magic/233214 "2014-11-25T14:21:13Z")

</div>

I installed nginx as a reverse proxy in front of apache server. No configuration change was made on apache and nginx is simply passing all requests to the backend apache. Now website is more responsive and it can han…

---

## [Nginx + php-fpm: permission denid](https://www.ruby-forum.com/t/nginx-php-fpm-permission-denid/233219)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 6\
**Last updated:** [November 25, 2014, 1:52pm UTC](https://www.ruby-forum.com/t/nginx-php-fpm-permission-denid/233219 "2014-11-25T13:52:41Z")

</div>

Hello, I have nginx 1.6.2 (compiled from source) and php-fpm 5.5.9 on Ubuntu server 14.04.1 LTS. I have problem with php-fpm, I receive error 502 Bad Gateway. In nginx error.log I found this: 2014/11/25 13:13:47 \[c…

---

## [Nginx reload, stop error](https://www.ruby-forum.com/t/nginx-reload-stop-error/231063)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 4\
**Last updated:** [November 25, 2014, 1:47pm UTC](https://www.ruby-forum.com/t/nginx-reload-stop-error/231063 "2014-11-25T13:47:13Z")

</div>

Hey, when I run ‘./nginx -s reload’ or ‘./nginx -s stop’ i get this: nginx: \[error\] open() “/usr/local/nginx-1.4.3/logs/nginx.pid” failed (2: No such file or directory) Any ideas why it’s trying to open this f…

---

## [Rewrite or return for simple redirection](https://www.ruby-forum.com/t/rewrite-or-return-for-simple-redirection/233178)

<div class="topic-metadata">

**Author:** [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Replies:** 6\
**Last updated:** [November 24, 2014, 3:40pm UTC](https://www.ruby-forum.com/t/rewrite-or-return-for-simple-redirection/233178 "2014-11-24T15:40:02Z")

</div>

I am trying to understand which option would result in more efficient HTTP redirection. I am trying to redirect ^/address page to ^/contact page. Option 1: rewrite ^/address /contact permanent; Option 2: location ~…

[Previous page](https://www.ruby-forum.com/c/server/nginx/21.md?page=43)

[Next page](https://www.ruby-forum.com/c/server/nginx/21.md?page=45)
