익명 사용자
로그인하지 않음
토론
기여
계정 만들기
로그인
IT 위키
검색
PHP-FPM pm.min spare servers
편집하기
IT 위키
이름공간
문서
토론
더 보기
더 보기
문서 행위
읽기
편집
원본 편집
역사
경고:
로그인하지 않았습니다. 편집을 하면 IP 주소가 공개되게 됩니다.
로그인
하거나
계정을 생성하면
편집자가 사용자 이름으로 기록되고, 다른 장점도 있습니다.
스팸 방지 검사입니다. 이것을 입력하지
마세요
!
'''pm.min_spare_servers''' is a configuration directive in PHP-FPM (FastCGI Process Manager) used to specify the minimum number of idle (spare) worker processes that should be maintained in the pool. It is applicable when the process manager (pm) is set to '''dynamic'''. This directive ensures that there are always enough idle workers available to handle incoming requests without unnecessary delays. ==Overview== When PHP-FPM is configured to use the '''dynamic''' process management mode, it automatically adjusts the number of worker processes based on server load. The `pm.min_spare_servers` directive sets a lower limit on the number of idle worker processes to ensure that the server can quickly respond to spikes in traffic. Key characteristics: *It defines the minimum number of idle worker processes. *Applies only in '''dynamic''' process management mode. *Helps reduce latency by ensuring that spare workers are pre-allocated. ==Default Value== The default value of `pm.min_spare_servers` is system-dependent but is typically set to `1` or `2`. ==Configuration Example== Here is an example of configuring `pm.min_spare_servers` in the PHP-FPM pool configuration file (e.g., `www.conf`):<syntaxhighlight lang="ini"> ; Set the minimum number of spare (idle) servers pm = dynamic pm.min_spare_servers = 5 pm.max_spare_servers = 10 pm.start_servers = 7 pm.max_children = 50 </syntaxhighlight> ===Explanation=== *`pm = dynamic`: Enables dynamic process management mode. *`pm.min_spare_servers = 5`: Ensures that at least 5 idle worker processes are maintained. *`pm.max_spare_servers = 10`: Limits the maximum number of idle worker processes to 10. ==Applicability== The `pm.min_spare_servers` directive is useful in scenarios where: *There are sudden spikes in traffic that require immediate processing. *The server needs to balance resource usage by keeping idle workers available. ==Advantages== *Reduces response time by pre-allocating worker processes. *Helps manage server load dynamically without manual intervention. *Improves user experience during traffic surges. ==Limitations== *Setting too high a value can lead to unnecessary resource consumption (e.g., memory usage). *Does not apply to other process management modes like `static` or `ondemand`. ==Related Directives== *'''pm.max_spare_servers:''' Sets the maximum number of idle worker processes. *'''pm.start_servers:''' Defines the number of worker processes created on startup. *'''pm.max_children:''' Limits the total number of child processes. ==See Also== *[[PHP-FPM]] *[[Dynamic Process Management]] *[[pm.max_spare_servers]] *[[pm.max_children]] [[Category:Server Engineering]] [[Category:Configuration]] [[Category:PHP]]
요약:
IT 위키에서의 모든 기여는 크리에이티브 커먼즈 저작자표시-비영리-동일조건변경허락 라이선스로 배포된다는 점을 유의해 주세요(자세한 내용에 대해서는
IT 위키:저작권
문서를 읽어주세요). 만약 여기에 동의하지 않는다면 문서를 저장하지 말아 주세요.
또한, 직접 작성했거나 퍼블릭 도메인과 같은 자유 문서에서 가져왔다는 것을 보증해야 합니다.
저작권이 있는 내용을 허가 없이 저장하지 마세요!
취소
편집 도움말
(새 창에서 열림)
둘러보기
둘러보기
대문
최근 바뀜
광고
위키 도구
위키 도구
특수 문서 목록
문서 도구
문서 도구
사용자 문서 도구
더 보기
여기를 가리키는 문서
가리키는 글의 최근 바뀜
문서 정보
문서 기록