nginx - Apache ab 不起作用 - ab : invalid URL when testing python cyclone

标签 nginx apachebench cyclone

我正在尝试 ab 测试旋风。

当我跑

ab -n 2000 -c 25 http://127.0.0.1

我得到 ab:无效的 URL。

嗯...当我在我的开发机器上访问 ff 时,该站点就在那里。

这是我的 nginx 配置
http {

    upstream frontends {
        server 127.0.0.1:8051;
    }

    ##
    # Basic Settings
    ##

    sendfile on;
    tcp_nopush on;
    tcp_nodelay on;
    keepalive_timeout 30;
    types_hash_max_size 2048;
    # server_tokens off;
    # server_names_hash_bucket_size 64;
    # server_name_in_redirect off;

    include /etc/nginx/mime.types;
    default_type application/octet-stream;

        # Only retry if there was a communication error, not a timeout
        # on the Tornado server (to avoid propagating "queries of death"
        # to all frontends)
        proxy_next_upstream error;

    server {
        listen   80;
        server_name 127.0.0.1;

                location / {
            proxy_pass_header Server;
            proxy_set_header Host $http_host;
            proxy_redirect false;
            proxy_set_header X-Real-IP $remote_addr;
            proxy_set_header X-Scheme $scheme;
                 proxy_pass http://frontends;
        }

最佳答案

ab URL 后面需要一个斜杠。

这应该有效:

ab -n 2000 -c 25 http://127.0.0.1/

关于nginx - Apache ab 不起作用 - ab : invalid URL when testing python cyclone,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10483833/

相关文章:

ubuntu - 使用 nginx 配置 owncloud 的 Fastcgi 参数

ssl - Apache 工作台 : SSL handshake failing directly related to concurrency level

apache - 如何将随机输入从输入文件传递到 Apache 基准测试 (abs) 以对 URL 进行负载测试

Apache Bench POST : Is it possible to read from string or stdin, 而不是文件?

python - tornado 将 GET 和 POST 参数映射到列表。如何禁用此 "feature"?

memory-leaks - 使用 Twisted + Cyclone + PyPy 处理 POST 请求会导致内存泄漏?

jquery - nginx comet 使用 jquery 进行长轮询

django - Nginx 重定向到默认页面

ruby-on-rails - NGINX + rails + dokku 上的错误 502 Bad Gateway

python - Twisted/Cyclone/Tornado 的高阶网络框架/附加组件(网络登录/用户/管理员)?