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

learn more… | top users | synonyms

-1
votes
2answers
12 views

nginx 1.8.1 only works with default root

I have Cent OS 6.6 with nginx 1.8.1 installed. It seems like if I change the root in the conf file to something other than the default '/usr/share/nginx' it gives an error 403 Permission denied. I ...
0
votes
1answer
17 views

Nginx: Access same content from multiple URLs

I'm trying to configure nginx so that the same static content can be accessed through two different URLs without any redirects. For instance, if the client enters /path/to/A in their browser, I want ...
0
votes
0answers
20 views

Ubuntu - Nginx + php5-fpm - suddenly times out every request even after restart

Caveat - Newbie nginx/php5-fpm/ubuntu I inherited a couple linux boxes and have had the same thing happen on both. I assume it's user error, but for the life of me I don't know what I did. ...
0
votes
0answers
5 views

nginx location redirect to folder with name as requested domain

I'm new to nginx and I want to do this: If the URL contains "/assets" redirect to "/communities/$url_domain" In other words: Requested: "http://www.cats.com/assets/superfile.png" ...
0
votes
1answer
8 views

nginx: proxy special file patterns (css) from s3

we are serving a web app with nginx. It proxys everything that comes in over https to a server listening on localhost. Now I want nginx to act as a proxy and serve our css files from s3. As I want ...
1
vote
1answer
1k views

Loadbalancing with nginx and tomcat

Hello this should be fairly easy to answer for any system admin, the problem is that I'm not server admin but I have to complete this task, I'm very close but still not managing to do it. Here is what ...
7
votes
2answers
1k views

Deploying Django App with Nginx, Apache, mod_wsgi

I have a django app which can run locally using the standard development environment. I want to now move this to EC2 for production. The django documentation suggests running with apache and ...
2
votes
1answer
130 views

HTTP/2 returning weird symbols

So I switched my nginx server over to use HTTP/2, and it works for Edge and Chrome. On IE11 however I'm getting no response, only this: http://i.imgur.com/zGRI6th.png On firefox the page simply ...
0
votes
2answers
19 views

Why is nginx running with a new PID each time I list my processes

Why is nginx restarting with a new PID each time I list processes? And also, why is nginx running to begin with? Refer to image below for output. Nginx Output I don't know if this is useful but I ...
0
votes
0answers
10 views

Nginx failed space when upload

I've a problem with my nginx server. He is a storage server, and when i want to upload a file (2,5G) i can show any error on my error.log 2016/02/08 03:26:24 [crit] 7843#0: *1154 pwrite() ...
0
votes
0answers
11 views

When does nginx's proxy_pass return 301 and when does it forward the request?

