NginX is a web server and mail proxy known for its high performance and small resource footprint. It is used in many places as a replacement to apache and also as a front end server to static content or reverse proxying. NginX is developed under a BSD-like license by kazakhstani developer Igor ...
0
votes
1answer
10 views
Nginx, PHP-FPM and Memcached
I have Wordpress installation running on two web servers powered by Nginx. I configured Memcached on both servers and I'm using W3 total cache plugin for Memcached:
What's the recommended solution ...
1
vote
1answer
35 views
Serve up s3 file with nginx
I have some static files sitting in an s3 bucket that I want to serve up from my nginx server. Basically, if a user goes to www.mywebsite.com/this/url I want to server them up a file from the S3 ...
0
votes
1answer
24 views
NGINX on OSX Snow Leopard Server - extremely slow over network
I set up nginx to serve a rails application for our intranet. It runs on a osx server blade with snow leopard.
When I work on the server and go to localhost:8444 it runs very smooth and fast, but when ...
0
votes
1answer
8 views
Allowing cross origin requests (CORS) on Nginx for 404 responses
I'm using Nginx to serve static files in response to CORS requests using the technique outlined in this question. However, when the file doesn't exist the 404 response does not contain the ...
0
votes
1answer
25 views
Nginx config file only working for ''/"
I am setting up nginx as a sort of static file server. For some reason it is only working when I go to 123.123.123.123/ or 123.123.123.123. However, when I go to 123.123.123.123/static/content/ or ...
1
vote
1answer
28 views
Node port forwarding or proxy via Nginx?
Which is the best method (in terms of speed / best practices) for hosting a Node/Express app on an EC2 server instance running Ubuntu?
Use Nginx as a proxy as outlined in this question.
Add a port ...
-2
votes
0answers
29 views
two applications (ruby and php) on same url [closed]
I have two applications. One is PHP and the other is Ruby.
I have only one domain (www.example.com) and I want both these apps accessible on same domain but with different URLs.
For example suppose ...
4
votes
1answer
22 views
mod_rpaf problems with Nginx front, Apache back-end after Ubuntu upgrade
I'm running an Nginx front-end for static files, and proxying to an Apache backend for PHP and Passenger, using Apache's mod_rpaf to set the correct remote IP address on the backend. Everything worked ...
0
votes
1answer
35 views
convert apache rewrite to nginx
I am confused to convert this rules to nginx.
RewriteEngine On
RewriteCond %{REQUEST_URI} ^(.+)\~s$
RewriteRule ^(.*) stats.php?u=$1 [L]
RewriteCond %{REQUEST_URI} ^(.+)\~d$
RewriteRule ^(.*) ...
1
vote
2answers
45 views
nginx - is using $http_host dangerous?
From my own answer, I had to replace $host with $http_host to get my problem resolved...
But is this safe?
It seems like all $http_host is doing is to exposed the whole HOST from header.
The ...
0
votes
1answer
69 views
MySQL, php-fpm, APC, Varnish and Nginx optimization for WordPress/W3 Total Cache?
I'm setting up my first VPS and it seems to be working well. Installed Nginx, php-fpm (as a unix socket), APC, Varnish and MySQL on Ubuntu 12.04 server with OnApp, and everything works and is damm ...
0
votes
0answers
22 views
Nginx as non-caching reverse-proxy overwrites Cache-control
We run our web application using Nginx as load-balancer in front of Apache driven backend servers. The cache in Nginx configuration is not enabled (is this different from disabled?); relevant ...
0
votes
2answers
45 views
Nginx - when tunnel the url redirects without port number
My problem is very similar to this: nginx proxy pass redirects ignore port
I am using nginx 1.0.14.
I want to be able to ssh-tunnel into my Django website, so I can work remotely. I've tested a ...
0
votes
4answers
37 views
Nginx deferred bind
I am using nginx on debian, and have a server configured with
server {
listen 172.30.0.172 deferred;
}
When I test the nginx config I still get
[emerg] bind() to 172.30.0.172:443 failed (99: ...
1
vote
1answer
25 views
Programatically blocking a url to rate limit, unblocking or expiring the block
My requirements are to be able to rate limit or temporarily hard block any requests to our server for a particular URL if the client sends more than x requests per hour.
There are about 250K urls ...
0
votes
2answers
38 views
Set nginx to answer for all domains
I have this setup with apache but want to move over to nginx. I'm not sure how I can accomplish this.
In apache I had it as ServerAlias *
What would be the nginx equivalent?
I've tried server_name ...
3
votes
1answer
28 views
Disable SSL for certain paths in Nginx
I have a Web site where I want all requests to be done with HTTPS except for requests to urls with paths that start with /foo/. How do I configure this in Nginx?
Right now I run all requests with ...
2
votes
1answer
40 views
Varnish client.ip says 127.0.0.1
So I have a setup like Nginx -> varnish -> apache2
If I get a request with a static file it is sent through nginx to varnish and back to nginx again since its a lot faster than letting apache2 server ...
0
votes
1answer
55 views
Proxy http nginx for multiple websites
I have to configure a Nginx server wich will be used as http(s) proxy and caching like a Apache server with proxy_pass and proxy_pass_reverse directives.
The system will be like this :
The nginx ...
0
votes
0answers
18 views
301 Redirect via Nginx from /foder to / without touching /folders
With this rewrite everything works fine:
map $uri $new_uri {
default '';
~^/mysite(?<real_uri>.*)$ $real_uri;
}
and
if ($new_uri) {
return 301 $scheme://myserver$new_uri;
}
But ...
0
votes
1answer
15 views
Easy way to launch several rails apps on the server
I have several rails applications on my server. Each application uses its own rvm gemset. I'm using Thin as web server for each application, this servers installs as a gem separately for each ...
0
votes
1answer
44 views
Web server caching
Could you please help me to better understand how the web server caching mechanism works.
I have a Wordpress website with opcode caching (APC). Pages are cached in memory via W3 total cache plugin.
...
0
votes
1answer
32 views
PUT and DELETE methods in nginx
is there anyway how to enable such http methods like PUT and DELETE for specific veirtual host in nginx ?
I need it for my RESTfull server application.
1
vote
0answers
23 views
Nginx HttpSecureLinkModule and IP restricted hashes not working sometimes
Im using the nginx module HttpSecureLinkModule to protect resources from being hotlinked with expiring hashes which use user's IP address to make a hash that will only work for them, on top of ...
0
votes
2answers
44 views
Forward Custom Header from Nginx Reverse Proxy
I have an nginx web server acting as a reverse proxy to forward requests on to Apache for additional handling (I'm begging you not to ask why). I have a request to which I'm trying to attach a custom ...
1
vote
1answer
32 views
Server crashing after Wordpress upgrade to latest version (nginx+php-fpm)
I upgraded Wordpress on my huge blog (around 300 000 visitors per day) from 2.8.4 to latest 3.3.2. Everything went well but my server started returning lot of Errors 502 although it worked perfectly ...
0
votes
1answer
34 views
nginx request blocking based on server_name
I am still newbie to nginx.
I am trying to block every request that came from somewhere but not server_name.
According to documentation it should work but I didn't succede.
I assume there are ...
0
votes
1answer
34 views
High server load with ngix+php5-fpm
I successfully installed nging+php5-fpm. Everything works fine but on the same machine server load is higher than with Apache2+php.
With Apache2+php I was running 2 websites and average server load ...
-1
votes
0answers
38 views
django-gunicorn-nginx: 502 bad gateway
I'm trying to ship my web application to the server and this is my first time configuring the server. I'm using django-gunicorn-nginx setup by following this tutorial ...
0
votes
1answer
40 views
Nginx monitor current connections
I am just starting learning Nginx webserver. I have question regarding few parameters which I know apache has, but I cannot find something similar in Nginx.
I used to monitor idle workers in apache ...
0
votes
1answer
33 views
Nginx + fastcgi to run PHP script , but it kept telling me “File not found”
Here's part of config in the server block:
I was unable to execute any php script , I placed a file named test.php under /var/html , but when I point to http://localhost/test.php , I got a result:
...
2
votes
2answers
83 views
Linux web servers that support websockets?
I'm currently having a lots of difficulties trying to play with socket.io which needs websockets support from the server (reverse-proxying).
I was wondering, is there any other web servers out there ...
1
vote
1answer
35 views
How to inspect load balancer L7 Injected Headers
There is a hardware LB redirecting http to an Nginx SSL Offloader listening only at 443. I have no access to the LB, but I need to verify if it is injecting the X-Forwarded-For header.
Why? I'm ...
0
votes
1answer
36 views
php 5.4 nginx ubuntu 10.04 LTS
How can I get Nginx to work with php 5.4 on Ubuntu 10.04 LTS
So far I installed php 5.4 on the server:
sudo apt-get install python-software-properties
sudo add-apt-repository ppa:ondrej/php5
sudo ...
0
votes
1answer
26 views
NGINX + GZIP - Altering Vary header to include User-Agent
Currently, when nginx is set to gzip outbound content as requested by the client, the "gzip_vary on" setting will set the following header:
Vary: Accept-Encoding
We would like to modify this to ...
1
vote
1answer
45 views
Configuring Nginx, Thin and Rails. Can access static pages but not dynamic
I have set up nginx (nginx.conf below) and thin. Both nginx and thin (2 servers) are running (I have checked they are running). I can access a static page in the rails public directory such as ...
2
votes
2answers
41 views
HAProxy + nginx reaching max numtcpsock in about 24 hours
I'm running a relatively simple VPS (a Media Temple (ve)) with a few PHP-based websites and (eventually) a few Node servers. In order to enable WebSockets support, I'm using HAProxy on port 80, which ...
0
votes
1answer
49 views
Nginx,Uwsgi and Django App Not Found
I have configured Nginx with uWSGI and Django on CentOS.
Django Directory(contains all my django app): /home
Django Project Directory: /home/hdblog
/home/hdapp.py contains below:
import os, sys
...
0
votes
0answers
14 views
Is it secure to use apache mod_mono with more virtualhosts?
I am using apache2 with mod_php and mpm_itk_module to run every virtualhost under its user. Now I am looking at mono (mod_mono) and I am not sure, if it is secure to run mono as only one process, whom ...
1
vote
2answers
34 views
Nginx - Does doing a nginx -s reload when upgrading nginx cause the binary to reload?
We were wondering the following:
Imaging upgrading nginx by compiling the new version, and doing a make install.
The targets are all the same, essentially the old version is overwritten (we usually ...
1
vote
2answers
48 views
Structuring an nginx config for static content and php
I'm trying to write an Nginx config with the following semantics, expressed in hopefully-readable psuedo-config:
location /dir1/ /dir2/ {
if (matches a .php file) {
serve with php
} else if ...
0
votes
1answer
31 views
Blank wordpress page for default server on nginx
I recently upgraded to php 5.3 tor the purpose of using php-fpm.
All my sites are working except for the default one which is showimg a blank page. Defined in nginx.conf as follows. What is te ...
1
vote
1answer
31 views
nginx - request getting handled by multiple location blocks
I'm testing a setup where I'd like to have nginx serve up static media and proxy all other requests to another backend. My configuration looks like this:
location /media {alias /var/httpd/media;}
...
1
vote
1answer
48 views
Nginx HTTP/SPDY over SCTP
I've ready a thread in russian Nginx maillist about implementing HTTP/SPDY over SCTP in future.
I realize that SCTP is completely unusable for public service at the moment, but what changes should ...
1
vote
1answer
37 views
Setting upi a proxy using nginx
I'm trying to setup of proxy using nginx, but it redirects rather than proxy it (at least that's what it looks like). My virtual host config:
server {
listen 80;
server_name ...
1
vote
3answers
51 views
NginX Subdomains
Working on migrating servers and having zero luck setting up my subdomains. The behavior I'm looking for is fairly straightforward:
www.domain.com & domain.com --> /var/www/live/
*.domain.com ...
1
vote
1answer
41 views
Tomcat and nginx sizing
I manage an application that is deployed on Tomcat servers, with nginx in front, as a reverse proxy. I need some help for the sizing of thread pools / connection pools / ... I find quite a lot of ...
1
vote
1answer
55 views
403 Forbidden when trying to reach my simple test page
I've just installed nginx and I'm trying to setup my first site. I'm trying to use nginx with php-fpm. nginx is installed (when I go to my ip I get the default welcome to nginx page).
Now I am trying ...
1
vote
0answers
22 views
Nginx as a proxy doesn't allow to access backend (Apache) content which is password protected
I have apache as a backend and nginx as a frontend. Some content is password-protected by Apache (HTTP Auth).
When I access it directly - everything works fine, bur when I try it through nginx - ...
0
votes
0answers
40 views
cx_Oracle - InterfaceError: Unable to acquire Oracle environment handle
I have installed Django on Ubuntu 12.04 behind NGINX with uWSGI.
I use Postgresql as the main database for the application however I need to retrieve some data from an Oracle database.
I have ...