cundeng 发表于 2018-11-25 15:12:55

Cacti和Zabbix所需Apache安装配置(三)

  上接“Cacti和Zabbix所需Apache安装配置(一)”(http://rolandqu.blog.51cto.com/3477736/945717)
  上接“Cacti和Zabbix所需Apache安装配置(二)”(http://rolandqu.blog.51cto.com/3477736/945731)
  7. httpd-mpm.conf 配置文件示例


[*]
[*]    PidFile "logs/httpd.pid"
[*]
[*]
[*]
[*]LockFile "logs/accept.lock"
[*]
[*]
[*]
[*]    ServerLimit      4000
[*]    StartServers         10
[*]    MinSpareServers      10
[*]    MaxSpareServers      20
[*]    MaxClients          300
[*]    MaxRequestsPerChild 150
[*]
[*]
[*]    StartServers          2
[*]    MaxClients          150
[*]    MinSpareThreads      25
[*]    MaxSpareThreads      75
[*]    ThreadsPerChild      25
[*]    MaxRequestsPerChild   0
[*]
[*]
[*]    StartThreads            10
[*]    MaxClients            50
[*]    MaxRequestsPerThread 10000
[*]
[*]
[*]    ThreadStackSize      65536
[*]    StartThreads         250
[*]    MinSpareThreads         25
[*]    MaxSpareThreads      250
[*]    MaxThreads            1000
[*]    MaxRequestsPerChild      0
[*]    MaxMemFree             100
[*]
[*]
[*]    StartServers         2
[*]    MinSpareThreads      5
[*]    MaxSpareThreads       10
[*]    MaxRequestsPerChild    0
[*]
[*]
[*]    ThreadsPerChild      150
[*]    MaxRequestsPerChild    0
[*]

  8. vhosts.conf 配置文件示例


[*]NameVirtualHost YourServerIpAddr:80
[*]SetEnvIf Request_URI "\.gif$" dontlog
[*]SetEnvIf Request_URI "\.jpg$" dontlog
[*]SetEnvIf Request_URI "\.jpeg$" dontlog
[*]SetEnvIf Request_URI "\.png$" dontlog
[*]SetEnvIf Request_URI "\.js$" dontlog
[*]SetEnvIf Request_URI "\.swf$" dontlog
[*]SetEnvIf Request_URI "\.css$" dontlog
[*]SetEnvIf Request_URI "/favicon.ico$" dontlog
[*]SetEnvIf Request_URI "^/error.wml$" dontlog
[*]SetEnvIf Request_URI "^/wml.php$" dontlog
[*]
[*]    DocumentRoot "/data/website/sample.troodo.net/htdocs"
[*]    ServerName sample.troodo.net
[*]    ServerAlias sample.troodo.net
[*]    ErrorDocument 404 http://sample.troodo.net
[*]    CustomLog "|/usr/local/cronolog/sbin/cronolog /data/website/sample.troodo.net/logs/access_log.%y%m%d" combined env=!dontlog
[*]    ErrorLog "|/usr/local/cronolog/sbin/cronolog /data/website/sample.troodo.net/logs/error_log.%y%m%d"
[*]   
[*]      DirectoryIndex index.wml index.html index.php
[*]      AddHandler server-parsed .shtml
[*]      AddType text/html .shtml
[*]      AddHandler server-parsed .inc
[*]      Options +Includes
[*]      AllowOverride None
[*]      Order allow,deny
[*]      Allow from all
[*]   
[*]




页: [1]
查看完整版本: Cacti和Zabbix所需Apache安装配置(三)