When using a nginx server on a vagrant (hosted by virtualbox) i used this config ... server { port_in_redirect on; listen 80 default_server; listen [::]:80 default_server ipv6only=on; root ...
1
vote
0answers
14 views

Nginx per used directory sites configuration

I have virtual server with 25 hosts with WordPress sites. Users need to be able to access their sites via ~username from main domain like this : http://subdomain.example.com/~username/ which works ...
0
votes
1answer
21 views

Nginx configuration mix

Is it possible to mix some configuration settings in Nginx? For example there is the auth_basic, which should work everywhere. And there is some other configuration spefic for one directory. Or there ...
1
vote
2answers
2k views

how to delete single nginx cache file?

when access http://example.com/ its blank but working good with http://example.com/index.php i need to delete nginx cache file for http://example.com/ how to do it? Here my nginx cache conf. ...
1
vote
1answer
29 views

Nginx: handle location depending on HTTP method

I want to handle all [GET] requests to /api from cache and handle all other requests as in last location block (without cache). All the requests to /api with methods PUT, POST, DELETE also have not to ...
0
votes
0answers
16 views

Deleted an error log and it won't regenerate

I'm a novice and hoping that someone with more experience can help me with this. I am running a VPS with CentOS 6.7 and nginx. The error log was getting very large and I was worried it would take up ...
-1
votes
0answers
17 views

HTTPS redirects with cloudflare SSL

I am using the Cloudflare to expose my application server as http and https. Because the nginx back-end is http, internal redirects (http 201, 301, 302) contain the server http address in the Location ...
0
votes
0answers
23 views

What is a correct way(s) to allow login to an IIS site through a reverse proxy?

I have an nginx reverse proxy, and I'm trying to get an IIS website with login to work behind it. I've found this question asked several times, but each answer appears to be different, and some of ...
0
votes
1answer
15 views

Installing Nginx “Headers More” module with YUM

I would really like to avoid the custom patching/compiling stuff as upgrades are a nightmare. On Nginx, which I've installed using yum install nginx18, I'd also like to enable the popular module: ...
5
votes
2answers
154 views

nginx use proxy cache if backend is down

I need to nginx proxy use cache if backend server down: this is my configuration. but seems be nginx use cache without check backend server. http { # ... proxy_set_header Host $host; ...
0
votes
0answers
6 views

Dynamic Partition Based Proxying [on hold]

In scalable architectures which partition (shard) systems using the userid or tenantId as the key, I was curious to know what are the common products that are used for routing requests intelligently ...
1
vote
1answer
2k views

Kibana 4, Logstash dashboard: how do I require Nginx authentication when saving but allow anonymous views?

I would like to require auth_basic nginx authentication to save all kibana 4 dashboards but allow anyone to view dashboards without authentication. I recently installed an ELK (Elasticsearch 1.4.5, ...
-1
votes
1answer
29 views

Case insensitivity in nginx

We have several SEO pages like: http://www.example.com/PageOne.html Which we redirect in config like: location = /PageOne.html { rewrite ^/(.*) /seo.php?id=1 last; } Problem is if a user ...
15
votes
3answers
2k views

Is there an elegant way to block a bunch of referrers at once?

In order to prevent referrer spam, my nginx.conf contains a section like this: if ($http_referer ~* spamdomain1\.com) { return 444; } if ($http_referer ~* spamdomain2\.com) { return 444; } if ...
0
votes
1answer
27 views

How do I proxy pass a URL in Nginx where location match is a URL and proxy pass has another URL

We have hosted some xml files in a S3 bucket on Amazon AWS. The web server is powered by Nginx. For a particular URL matching '/super-shots.xml' , Nginx must proxy pass through S3 location which is : ...
0
votes
2answers
991 views

Dynamic throttling of bandwidth

I am planning on setting up streaming server. Streaming is done kind of like YT does it; there will be a large number of audio content and each user can listen to it right on the website. In order ...
0
votes
1answer
22 views

How do I tell Nginx to pass requests to different apps based on the incoming url?

How do I tell Nginx to pass requests to different apps based on the incoming url? For example, mybudgetapp.com and myshoppingapp.com both point to my server where both apps (8001, 8002) and Nginx ...
0
votes
1answer
2k views

How do you get multiple ports working with nginx proxy_pass and Node Express?

I have multiple node instances running each on a different port. (8000, 8001, etc.) I also have nginx running on port 80. What I am trying to do is allow a user to enter my site via a single domain ...
3
votes
1answer
512 views

Cron Daemon Wget blocked

I've got nginx on Debian 7 without cpanel. I am seting-up my Crontab like this: */45 * * * * wget "http://example.com/cron-url.php" >/dev/null 2>&1 The above cron is being blocked with ...
4
votes
2answers
7k views

nginx uLimit 'worker_connections exceed open file resource limit: 1024'

I keep getting this error in nginx/error.log and its driving me nuts: 8096 worker_connections exceed open file resource limit: 1024 I've tried everything I can think of and cant figure out what is ...
1
vote
1answer
1k views

How to properly use nginx echo support to respond with a 504 inline page?

I am trying to reply with a custom 504 page by using nginx echo support but for some strange reason when this is active the browser downloads the response instead of opening it. server { ...
-2
votes
2answers
43 views

redirect https://www.example.com to https://example.com in nginx

I have SSL issued for domain.com. Now these url works fine: http://www.example.com -> https://example.com http://example.com -> https://example.com https://example.com But when accessed with ...
1
vote
1answer
59 views

Maximum server attempts from upstream in Nginx

I have configured Nginx load balancing between backend servers. upsteam backend { server 127.0.0.1:8080; server 127.0.0.1:8081; server 127.0.0.1:8082; server 127.0.0.1:8083; } server ...
-1
votes
0answers
14 views

Parameterized configuration templates/macros with nginx [on hold]

I have several websites hosted on the same server and they all share similar, but slightly different configurations. With Apache I could define a <Macro> that accepted arguments, but with nginx ...
-1
votes
0answers
18 views

how to resolve domain in frontend nginx load balancer for two backend apache servers

how to resolve domain in frontend nginx load balancer for two backend apache servers...? we have confired nginx load balancer in frontend... and then configured two apache web-server in backend... ...
0
votes
1answer
1k views

Nginx subdomain proxypass

I want to redirect non-ssl traffic to ssl for all subdomains. I want to keep the subdomain the same. I want to specify a different proxy_pass for staging.foo.com. I only have 3 things going right now ...
1
vote
2answers
995 views

How i can set an index with parameters under nginx?

under Apache I can set the index very easy. Like: DirectoryIndex index.php?parameter=xyz How can I set this in nginx? I had tried: index index.php?parameter=xyz but I get an 403 error.
1
vote
3answers
1k views

Nginx custom 404 page results in 500 internal server error

Here is my nginx config: server { # Running port listen 80; error_page 404 /404; # Settings to by-pass for static files location ^~ / { # Example: # root ...
2
votes
1answer
12 views

nginx return adds trailing slash to url

This redirect adds a trailing slash which breaks the link I would like to spend people to, the exact code follows: server { listen 80; server_name graphwhy.org; return 301 ...
2
votes
1answer
61 views

Nginx rewrite, reset rewrite or add extensions to a specific directory

Here's my nginx site config: server { server_name DOMAIN.COM; access_log /srv/www/DOMAIN.COM/logs/access.log; error_log /srv/www/DOMAIN.COM/logs/error.log; root /srv/www/DOMAIN.COM/public_html; ...
0
votes
1answer
35 views

Reverse proxy caching Steam stream

I'm currently using nginx to cache Steam downloads for my local network as detailed by Multiplay. This works great, but Steam has a feature to watch other users games via a stream not unlike Twitch ...
1
vote
1answer
993 views

Why is Perl Cgiwrap Sock refusing connection to nginx?

Could anyone shed some light on the following line in my nginx error logs. I'm trying to get Perl and Nginx talking to each other, but so far no success. unix:/var/run/nginx/cgiwrap-dispatch.sock ...
1
vote
1answer
32 views

Nginx serving .PHP as a download only when .php is added with arguments

Here is my current nginx config: server { server_name mydomain.example; access_log /srv/www/mydomain.example/logs/access.log; error_log /srv/www/mydomain.example/logs/error.log; root ...
0
votes
5answers
3k views

nginx: php-fastcgi running but php files not executing

I have recently set up a nginx server with PHP running as FastCGI process. The server is running with HTML files however PHP files are downloading instead of displaying and PHP code is not processed. ...
2
votes
2answers
147 views

RHEL Nginx SSL versus non SSL performance huge difference.

I'm in the process of setting up an Nginx 1.8 reverse proxy. In short - Serving HTML content HTTP traffic is up to 50x faster than HTTPS. Serving ProxyPass HTTP traffic is up to 7x faster than ...
-1
votes
1answer
19 views

Hiding parameters on url with nginx

I have a website with this kind of adresses: www.mydomain.com/user/userprofile/[userprofile1]?r=[login]&w=[encryptedpassword] ie: ...
1
vote
2answers
1k views

Varnish 4 Working Config (optimized) for Wordpress (default.vcl)

I have successfully set up varnish 4 on my nginx 1.6.2 it is working but as per the test on http://www.isvarnishworking.com/ it shows Varnish appears to be responding at that url, but the ...
0
votes
1answer
997 views

Moving Zend Framework 2 from apache to nginx

I would like to move site that uses Zend Framework 2 from Apache to Nginx. The problem is that site have 6 modules, and apache handles it by aliases defined in httpd-vhosts.conf, #httpd-vhosts.conf ...
0
votes
1answer
28 views

Pointing Custom Domain to Server on Nginx

I have my server up and running on an Azure Ubuntu 14.04 virtual machine. It is working great. Now I want to point my custom domain to it so that users can visit my website by going to www.example.com ...
1
vote
0answers
25 views

migrating htaccess from Apache to nginx

I'm trying to start using Homestead for my non-Laravel projects (legacy) and I managed to install box 0.3.3 successfully by cloning laravel/homestead 2.2.1 (with PHP 5.6.15). Now my problem is due to ...