user root; worker_processes 4; worker_rlimit_nofile 102400; daemon off; events { use epoll; worker_connections 102400; accept_mutex off; } http { include mime.types; default_type application/octet-stream; access_log off; keepalive_timeout 300; keepalive_requests 1000000; proxy_connect_timeout 300; large_client_header_buffers 4 512k; client_max_body_size 3000m; client_header_buffer_size 2048m; client_body_buffer_size 1024m; proxy_buffers 16 10240k; proxy_buffer_size 10240k; gzip on; upstream bk { server 10.10.2.1:8091; keepalive 30000; } upstream bk1 { server 10.10.2.1:8092; keepalive 30000; } upstream bk2 { server 10.10.2.1:8093; keepalive 30000; } server { listen 80; server_name 10.10.1.2; server_tokens off; proxy_redirect off; location / { root html; index index.html index.htm; proxy_pass http://bk; proxy_set_header Connection ""; proxy_set_header X-Original-URI $request_uri; proxy_set_header Host $host:$server_port; chunked_transfer_encoding on; proxy_http_version 1.1; mirror /mimic1; mirror /mimic2; mirror_request_body on; } location /mimic1 { proxy_pass http://bk1$request_uri; proxy_set_header X-Original-URI $request_uri; proxy_set_header Connection ""; chunked_transfer_encoding on; proxy_http_version 1.1; proxy_set_header Host $host:$server_port; } location /mimic2 { proxy_pass http://bk2$request_uri; proxy_set_header X-Original-URI $request_uri; proxy_set_header Host $host:$server_port; proxy_set_header Connection ""; proxy_http_version 1.1; chunked_transfer_encoding on; } } }