Discover Centmin Mod today
Register Now

PHP-FPM WARNING: [pool www] server reached max_children setting (50), consider raising it

Discussion in 'Nginx, PHP-FPM & MariaDB MySQL' started by rdan, Jul 10, 2014.

  1. rdan

    rdan Premium Member Premium Member

    5,301
    1,328
    113
    May 25, 2014
    Ratings:
    +2,052
    Local Time:
    10:26 PM
    Mainline
    10.2
    This my current server: Server E3-SSD-3 - So you Start
    But with 2 x 120GB SSD only.

     
  2. eva2000

    eva2000 Administrator Staff Member

    49,039
    11,235
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +17,488
    Local Time:
    12:26 AM
    Nginx 1.21.x
    MariaDB 10.x
    oh thought you had SSD-2, so you went with SSD-3 with hardware raid ?
     
  3. rdan

    rdan Premium Member Premium Member

    5,301
    1,328
    113
    May 25, 2014
    Ratings:
    +2,052
    Local Time:
    10:26 PM
    Mainline
    10.2
    Sorry to bother you guys with my problem :)
    Yes average internet speed here is just 1 to 2 mbps plan, I myself is just using 2MPBS plan.

    This is a real problem on Asia, very poor internet speed.
     
  4. rdan

    rdan Premium Member Premium Member

    5,301
    1,328
    113
    May 25, 2014
    Ratings:
    +2,052
    Local Time:
    10:26 PM
    Mainline
    10.2
  5. eva2000

    eva2000 Administrator Staff Member

    49,039
    11,235
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +17,488
    Local Time:
    12:26 AM
    Nginx 1.21.x
    MariaDB 10.x
    I'd imagine your pain, I'd drive myself mad if I was on 2Mbps ! But interesting discussion coming out of your problem - learning is always good :D

    Ah I see they changed their product offerings again heh
     
  6. Matt

    Matt Well-Known Member

    890
    402
    63
    May 25, 2014
    Rotherham, UK
    Ratings:
    +643
    Local Time:
    3:26 PM
    1.5.15
    MariaDB 10.2
    Yep, with no change in payments for people with existing servers. Even though my spec has changed (3 x 120GB SSD now), it's £5 a month less :(
     
  7. Matt

    Matt Well-Known Member

    890
    402
    63
    May 25, 2014
    Rotherham, UK
    Ratings:
    +643
    Local Time:
    3:26 PM
    1.5.15
    MariaDB 10.2
    Actually, seems like their front page shows 3 x SSD, but they are only giving 2

    SSD-3 Help
     
  8. eva2000

    eva2000 Administrator Staff Member

    49,039
    11,235
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +17,488
    Local Time:
    12:26 AM
    Nginx 1.21.x
    MariaDB 10.x
    what SSDs they using ?

    looks like they just mounted 2 of the SSD and left the 3rd for end user to configure ?
     
  9. rdan

    rdan Premium Member Premium Member

    5,301
    1,328
    113
    May 25, 2014
    Ratings:
    +2,052
    Local Time:
    10:26 PM
    Mainline
    10.2
    I will install my own minimal CentoS install and use all of that 3 drives :D
     
  10. eva2000

    eva2000 Administrator Staff Member

    49,039
    11,235
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +17,488
    Local Time:
    12:26 AM
    Nginx 1.21.x
    MariaDB 10.x
  11. jeffwidman

    jeffwidman Active Member

    152
    27
    28
    Dec 3, 2014
    Ratings:
    +51
    Local Time:
    7:26 AM
    Hey George--question about this. In theory what you say makes complete sense, but question about how it works out in practice.

    I've got a VPS with 2 cores, load average between 0.1-0.2, so it's got plenty of CPU to spare. As long as CPU isn't the bottleneck, will php response times still get slower as max_children increases?

    I'm guessing my bottlenecks are RAM/Disk IO, so would increasing the children allow the CPU to handle more users concurrently in almost the same speed because the extra processes let the CPU start working on new requests while waiting on ram/disk?

    I'm playing around with the settings, but trying to also make sure my mental model of how this is working is correct.

    Other reason I ask is I've got a few medium-traffic sites on this box, and a number of low-traffic sites as well. I've been setting `pm.type = ondemand` for the low-traffic sites (every php app has its own separate php-fpm pool), but if it just takes up a little extra CPU cycles, and I've got extra to burn, then I might as well change that to dynamic with start_servers=1 and min_spare_servers=1. These sites will never be high-traffic, so latency rather than concurrency is the thing to optimize for them and having a pre-warmed php process would cut down on latency. I've been avoiding that because I didn't want the low-traffic sites to starve resources from the medium-traffic ones... your statement above about more cumulative php processes going will slow things down makes sense in theory. But if it's just CPU cycles, then in practice those aren't the bottleneck on this box, so despite the theory, I should still set them to dynamic. Thoughts?

    And yeah, I know it won't make a huge difference either way in real life, but as you know, I like to understand how things actually work under the covers. :)
     
    Last edited: Jun 3, 2015
  12. eva2000

    eva2000 Administrator Staff Member

    49,039
    11,235
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +17,488
    Local Time:
    12:26 AM
    Nginx 1.21.x
    MariaDB 10.x
    depends on what cpu related activity those php-fpm children are doing - i.e. if each children is pegged at 100% cpu thread usage
     
  13. elargento

    elargento Member

    349
    17
    18
    Jan 4, 2016
    Ratings:
    +43
    Local Time:
    11:26 AM
    10
    What does those parameters do?