Apache settings - httpd.conf

xiaoxiao2021-03-06  41

This setting is of course Apache1.x, and after 2 is apache2.conf.

● HTTPD.CONF setting file parameter description

# 语 法: ServerType [Standalone / INTED] # Description: Define httpd start-up mode # Standalone: ​​Immediately after boot, high efficiency, HTTP independently, even if no viewers are connected to this website,

Will start HTTPD to provide services with the boat.

# inted: Temporary to start when needed, listen to all ports that enter the native request, then check the services corresponding to Port

To decide which service to use, execute httpd, ending the httpd when the request is completed.

# 语法: Port [Number] # Description: Specifies the gateway of the HTTPD service, usually 80, the URL after # 2000 must be written into http: //xx.xx.xx.xx: 2000 /

# Syntax: Hostnamelookups [ON / OFF] # Description: Set whether to turn the automatic search hostName to open # set to ON, record the host name of the user who enter this website (such as fo23.flag.com.tw)

# Set to OFF, only the IP of the user host (for example, 203.74.205.23)

# Syntax: User [username / # uid] # Description: Setting the executor of the httpd program. #Mhirting is Nobody, or it can be registered User, if you want to use the user ID ##

# 语 法: Group [groupname / # gid] # Description: Set the group of executors to this httpd program to the group # typically NOGROUP, this group must exist in / etc / group

# 语法: Server admin [e-mail] # Description: Set this WEB station manager's E-mail address, convenient to contact managers when an error occurs

# 语法: Serverroot [Directory absolute path] # Description: Set the absolute path installed by Apache, all sites related crotch cases are stored in this directory # Example: Serverroot / USR / local / apache

# 语 法: Bindaddress [* / ip / fqdn] # Description: Forced Apache only reacts a particular address, * is to react to all address # If you want to use the Virtual Host virtual host function, it is necessary to set it to bindaddress * # Description: Set which address to serve, you can use the IP or complete host name (FQDN), # * is all accepted

# When using a virtual host function, there may be several online cards to set different IPs on one computer. Bindaddress

Set to *, indicating that the system monitors each IP connection; set to an IP value, listening only the IP connection; can also be set

Domain Name, only listening to the connection

# 语法: ERRORLOG [Archive Name] # Description: Record the error message generated when executing Apache, if the file name is not / start, then you will not connect # 接 接 s er er # # Example: ErrorLog logs / error_log # Error message Put in / usr / local / apache / logs / error_log # Apache Root Directory in / usr / local / apache

# 语法: Loglevel [Debug / Info / Notice / Warm / Error / Crit / Alert / Emerg] # Description: Set the error message species recorded in Error_Log, the recommended value is WARM, the more you click on the right side # 语法: CustomLog [file name] [Combined / Common / Referer / Agent] # Description: With the ERRORLOG part, it is a transmission record and sets the information recorded in the record. Example: Customlog logs / access_log common (Common is a suggested value) # The more the right side The more simply # if user is more, this file will be great, be careful

# Logformat "% h% l% u% T /"% r / "%> S% b /"% {referer} I / "/"% {user-agent} I / "" Combined

# Logformat "% H% L% u% T /"% r / "%> s% B" Common

# Logformat "% {refrer} @ ->% u" Referel

# LogFormat "% {user-agent} i" Agent

# Set the 楁 of each record, there are four kinds of combined, common, refrer and Agent

# The location of the access logfile (Common logfile format)

# I i @@ Not Start with /, ServerRoot Is Prepended to IT.

# Customlog / USR / local / apache / var / log / access_log common

#Egle the location of the record, use the COMON format

# Imp You Would Like To Have An Agent and Referer Logfile Uncomment THE

# FOLLOWING DIRECTIVES.

# Customlog / USR / local / apache / var / log / referer_logreferel

# Record the viewer to use the Refere "Self-order format via the URL throwing out of this website

# Customlog / usr / local / apache / var / log / agent_logagent

# Record the browser to the browser version and type used by this website, use the Agent self-contained format

# Ration prefer a single logfile with access, agent and referer information

# (Combined logfile format) You can use the Following Directive.

