Welcome! Log In Create A New Profile

Advanced

Error: Couldn't connect to server

mohan prakash via nginx
April 27, 2018 09:10AM
Hi Team

I am trying execute ~1000 curl request from my CentOS machine to my nginx server in ~5 sec.
The same exercise continuous every ~5sec.

I am using libcurl to make the HTTP request.

During this process i see most of my request are failed with reason

Failure Curl Error Code[ 7 ] Reason[ Couldn't connect to server ]

Can someone suggest whether i am missing any configuration info in my nginx server. Below is my nginx server configuration

user nginx;
worker_processes auto;
error_log /var/log/nginx/error.log;
pid /run/nginx.pid;

# Load dynamic modules. See /usr/share/nginx/README.dynamic.
include /usr/share/nginx/modules/*.conf;


worker_rlimit_nofile 262144;

events {
    worker_connections 16384;
}

http {
    log_format  main  '$remote_addr - $remote_user [$time_local] "$request" '
                      '$status $body_bytes_sent "$http_referer" '
                      '"$http_user_agent" "$http_x_forwarded_for"';

    access_log  /var/log/nginx/access.log  main;

    sendfile            on;
    tcp_nopush          on;
    tcp_nodelay         on;
    keepalive_timeout   65;
    types_hash_max_size 2048;

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

    # Load modular configuration files from the /etc/nginx/conf.d directory.
    # See http://nginx.org/en/docs/ngx_core_module.html#include
    # for more information.
    include /etc/nginx/conf.d/*.conf;

    limit_conn_zone $binary_remote_addr zone=perip:10m;
    limit_conn_zone $server_name zone=perserver:10m;

    server {
        limit_conn perip 2000;
        limit_conn perserver 20000;
        listen *:8080 backlog=16384;
    }
}

RegardsMohanaprakash T
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Error: Couldn't connect to server

mohan prakash via nginx April 27, 2018 09:10AM

Re: Error: Couldn't connect to server

Liu Lantao April 27, 2018 09:38AM

Re: Error: Couldn't connect to server

mohan prakash via nginx April 27, 2018 11:34AM

Re: Error: Couldn't connect to server

pbooth April 27, 2018 12:02PM

Re: Error: Couldn't connect to server

mohan prakash via nginx April 28, 2018 07:34AM

Re: Error: Couldn't connect to server

oscaretu April 28, 2018 08:28AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 185
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready