Questions tagged [nginx]

Nginx ("eNgine x") is a lightweight, high-performance HTTP server, reverse proxy, TCP stream proxy and mail proxy, released under a BSD-like license.

5,933 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
1 vote
1 answer
835 views

Redirect to HTTPS from my Amazon Elastic Load Balancer

I have a rails app on 2 EC2 Instances running nginx behind an Amazon Elastic Load Balancer. I'd like to force HTTPS, which was working fine before I added in the Load Balancer. Now I can't quite ...
Adam's user avatar
  • 113
1 vote
1 answer
93 views

Owner/Group issue on Mirror server

I am running Gluster-FS with a High-Availability Storage setup. Both client and server nodes have NginX running to serve same files. main.mysite.com mirror1.mysite.com ..etc.. The problem is that ...
Hassan's user avatar
  • 467
1 vote
0 answers
731 views

nginx does not respect "root" directive

I'm running an EC2 instance with Ubuntu and trying to setup virtual servers for two domains without luck and cannot figure out why. My web documents are located in /var/www/<domain> and ...
kiri__'s user avatar
  • 111
1 vote
1 answer
1k views

nginx add trailing slash

I'm having troubles figuring out the following problem. Basically, we have a jekyll blog which we decided to separate physically on the server from our main website ie. it is not served from the main ...
milosgajdos's user avatar
  • 1,878
1 vote
0 answers
870 views

Nginx reverse proxy apache2 High CPU load

my server: 2x Intel Xeon 5506 2.13GHz 24 GB DDR3 RAM Debian 5.0.8 64-bit My server CPU is aroung 90% at 600 users and around 6 page views per second. There are 2 Sites on the server. One Forum with ...
chillah's user avatar
  • 101
1 vote
0 answers
649 views

NGinx - PHP / CGI - No input file specified

I know this is a common problem. I googled and tried a lot but still doesn't work. "No input file specified" while calling PHP files from browser. I Installed nginx php/cgi on a fresh debian machine. ...
Aditya Singh's user avatar
1 vote
2 answers
1k views

Sync the cache of multiple nginx servers

I have a master caching server with nginx. Its setup with proxy_pass and proxy_cache. But I want to add more nginx caching servers in other locations that will all contain the same contents with ...
Jim's user avatar
  • 410
1 vote
2 answers
1k views

Caching without file extensions

I'm trying to use Varnish to show the non-logged in users a cached version of my website. I'm able to perfectly detect if the user is logged in or out, but I can't cache pages without extensions. ...
Sigurs's user avatar
  • 11
1 vote
1 answer
361 views

2 sited hosted in NGINX with separate SSL certs. IE8 posting invalid when starting at one site going to the other

If users with IE8 go directly to www.xyz.com, SSL cert is fine. Users going directly to www.zyx.com have no issues with cert. If users start at one site and go to the other, they get invalid cert ...
Dave Johnsen's user avatar
1 vote
2 answers
982 views

nginx won't execute PHP page that returns JavaScript

Here is my nginx (1.1.19) conf for the Silverstripe site. I am using PHP-FPM as well. nginx and PHP-FPM for the most part are vanilla setups at the moment. I am using a separate FPM pool with its own ...
Brandon's user avatar
  • 11
1 vote
0 answers
697 views

Nginx config rewrite or internal redirection cycle

I'm using Nginx with ISPConfig 3 to make the configuration and I'm getting rewrite or internal redirection cycle that I can't figure out with my limited knowledge of nginx. [error] 13741#0: *64 ...
Scott's user avatar
  • 11
1 vote
0 answers
1k views

Nginx, wordpress: Unable to proper reverse proxy caching due to Set-Cookie. Recommendation for a good strategy

