Welcome! Log In Create A New Profile

Advanced

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

October 16, 2017 03:32PM
Advice
- instead of tweaking values, first work out what is happening,
locate the bottleneck, then try adjusting things when you have a theory


First QN you need to answer:
For your test, is your system as a whole overloaded?

As in, for he duration of the test is the #req/se supported constant?
Is the request time shown in nginx log increasing?
If you capture the output of net stat -ant | grep -i tcp > aa is the # of tcp connections changing wit time


Some other key questions:

Does every PHP request involve a call to mysql?
Is there a connection pool or does every PHP instance have its connection to mysql
When you do your test are you ramping up workload do you have a consistent workload?
How many requests per second are seeing from the nginx logs?


How are you driving the test traffic and from what host?
Ar you logging the request execution time in the nginx log?
The ps output that you pasted only showed 36 PHP processes but
your initial config specified 400 max_children

If consistent, how many virtual agents / independent request sources do you have?

What do you mean “losing visitors abnormally?”
how are you seeing this?
Do you realize that your PHP process is configured to die after serving 800 (now 2500)
requests and then needs to be restarted?


> On Oct 16, 2017, at 3:04 PM, agriz <nginx-forum@forum.nginx.org> wrote:
>
> worker_processes 4;
> worker_rlimit_nofile 40000;
>
> events {
> worker_connections 4096;
> # accept_mutex on;
> # accept_mutex_delay 500ms;
> multi_accept on;
> use epoll;
> }
>
> pm.max_children = 50
> pm.start_servers = 4
> pm.min_spare_servers = 4
> pm.max_spare_servers = 32
> pm.max_requests = 2500 //modified
> rlimit_files = 131072 //modified
> rlimit_core = unlimited //modified
>
> # TCP Stack changes
> net.ipv4.tcp_fin_timeout = 20
> net.ipv4.tcp_tw_reuse = 1
> net.core.netdev_max_backlog = 10000
> net.core.somaxconn = 2048
> net.ipv4.tcp_max_syn_backlog = 2048
> net.ipv4.ip_local_port_range = 15000 65000
>
> But still not efficient.
> Losing visitors abnormally
>
> Posted at Nginx Forum: https://forum.nginx.org/read.php?2,276892,276900#msg-276900
>
> _______________________________________________
> nginx mailing list
> nginx@nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx

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

E3-1240 with 32GB Ram - Unable to set the optimal value for the server

agriz October 16, 2017 12:37PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

Iurii Medvedev October 16, 2017 12:50PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

agriz October 16, 2017 12:59PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

rsdrsd October 16, 2017 01:26PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

agriz October 16, 2017 01:32PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

rsdrsd October 16, 2017 01:36PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

agriz October 16, 2017 01:52PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

Iurii Medvedev October 16, 2017 02:20PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

agriz October 16, 2017 03:04PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

pbooth October 16, 2017 03:32PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

pbooth October 16, 2017 03:36PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

agriz October 16, 2017 03:55PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

pbooth October 16, 2017 11:50PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

agriz October 17, 2017 12:39AM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

pbooth October 17, 2017 08:18PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

GreenGecko October 18, 2017 03:36AM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

Brian October 16, 2017 04:06PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

agriz October 16, 2017 11:38PM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

agriz October 17, 2017 01:31AM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

agriz October 17, 2017 01:48AM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

agriz October 17, 2017 01:50AM

Re: E3-1240 with 32GB Ram - Unable to set the optimal value for the server

pbooth October 17, 2017 02:00AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 293
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