# Customlog / usr / local / apache / var / log / access_log combined

# 语法: Pidfile [PID-filename] # Description: Record the PID at HTTPD starts to facilitate administrator management; make reference when restarting, # This does not have to use PS to find # example: pidfile logs / httpd.pid

# Pidfile /usr/local/apache/var/run/httpd.pid ← Record httpd PID

# 语法: scoreboardfile [file name] # Description: Record used file # example: scoreboardfile logs / apache_runtime_status

# Syntax: ServerName [Host Name] # Description: Set the Domain Name of the server, this name must be registered with DNS to your network. # Example: ServerName www.hmes.kh.edu.tw ← If there is no registration DNS Name, please change to IP # Syntax: cachenegotiatedDocs

# Description: When the user reads Web Server when using proxy, Apache HTTPD will send PRAGMA:

# No-cache's file makes Proxy Server not staying him in Cache.

# 语法: Timeout [second]

# Description: Set the time of the HTTPD waiting for the user next instruction, if the user does not respond during this time

#, Terminate the service if the network speed is slow, and the time is a long.

# Example: Timeout 300

# 语法: Keepalive [ON / OFF] # Description: Set whether to accept the continuous request of the user.

# Syntax: MaxkeepaliveRequests [Number] # Description: Set the maximum continuous request for acceptance, if the continuous request exceeds this number, Server will automatically kick. # Example: MaxkeepaliveRequests 100 ← Each connection can be made, set to 0 indicate unlimited number of times, set to 100

# 语 法: KeepaliveTimeout [second] # Description: Set the user's continuous request waiting time limit, if the user continuously requests the time exceeds this number, then # no longer execute this request # Example: KeePaliveTimeou 15 ← Next requirement If more than how much Seconds have not arrived, it is considered to end

# Syntax: MaxSpareServers [Quantity] # MINSPARSERVERS [Quantity] # Description: Set the number of servo to wait for the service, when the system's idle number is smaller than this setting, the system will open # check more Server; The number of idle numbers is greater than this setting, the extra number will be deleted #; If the web use rate is high, it should increase the MaxSpareServers 10 MinSpareServers 5

# 语法: StartServers [Quantity] # Description: When you drive the Apache httpd, the number of servers who idle waiting service will be sent. # Example: StartServers 5 ← (You can see these 5 serverProcesses)

# 语 法: MaxClients [Quantity] # Description: Set up to the maximum available to several USERs and connect # example: maxclients 150 ← Because the number of coming in, it will reduce the efficiency of system access, which can be set

This numerical limit is connected to the number of connectments, if your system CPU is very fast, many memory is very effective

Good time, you can consider raising this value. Otherwise it will reduce a little

# Syntax: MaxRequestSperChild [Quantity] # Description: Set the maximum number of services that each subroutine can accept, when this number is reached, the subroutine will automatically turn off #N: maxRequestSperchild 30

# 语法: proxyRequests [on / off]

# Description: Open or close the function of Proxy, the internal value is closed, and most cases are also closed. When installing, Apache does not join the Proxy module. If this feature is required, please refer to the installs file.

# Syntax: .. # Description: Settings of the virtual host; Before doing this setting, you must have a support Multipule Address or a piece of online card.

# 号: # NamevirtualHost 203.72.230.212 ## must be set, Apache 1.3 or above change ## ## first part

# ServerAdmin Webadmin@hmes.kh.edu.tw

# Set the managers mailbox for the virtual host, not necessarily the same as the local website manager

# Documentroot / WWW / DOCS / # Specify the home directory of the virtual host

# Servername wwwa.hmes.kh.edu.tw ## Name of VirtualHost # Specifies the URL of the virtual host

# Rlog logs / ?? ??

# # When the virtual host occurs, you want to record in which directory

# TransferLog logs / ??

# 虚 虚 机机 存 存 目 目 目 目 目 目

# # ## second DNS ## second part # ServerAdmin webadmin2@hmentroot / www / docs2 / # servername Wwwb.hmes.kh.edu.tw # ErrorLog logs / ?? # TransferLog logs / ?? #

转载请注明原文地址:https://www.9cbs.com/read-82868.html

New Post(0)