# Server

**URL:** https://www.ruby-forum.com/c/server/33.md?page=342

[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:** 343

---

## [Correct IP in access log](https://www.ruby-forum.com/t/correct-ip-in-access-log/149808)

<div class="topic-metadata">

**Author:** [@unclouded](https://www.ruby-forum.com/u/unclouded)\
**Replies:** 4\
**Last updated:** [September 30, 2008, 4:26am UTC](https://www.ruby-forum.com/t/correct-ip-in-access-log/149808 "2008-09-30T04:26:48Z")

</div>

Hello, I’m in the process of upgrading my setup. We’re installing nginx on a new server. While we transition (and dns propogates), I will keep the old nginx server running. I’m going to route requests that hit the …

---

## [File uploads](https://www.ruby-forum.com/t/file-uploads/149800)

<div class="topic-metadata">

**Author:** [@joviyach](https://www.ruby-forum.com/u/joviyach)\
**Replies:** 2\
**Last updated:** [September 30, 2008, 12:59am UTC](https://www.ruby-forum.com/t/file-uploads/149800 "2008-09-30T00:59:37Z")

</div>

Hi, I run a vBulletin site on a small VPS that I recently switched to Nginx from Apache. I recompiled php with fpm and have everything working fairly well but we’re experiencing one fairly major problem. It’s a Worl…

---

## [Reverse proxy performance woes](https://www.ruby-forum.com/t/reverse-proxy-performance-woes/147654)

<div class="topic-metadata">

**Author:** [@pachl](https://www.ruby-forum.com/u/pachl)\
**Replies:** 4\
**Last updated:** [September 29, 2008, 3:11pm UTC](https://www.ruby-forum.com/t/reverse-proxy-performance-woes/147654 "2008-09-29T15:11:23Z")

</div>

Hey all, I'm running into performance issues with nginx as a load balancer. I have three web servers and one load balancer server. All four of them have nginx installed and setup. Using a stress testing tool (jMeter…

---

## [(fast)cgi and nginx - there has to be a better way](https://www.ruby-forum.com/t/fast-cgi-and-nginx-there-has-to-be-a-better-way/149357)

<div class="topic-metadata">

**Author:** [@jonny](https://www.ruby-forum.com/u/jonny)\
**Replies:** 19\
**Last updated:** [September 29, 2008, 2:49pm UTC](https://www.ruby-forum.com/t/fast-cgi-and-nginx-there-has-to-be-a-better-way/149357 "2008-09-29T14:49:38Z")

</div>

I’ve spent the better part of the day combing through docs and the mailing list trying to get MovableType working with nginx it seems the best option is proxying to lighttpd - everything else seems to involve hacks an…

---

## [Terminating php fastcgi processes](https://www.ruby-forum.com/t/terminating-php-fastcgi-processes/148884)

<div class="topic-metadata">

**Author:** [@Sergio\_Devojno\_Brud](https://www.ruby-forum.com/u/Sergio_Devojno_Brud)\
**Replies:** 2\
**Last updated:** [September 29, 2008, 1:41pm UTC](https://www.ruby-forum.com/t/terminating-php-fastcgi-processes/148884 "2008-09-29T13:41:53Z")

</div>

offtopic: its more about php than nginx: there is any similar to apache\_child\_terminate for fastcgi php´s? My last resort of exec(’/usr/bin/kill '.getmypid()) plainly doesnt worked, the output is broken (nginx spit ou…

---

## [Mongrel hangs with 100% CPU / EBADF (Bad file descriptor)](https://www.ruby-forum.com/t/mongrel-hangs-with-100-cpu-ebadf-bad-file-descriptor/147005)

<div class="topic-metadata">

**Author:** [@frontline](https://www.ruby-forum.com/u/frontline)\
**Replies:** 1\
**Last updated:** [September 27, 2008, 5:20pm UTC](https://www.ruby-forum.com/t/mongrel-hangs-with-100-cpu-ebadf-bad-file-descriptor/147005 "2008-09-27T17:20:16Z")

</div>

We have a server with 10 running mongrel\_cluster instances with apache in front of them, and every now and then one or some of them hang. No activity is seen in the database (we’re using activerecord sessions). Mysql …

---

## ["Proxy proxy"!](https://www.ruby-forum.com/t/proxy-proxy/149573)

<div class="topic-metadata">

**Author:** [@igorclark](https://www.ruby-forum.com/u/igorclark)\
**Replies:** 4\
**Last updated:** [September 26, 2008, 3:49pm UTC](https://www.ruby-forum.com/t/proxy-proxy/149573 "2008-09-26T15:49:20Z")

</div>

Hi, We have a linux box hosted at an ISP which has been running various sites on Apache for some time. I’m in the process of porting the sites on it to nginx. At the moment I just have the default (’\_’) nginx server …

---

## [Problem about set variable according rewrite rule whithout if{}](https://www.ruby-forum.com/t/problem-about-set-variable-according-rewrite-rule-whithout-if/149572)

<div class="topic-metadata">

**Author:** [@yahwist](https://www.ruby-forum.com/u/yahwist)\
**Replies:** 0\
**Last updated:** [September 26, 2008, 12:21pm UTC](https://www.ruby-forum.com/t/problem-about-set-variable-according-rewrite-rule-whithout-if/149572 "2008-09-26T12:21:09Z")

</div>

I use apache2.2.8 as my web proxy server. I use the rewrite rule to implement according article id’s last number to assign user’s request to different domain. the apache rules is RewriteRule ^/(\[0-9\]+)(\[0-9\])/(.\*) h…

---

## [Static POST](https://www.ruby-forum.com/t/static-post/145844)

<div class="topic-metadata">

**Author:** [@imixaly4](https://www.ruby-forum.com/u/imixaly4)\
**Replies:** 14\
**Last updated:** [September 26, 2008, 12:08pm UTC](https://www.ruby-forum.com/t/static-post/145844 "2008-09-26T12:08:49Z")

</div>

The attached patch allows POSTs to non-existent files. This allows POSTs in following configuration: location / { error\_page 404 = @fallback; } location @fallback { ... } I intended to include it in the next…

---

## [Enhancement request for realip module](https://www.ruby-forum.com/t/enhancement-request-for-realip-module/149473)

<div class="topic-metadata">

**Author:** [@mike](https://www.ruby-forum.com/u/mike)\
**Replies:** 4\
**Last updated:** [September 25, 2008, 8:52pm UTC](https://www.ruby-forum.com/t/enhancement-request-for-realip-module/149473 "2008-09-25T20:52:00Z")

</div>

Is there any way to make the “real\_ip\_header” accept -any- header, instead of only X-Forwarded-For and X-Real-IP? I have a site on nginx behind Akamai, and they transmit a “True-Client\_IP” header with the actual clien…

---

## [Order of statements in server section](https://www.ruby-forum.com/t/order-of-statements-in-server-section/149488)

<div class="topic-metadata">

**Author:** [@david](https://www.ruby-forum.com/u/david)\
**Replies:** 0\
**Last updated:** [September 25, 2008, 11:07am UTC](https://www.ruby-forum.com/t/order-of-statements-in-server-section/149488 "2008-09-25T11:07:09Z")

</div>

Hello, Is there a specific order in which statements should be put in the server section of nginx.conf ? I ask because I’m nearing having to replace nginx and php-fpm with Apache and PHP as a module :-/ Nothing I d…

---

## [Persistence + Round robin](https://www.ruby-forum.com/t/persistence-round-robin/149428)

<div class="topic-metadata">

**Author:** [@Brian\_Moschel](https://www.ruby-forum.com/u/Brian_Moschel)\
**Replies:** 6\
**Last updated:** [September 25, 2008, 10:23am UTC](https://www.ruby-forum.com/t/persistence-round-robin/149428 "2008-09-25T10:23:43Z")

</div>

Hey guys, I’ve read through the docs and this doesn’t seem possible in the current setup, but I could be wrong. Here’s what I need: Load balancing using a uri param, but if its not found, fall back to round robin, …

---

## [Gzip+cache-dir: What's the easiest way to port this lighty config excerpt?](https://www.ruby-forum.com/t/gzip-cache-dir-whats-the-easiest-way-to-port-this-lighty-config-excerpt/149457)

<div class="topic-metadata">

**Author:** [@Sven\_CSKoehler](https://www.ruby-forum.com/u/Sven_CSKoehler)\
**Replies:** 3\
**Last updated:** [September 25, 2008, 12:58am UTC](https://www.ruby-forum.com/t/gzip-cache-dir-whats-the-easiest-way-to-port-this-lighty-config-excerpt/149457 "2008-09-25T00:58:44Z")

</div>

Hi, I am wondering what might be the easiest way to resemble the semantics of lighttpd’s compress.cache-dir: | server.modules = ( “mod\_compress” ) | compress.filetype = (“text/javascript”, “text/css”) | server.docu…

---

## [Nginx fails to build on sparc (Architecture mismatch on "casa")](https://www.ruby-forum.com/t/nginx-fails-to-build-on-sparc-architecture-mismatch-on-casa/149413)

<div class="topic-metadata">

**Author:** [@JosSSSS\_Miguel\_Parr](https://www.ruby-forum.com/u/JosSSSS_Miguel_Parr)\
**Replies:** 0\
**Last updated:** [September 24, 2008, 4:11pm UTC](https://www.ruby-forum.com/t/nginx-fails-to-build-on-sparc-architecture-mismatch-on-casa/149413 "2008-09-24T16:11:12Z")

</div>

Greetings, It seems that somewhere around 0.5.35 a change in nginx’s build system make it fail while building on sparc machines with this error message: —8\<— gcc -c -Wall -g -O2 -I src/core -I src/event -I src/event…

---

## [Ajax](https://www.ruby-forum.com/t/ajax/149353)

<div class="topic-metadata">

**Author:** [@david](https://www.ruby-forum.com/u/david)\
**Replies:** 7\
**Last updated:** [September 24, 2008, 2:41am UTC](https://www.ruby-forum.com/t/ajax/149353 "2008-09-24T02:41:52Z")

</div>

Hello, Has anyone had any issues using Ajax, PHP-fpm and ajax ? I’m finding ajax requests to be very very slow and sometimes timing out. What sort of things in the nginx log should I be looking for to try and debug …

---

## [Proxy passing and the URI](https://www.ruby-forum.com/t/proxy-passing-and-the-uri/149273)

<div class="topic-metadata">

**Author:** [@mike](https://www.ruby-forum.com/u/mike)\
**Replies:** 7\
**Last updated:** [September 24, 2008, 1:14am UTC](https://www.ruby-forum.com/t/proxy-passing-and-the-uri/149273 "2008-09-24T01:14:40Z")

</div>

I have a request for http://foo.com/sites/something I have this location block inside of server{} with root /home/foo/web/foo.com location ^~ /sites { proxy\_pass http://10.122.47.82; proxy\_set\_header Host foo.com; …

---

## [Nginx slowing down](https://www.ruby-forum.com/t/nginx-slowing-down/149347)

<div class="topic-metadata">

**Author:** [@gennix](https://www.ruby-forum.com/u/gennix)\
**Replies:** 6\
**Last updated:** [September 23, 2008, 11:48pm UTC](https://www.ruby-forum.com/t/nginx-slowing-down/149347 "2008-09-23T23:48:52Z")

</div>

Hi everybody, I have a problem… When Nginx is reaching more than 120 requests/seconds, http connections start to slow down (from 2 secondes to get all the home page to 20 secondes), and I don’t understand why. I tho…

---

## [Upstream closed connection](https://www.ruby-forum.com/t/upstream-closed-connection/148846)

<div class="topic-metadata">

**Author:** [@gennix](https://www.ruby-forum.com/u/gennix)\
**Replies:** 5\
**Last updated:** [September 23, 2008, 10:10pm UTC](https://www.ruby-forum.com/t/upstream-closed-connection/148846 "2008-09-23T22:10:00Z")

</div>

Hi, I’m using Nginx+PHP+MySQL on CentOS since two weeks and it works great (with 20 000 visitors/day). But every minutes, I received several errors like this one : 2008/09/16 12:39:30 \[error\] 25031#0: 5786740 upstrea…

---

## [Re: nginx not responding to requests](https://www.ruby-forum.com/t/re-nginx-not-responding-to-requests/149334)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 0\
**Last updated:** [September 23, 2008, 7:54pm UTC](https://www.ruby-forum.com/t/re-nginx-not-responding-to-requests/149334 "2008-09-23T19:54:42Z")

</div>

How have you configured and built nginx ? It seems that you use --test-build-rtsig option which I use to test rtsig module building on FreeBSD that has no rtsig support. I built it with the following: ./configure -…

---

## [Can X-Accel-Redirect set limit\_conn](https://www.ruby-forum.com/t/can-x-accel-redirect-set-limit-conn/149169)

<div class="topic-metadata">

**Author:** [@henry](https://www.ruby-forum.com/u/henry)\
**Replies:** 4\
**Last updated:** [September 23, 2008, 1:49pm UTC](https://www.ruby-forum.com/t/can-x-accel-redirect-set-limit-conn/149169 "2008-09-23T13:49:52Z")

</div>

Is the settings of number of simultaneous connections only in location? etc. location /download/ { limit\_conn one 1; } Can add some header of X-Accel-Redirect? it will be more flexible.

---

## [Blocking request using client hostname](https://www.ruby-forum.com/t/blocking-request-using-client-hostname/149279)

<div class="topic-metadata">

**Author:** [@Rakesh\_Rajan](https://www.ruby-forum.com/u/Rakesh_Rajan)\
**Replies:** 0\
**Last updated:** [September 23, 2008, 9:16am UTC](https://www.ruby-forum.com/t/blocking-request-using-client-hostname/149279 "2008-09-23T09:16:38Z")

</div>

Hi All, I have a particular server block, whose access I want to restrict to a particular client host name ( i.e client should have an IP which is pointed by www.example.com to get access to that server block ). Is th…

---

## [Rewrites vs. location, etc](https://www.ruby-forum.com/t/rewrites-vs-location-etc/149240)

<div class="topic-metadata">

**Author:** [@mike](https://www.ruby-forum.com/u/mike)\
**Replies:** 0\
**Last updated:** [September 22, 2008, 8:16pm UTC](https://www.ruby-forum.com/t/rewrites-vs-location-etc/149240 "2008-09-22T20:16:51Z")

</div>

From what it appears, rewrite foo bar last; Gets processed before any location blocks. i.e. a request for /foo/bar with a rewrite of rewrite ^/foo/(.\*) /$1 last; will wind up making it /bar, so the location needs t…

---

## [Loadable modules in nginx?](https://www.ruby-forum.com/t/loadable-modules-in-nginx/149236)

<div class="topic-metadata">

**Author:** [@Arvind\_Jayaprakash](https://www.ruby-forum.com/u/Arvind_Jayaprakash)\
**Replies:** 0\
**Last updated:** [September 22, 2008, 7:25pm UTC](https://www.ruby-forum.com/t/loadable-modules-in-nginx/149236 "2008-09-22T19:25:41Z")

</div>

I am newbie to nginx and I read that in order to write custom modules, they need to be recompiled with nginx. I expect this to be a bit of a maintanence issue and wonder why we don’t have loadable modules. It should n…

---

## [Named location explicit config](https://www.ruby-forum.com/t/named-location-explicit-config/149196)

<div class="topic-metadata">

**Author:** [@igorclark](https://www.ruby-forum.com/u/igorclark)\
**Replies:** 5\
**Last updated:** [September 22, 2008, 4:53pm UTC](https://www.ruby-forum.com/t/named-location-explicit-config/149196 "2008-09-22T16:53:30Z")

</div>

Hi, Is it possible to route specific types directly to a named location without using error\_page? e.g. location .php$ { @phpapp; } That doesn’t work, but is there any way to do this? Thanks very much, Igor

---

## [Mongrel + Apache occasional Proxy Error](https://www.ruby-forum.com/t/mongrel-apache-occasional-proxy-error/149182)

<div class="topic-metadata">

**Author:** [@cpher](https://www.ruby-forum.com/u/cpher)\
**Replies:** 0\
**Last updated:** [September 22, 2008, 10:52am UTC](https://www.ruby-forum.com/t/mongrel-apache-occasional-proxy-error/149182 "2008-09-22T10:52:38Z")

</div>

Hi There - long time reader first time poster :stuck\_out\_tongue: I appreciate this is a problem with quite a few threads out there, but I have read many of the threads and tried many of the fixes / hacks suggested to …

---

## [Conditional error\_log capability?](https://www.ruby-forum.com/t/conditional-error-log-capability/149082)

<div class="topic-metadata">

**Author:** [@mike](https://www.ruby-forum.com/u/mike)\
**Replies:** 3\
**Last updated:** [September 21, 2008, 10:11am UTC](https://www.ruby-forum.com/t/conditional-error-log-capability/149082 "2008-09-21T10:11:41Z")

</div>

Our new ISP’s load balancer is going crazy, and is apparently issuing partial HTTP requests constantly or something. This is flooding the error log, and I’m wondering if there is a way to disable the error\_log conditi…

---

## [Out of Office AutoReply: Conditional error\_log capability?](https://www.ruby-forum.com/t/out-of-office-autoreply-conditional-error-log-capability/149081)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 0\
**Last updated:** [September 20, 2008, 2:19am UTC](https://www.ruby-forum.com/t/out-of-office-autoreply-conditional-error-log-capability/149081 "2008-09-20T02:19:02Z")

</div>

Hello - I am on vacation until September 30th. I look forward to responding to your email when I return. Thanks, Jeff

---

## [Redirecting from mysite.com to www.mysite.com](https://www.ruby-forum.com/t/redirecting-from-mysite-com-to-www-mysite-com/148975)

<div class="topic-metadata">

**Author:** [@thomas](https://www.ruby-forum.com/u/thomas)\
**Replies:** 4\
**Last updated:** [September 18, 2008, 10:59pm UTC](https://www.ruby-forum.com/t/redirecting-from-mysite-com-to-www-mysite-com/148975 "2008-09-18T22:59:39Z")

</div>

On my local dev machine, here is my /etc/hosts file: 127.0.0.1 localhost mysite.com www.mysite.com And in my Nginx config file I have: server { server\_name mysite.com; rewrite ^/(.\*) http://www.mysite.com/$1 per…

---

## [Tweaking $host value](https://www.ruby-forum.com/t/tweaking-host-value/148969)

<div class="topic-metadata">

**Author:** [@thomas](https://www.ruby-forum.com/u/thomas)\
**Replies:** 1\
**Last updated:** [September 18, 2008, 9:42pm UTC](https://www.ruby-forum.com/t/tweaking-host-value/148969 "2008-09-18T21:42:10Z")

</div>

Hi, When a user enters www.mysite.com, the value returned by nginx in $host is “www.mysite.com”, If I use this in my root declaration such as: root /var/www/$host; This means that I must rename my folder on disk as w…

---

## [Worker process exits w/addition of rewrite rule](https://www.ruby-forum.com/t/worker-process-exits-w-addition-of-rewrite-rule/148973)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 0\
**Last updated:** [September 18, 2008, 8:59pm UTC](https://www.ruby-forum.com/t/worker-process-exits-w-addition-of-rewrite-rule/148973 "2008-09-18T20:59:06Z")

</div>

Running 0.6.29 on Gentoo for sparc64. When I add a rewrite rule to my server config, nginx worker exits (nothing returned to browser). Works: server { listen 80; server\_name foo.example.com; acces…

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

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