14 messages in ru.sysoev.nginxNginx double requests for my upstreams?
FromSent OnAttachments
funkdoobiestJun 5, 2009 4:58 am 
Maxim DouninJun 5, 2009 6:30 am 
funkdoobiestJun 7, 2009 12:35 pm 
Michael ShadleJun 7, 2009 12:49 pm 
Maxim DouninJun 7, 2009 1:56 pm 
funkdoobiestJun 8, 2009 3:44 am 
Maxim DouninJun 8, 2009 5:20 am 
funkdoobiestJun 22, 2009 7:19 pm 
funkdoobiestJun 23, 2009 4:47 am 
Maxim DouninJun 23, 2009 5:23 am 
funkdoobiestJun 23, 2009 7:32 am 
Maxim DouninJun 23, 2009 7:56 am 
funkdoobiestJun 30, 2009 7:54 am 
Maxim DouninJun 30, 2009 9:47 am 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:Nginx double requests for my upstreams?Actions...
From:funkdoobiest (ngin@nginx.us)
Date:Jun 5, 2009 4:58:50 am
List:ru.sysoev.nginx

Hi,

I have a strange behavior for my site load balanced with nginx. I have 1 Loadbalancer with nginx and 3 servers with apache.

sometimes a request is doubled and send to 2 of my apache webservers. this is a big problem for me, because this is sometimes a requests that is doing
a payement. I checked this behavior with doing a log of all my payment transactions and
there a some transactions for the same person double at the same second! (the user can't do this at the
website, because I send the form which is doing the request with JS and ask the
User if he really wants to pay and so on)

Here are my config files for nginx, please help me:

#ningx.conf user www-data; worker_processes 4;

error_log logs/error.log; #error_log logs/error.log notice; #error_log logs/error.log info;

#pid logs/nginx.pid;

events { worker_connections 512; }

http {

include mime.types; include proxy.conf;

access_log logs/access.log combined;

sendfile on; tcp_nopush on;

keepalive_timeout 0; #keepalive_timeout 15;

#gzip on;

include upstream.conf;

include server_www.conf;

}

# proxy.conf proxy_redirect off; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; client_max_body_size 10m; client_body_buffer_size 128k; proxy_connect_timeout 90; proxy_send_timeout 90; proxy_read_timeout 90; proxy_buffers 32 4k;

#upstream.conf upstream webseite { ip_hash; server 10.XXX.XX.1:8081; server 10.XXX.XX.2:8081; server 10.XXX.XX.3:8081; }

#server_www.conf server { listen 80; server_name www.website.com;

# serve static files location ~* ^.+.(jpg|jpeg|gif|css|png|js|ico|html|htm|swf)$ { root /var/www/www.website.com/; expires 1d; }

location / { proxy_pass http://webseite; } }

Thank you!

Posted at Nginx Forum: http://forum.nginx.org/read.php?2,2644,2644#msg-2644