I am trying to do reverse proxy caching for a wordpress blog and I am hit with snags. The initial configuration was a simple reverse caching like this location / { proxy_cache_key "$scheme:/...
Quintin Par's user avatar
  • 4,443
1 vote
2 answers
510 views

Nginx rewrite rule for subdomain

I have a sub-domain, something.site.com. In my main-site, site.com/something, I would like to rewrite to something.site.com, but keep the url site.com/something intact. Is that something I can do ...
Silfverstrom's user avatar
1 vote
0 answers
3k views

Nginx Active/Active Cluster Setup

I am currently attempting to configure a pair of load balancing servers in an Active/Active configuration using the following: Nginx Corosync Pacemaker Applicable instructions were followed ...
mazatsushi's user avatar
1 vote
1 answer
2k views

Node.js apps and wordpress on the same vps

So currently my linode (ubuntu 11.10) serves up three node.js apps for me using connect's vhost middleware listening on port 80. Here is an example of how vhost sets up a domain: var portfolio = ...
Msencenb's user avatar
  • 113
1 vote
2 answers
547 views

nginx location rewrite but proxy_rewrite off

I'm trying to use nginx for proxying requests to my internal backend. My configuration reads as follows: location /Shibboleth.sso { proxy_pass internal-backend; # ip proxy_redirect off; } ...
Jan's user avatar
  • 11
1 vote
1 answer
333 views

converting apache rewrite rules to nginx

Hello everyone, I am trying to create a UDID protected Cydia Repo but I cannot use it on nginx because of nginx does not use the .htaccess file. The file certain rewrite rules to make ...
Muktadir Miah's user avatar
1 vote
0 answers
210 views

Domain root on nginx not working

mydomain.com is running with nginx1.2, php-fpm, apc on an ubuntu server (medium - amazon ec2). I have been tweaking my server for past 6 months, however a problem started occurring since day before ...
Apurva Sukant's user avatar
1 vote
0 answers
190 views

nginx HttpAuthDigestModule

I have to problem to login in secure folder nginx conf auth_digest_user_file /var/www/*******/htpasswd/passwd.digest; location /private { auth_digest 'this is not for you'; } ...
nemanja's user avatar
  • 19
1 vote
1 answer
81 views

How can I globally set Cache-Control: no-expire on POST in an nginx config?

I'd like to set Cache-Control: no-expire but only on POSTs, what would be the correct way of doing that?
Kit Sunde's user avatar
  • 946
1 vote
0 answers
211 views

root folder php scripts not running in nginx

nginx with php-fpm on ubuntu 12.04 server. attempting to access /var/www/test.php (via https://example.net/test.php) downloads the script instead of executing it. if I place the test.php in a ...
Thermionix's user avatar
1 vote
1 answer
896 views

Performance: Nginx SSL slowness or just SSL slowness in general?

I have an Amazon Web Services setup with an Apache instance behind Nginx with Nginx handling SSL and serving everything but the .php pages. In my ApacheBench tests I'm seeing this for my most ...
Mauvis Ledford's user avatar
1 vote
1 answer
482 views

Static file or memory based web server cache for Coldfusion and IIS

We are looking for a cache layer between IIS/ISAPI and Coldfusion, so that if an entire page is cached on the server, then additional requests to that resource do not require allocating a Coldfusion ...
Owen Allen's user avatar
1 vote
0 answers
3k views

Nginx condition proxy based on the $request_body

I want my server proxy Google if my $request_body of a POSTed request contains the string google, e.g. echo "google" | lwp-request -m POST "http://127.0.0.1" So I have the config like, e.g. server {...
Ryan's user avatar
  • 6,041
1 vote
1 answer
634 views

nginx clean url router/rewrites

im having difficulties with a relativity simple rewrite rules / router in nginx config. All I want to do is, if requested dir or file 'host/my/request/path[/[index.php]]' does not exist, rewrite to '...
Janko's user avatar
  • 11
1 vote
0 answers
525 views

Need help optimizing a LEMP stack on a 4GB dedicated server

Recently i got a project i'm working in financed by a friend. So he gave me access to a 60mbps dedicated connection link and a HP Compaq 8200 Elite. The HP is just a desktop, but i'm using it as a ...
Julian Fernandes's user avatar
1 vote
0 answers
146 views

Nginx for a site allowing downloads

My friend have a site that allows users to download files.However the moment one guy start downloading server load change from 0.00 to 3.50 in a matter of minutes.Nginx and php-fpm reach D state and ...
Werulz's user avatar
  • 315
1 vote
1 answer
1k views

404 with serving static files in a custom nginx configuration

In my nginx configuration, I have the following: location /admin/ { alias /usr/share/php/wtlib_4/apps/admin/; location ~* .*\.php$ { try_files $uri $uri/ @php_admin; } location ~* \.(js|...
code90's user avatar
  • 173
1 vote
0 answers
2k views

only removing index.php rule works on my NginX and CodeIgniter as rewrite. Why?

Although I've spent 2 days reading on forums, I still can't get some Codeigniter rewrites working in Nginx. Here is the server configuration: server { listen *:80; server_name artademy.com ...
Atomei Cosmin's user avatar
1 vote
0 answers
246 views

Proxy to either Rails app or Node.js app depending on HTTP path w/ Nginx

On Ubuntu 11, I have Nginx correctly serving either CouchDB or Node.js depending on the path, but am unable to get Nginx to access a Rails app via it's port. server { rewrite ^/api(.*)$ $1 last; ...
james_womack's user avatar
1 vote
0 answers
843 views

Mumble Django via Nginx - config file infinitely loops in rewrite

I am having a bit of problem of configuring Nginx in place of Apache, so that it served Mumble Django to clients. I have vhosts configs for both Apache and Lighttpd - let me put them here side by side,...
Gelmir's user avatar
  • 111
1 vote
1 answer
2k views

Convert a RewriteRule from nginx to apache

i want to convert a nginx rewriterule to a htaccess rewrite rule. The nginx one is the following: rewrite ^/(.*)$ /index.php?$1 last; I tried it with: RewriteEngine On RewriteRule ^/(.*)$ /index....
carrot's user avatar
  • 97
1 vote
1 answer
986 views

Nginx: Do not redirect without trailing /

I have a problem where Nginx redirects me to the wrong url if there is no trailing / provided. I have haproxy setup to delegate the requests between multiple servers. curl output: ➜ ~ curl -i www....
Hendrik's user avatar
  • 251
1 vote
1 answer
2k views

Nginx dynamic PHP 404 (with URL rewriting)

I'm trying to set-up dynamic 404 pages so that I can keep the URL of the missing content, show it on the 404 page and keep my site's template consistent. Here is my site conf: server { listen ...
grandcameo's user avatar
1 vote
0 answers
253 views

Why this vhosts configuration keeps redirect other domains to one

I'm trying to add a second domain to nginx. It's ok to access static files like css in domain2.com but visits to php scripts (e.g domain2.com/index.php) will be 302 redirect to domain1.com (e.g ...
dotslashlu's user avatar
1 vote
0 answers
2k views

Jmeter Nginx Stress Test Error Rate Higher

I have a JSF web application runs on Glassfish Application Server. I'm using Nginx with reverse proxing to Glassfish. I wanna see performance gains with Nginx, i'm testing application with JMeter. ...
Rahman Usta's user avatar
1 vote
0 answers
645 views

request a image but nginx return 200 and a blank response header

When browser(Windows IE8,9 and Windows Chrome(20) and Mac Chrome(20)) request a set of images, some image requests return 304 and display correctly, but others return 200OK and a blank response header,...
VvDPzZ's user avatar
  • 135
1 vote
0 answers
375 views

Why does nginx 1.0.0 appear to not use the kernels open file cache on Gentoo? (high iowait)

free -m total used free shared buffers cached Mem: 7996 2043 5952 0 73 140 -/+ buffers/cache: 1830 6165 ...
Daniel's user avatar
  • 119
1 vote
0 answers
1k views

I get a 502 bad gateway ONLY with a specific combination of domain/root folders - NGINX

I have a VPS running NGINX and virtual hosts, with a configuration such as this: Domains directing to it: lolpics.no smscloud.no idmag.no Root folders: /home/vds/www/lolpics /home/vds/www/smscloud ...
Patrick De Amorim's user avatar
1 vote
0 answers
256 views

email handling with inbox.py and nginx

I have a Flask web application running behind gunicorn and Nginx. Nginx proxies any traffic to ivrhub.org to the correct flask app. I would very much like to use inbox.py to process some incoming ...
Matt's user avatar
  • 111
1 vote
1 answer
773 views

Why does SERVER_PORT not always get passed to my appserver?

I have an nginx set up in a very boring fashion as a reverse proxy to an appserver. But sometimes my upstream gets the environment variable SERVER_PORT, sometimes it does not. Anyone suggest why it's ...
dotplus's user avatar
  • 1,230
1 vote
1 answer
1k views

nginx doesn't find the directory but apache does

I use apache as the backend server and nginx on the frontend. Apache listens to port 8080 and nginx to port 80. What I do is have the root point to the public folder foreach virtualhost: <...
Jürgen Paul's user avatar
  • 1,275
1 vote
0 answers
589 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 ...
user1394013's user avatar
1 vote
1 answer
139 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 ...
Fanda's user avatar
  • 188
1 vote
1 answer
777 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 proxy.example....
user6669's user avatar
  • 145
1 vote
0 answers
1k views

Is there any way I can install nginx with tcp_proxy module as a ubuntu package?

I've installed my nginx via the ppa package add-apt-repository ppa:nginx apt-get install nginx which works just fine. But now I need to add support for websockets for my socket.io app. I found some ...
Jakub Arnold's user avatar
  • 1,794
1 vote
0 answers
666 views

php5cgi keeps dying and nginx gives 502 Bad Gateway

I have nginx on my server (Ubuntu 11.10). i have created the script below in /etc/init.d/php5cgi to start/stop/restart php5-cgi. the problem is that php5-cgi dies from time to another which makes my ...
Alaa Alomari's user avatar
1 vote
0 answers
1k views

High varnish CPU load when combining it WordPress and nginx for multiple sites

I recently applied the following setup to install WordPress plus W3 Total Cache on an nginx server with a varnish frontend to achieve high scalability. It works great when I'm only running one virtual ...
Joost Schuur's user avatar
1 vote
1 answer
2k views

NGINX: Setting Different FastCGI Read Timeouts for Folders

I have a PHP file in my /batch/ folder I run with an hourly CRON job. Unfortunately this process can often take a few minutes to complete so I have had to increase my fastcgi_read_timeout to 300 ...
Hart Jones's user avatar
1 vote
1 answer
554 views

How to redirect secure requests to another subdomain in nginx

I've been searching pretty long for this one, but nothing I seem to read works right -- maybe I'm not searching for the right things. Anyway, we have a www.example.com and a secure.example.com. I'm ...
paulnsorensen's user avatar

1
41 42
43
44 45
119