将apache2的最高性能设置为70% - 80%

时间:2015-05-27 16:46:39

标签: apache apache2 setting

我尝试在apache2.conf上编辑它

<IfModule mpm_prefork_module>
    StartServers          8
    MinSpareServers       8
    MaxSpareServers      15
    ServerLimit        2000
    MaxClients         2000
    MaxRequestsPerChild   0
</IfModule>

StartServers和MinSpareServers从5到8
MaxSpareServers从10到15
ServerLimit和MaxClients从默认为2000。

来自apachebuddy的报告

    Apache is using prefork model
    Examining your Apache configuration...
    Apache runs as www-data
    Your max clients setting is 150
    Analyzing memory use...
    Your server has 30227 MB of memory
    The largest apache process is using 42.51 MB of memory
    The smallest apache process is using 15.52 MB of memory
    The average apache process is using 24.80 MB of memory
    Going by the average Apache process, Apache can potentially use 3720.01 MB RAM (12.31 % of available RAM)
    Going by the largest Apache process, Apache can potentially use 6376.51 MB RAM (21.10 % of available RAM)
    Generating reports...
    ### GENERAL REPORT ###
    Settings considered for this report:
            Your server's physical RAM:             30227MB
            Apache's MaxClients directive:          150
            Apache MPM Model:                       prefork
            Largest Apache process (by memory):     42.51MB
    [ OK ]  Your MaxClients setting is within an acceptable range.
            Max potential memory usage:             6376.5 MB
            Percentage of RAM allocated to Apache   21.10 %
    -----------------------------------------------------------------------
    -----------------------------------------------------------------------


服务器规格
8 CPU
30GB RAM
800GB SSD

我的网站2000上的平均用户在线(我看到的最大值是3100)

我需要让3100用户在线保持我的网站平稳运行,并获得最佳性能。使用70-85%可用的RAM。

谢谢你们

0 个答案:

没有答案