mod_fcgid:無法套用進程槽 - 錯誤每 6 小時重複一次

mod_fcgid:無法套用進程槽 - 錯誤每 6 小時重複一次

在伺服器上,我使用 PHP 7.4.13 透過 FastCGI 運行 Apache:

/etc/httpd/conf.d/配置如下:

# Use FastCGI to process .fcg .fcgi & .fpl scripts
AddHandler fcgid-script fcg fcgi fpl

# Sane place to put sockets and shared memory file
FcgidIPCDir /run/mod_fcgid
FcgidProcessTableFile /run/mod_fcgid/fcgid_shm

FcgidMaxRequestLen 33554432
FcgidIOTimeout 3600
FcgidBusyTimeout 3600

FcgidConnectTimeout 300
FcgidMaxRequestsPerProcess 500

FcgidMaxProcesses 10000
FcgidMaxProcessesPerClass 5000

然而,大約每 6 小時,伺服器就會「崩潰」(FTP 正在工作,來自子網域的靜態內容正在工作,SSH 正在工作)並且錯誤日誌充滿了

mod_fcgid: can't apply process slot for /var/www/php-bin/domain/php

在此期間伺服器資源是免費的:htopTasks約為600,我有190GB RAM(佔用了60GB)和40 個核心(根據htop,全部低於5%),因此有足夠的電量,但伺服器沒有回應並返回500-家庭錯誤。重置後一切恢復正常。

根據 Apache 訪問日誌,似乎沒有“奇怪”的活動。我目前rsync在低優先權模式下運行(複製數百萬個小檔案)來備份我的光碟,當我開始時,這個問題最近開始出現rsync。我不確定這是否是相關問題,但我無法退出rsync

相關內容