我们正在使用Apache 2.4,我们正在尝试为事件MPM配置MaxRequestWorker和ThreadLimit。以下是我在apache的httpd.conf中的配置。但配置似乎没有任何效果。它仍然继续使用默认值(400 MaxRequestWorker和25 Threads)。不确定我的配置中是否遗漏了任何内容。
我想配置我的服务器使用1024 MaxRequestWorker和64 ThreadsPerChild。
我们在SWAP,Apache 2.4(EVENT MPM)和Red Hat Linux OS中大约有2Gig RAM和2Gig。
任何帮助都会有所帮助。非常感谢你!!
Httpd.conf
------------
Event MPM
# StartServers: initial number of server processes to start
# MaxClients: maximum number of simultaneous client connections
# MinSpareThreads: minimum number of Event threads which are kept spare
# MaxSpareThreads: maximum number of Event threads which are kept spare
# ThreadsPerChild: constant number of Event threads in each server process
# MaxRequestsPerChild: maximum number of requests a server process serves
<IfModule event.c>
ServerLimit 16
StartServers 8
MaxRequestWorkers 1024
MinSpareThreads 75
MaxSpareThreads 250
ThreadsPerChild 64
ThreadLimit 64
MaxConnectionsPerChild 0
</IfModule>
答案 0 :(得分:2)
我意识到这是一篇旧帖子。以防万一其他人再遇到这个问题。
LoadModule mpm_event_module
复制此模块名称'mpm_event_module'。
不是在httpd.conf的末尾指定它,最好在/etc/httpd/conf.d/中创建一个名为mpm_event.conf的文件并将其加载到那里。
在这种情况下,我相信改变:
<IfModule event.c>
到
<IfModule mpm_event_module>
亲切的问候,
威尔