NginxHttpStubStatusModule Stats Incorrect?

Nathan Folkman nathan at foursquare.com
Fri Jan 8 18:30:43 MSK 2010


reluctant to move to 0.8 until it is out of dev and considered stable. also have nginx-upstream-jvm-route dependency that will need to be tested. if this is just a bug where some counter isn't getting incremented, i'm fine with it, just wanted to make sure something else wasn't happening. appreciate the help!

- nathan

/usr/local/nginx/sbin/nginx -V
nginx version: nginx/0.7.64
built by gcc 4.3.2 (Ubuntu 4.3.2-1ubuntu12) 
TLS SNI support enabled
configure arguments: --with-http_stub_status_module --add-module=../nginx-upstream-jvm-route-read-only/ --with-http_ssl_module

cat /usr/local/nginx/conf/nginx.conf

user nginx nginx;
error_log /data/logs/nginx/error.log error;
pid /var/run/nginx.pid;

worker_processes 8;
worker_rlimit_nofile 10240;

events {
    worker_connections 8024;
}

http {
    include mime.types;
    default_type application/octet-stream;
    limit_zone one $binary_remote_addr 10m;
    large_client_header_buffers 4 16k;
    output_buffers 1 32k;

    log_format upstream '$remote_addr - $remote_user [$time_local] '
        '"$request" $status $body_bytes_sent '
        '"$http_referer" "$http_user_agent" '
        '$request_time '
        '$upstream_addr '
        '$upstream_status '
        '$upstream_response_time '
        '$cookie_XSESSIONID';

    access_log /data/logs/nginx/access.log upstream;

    sendfile on;
    keepalive_timeout 10;
    tcp_nodelay on;

    upstream jettystickyrr {
        server web2:8080 srun_id=2;
        server web3:8080 srun_id=3;
        server web4:8080 srun_id=4;
        server web5:8080 srun_id=5;

        jvm_route $cookie_XSESSIONID reverse;
    }

    server {
        listen 80;
        server_name _;
        underscores_in_headers on;
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_connect_timeout 10;
        proxy_send_timeout 30;
        proxy_read_timeout 30;
        charset utf-8;

        if ($host ~* "www.playfoursquare.com") {
            rewrite ^(.*)$ http://foursquare.com$1 permanent;
        }

        if ($host ~* "playfoursquare.com") {
            rewrite ^(.*)$ http://foursquare.com$1 permanent;
        }

        if ($host ~* "www.foursquare.com") {
            rewrite ^(.*)$ http://foursquare.com$1 permanent;
        }

        location / {
            error_page 404 /error/404.html;
            error_page 500 /error/500.html;
            error_page 502 503 /error/503.html;
            proxy_intercept_errors on;
            proxy_pass http://jettystickyrr;
        }

        location /nginx_status {
            stub_status on;
            access_log off;
        }

        location /nginx_status_rr {
            access_log off;
            jvm_route_status jettystickyrr;
        }
    }
}




More information about the nginx mailing list