Apache最新官方配置文件中文版说明

2020-01-30 12:21:00王旭

# # The mod_mime_magic module allows the server to use various hints from the # contents of the file itself to determine its type. The MIMEMagicFile # directive tells the module where the hint definitions are located. # mod_mime_magic模块,允许服务器根据内容提示来识别文件型别。MIMEMagicFile指令告知模块“内容提示”应到何处找。 <IfModule mod_mime_magic.c> MIMEMagicFile conf/magic </IfModule>
# # HostnameLookups: Log the names of clients or just their IP addresses # e.g., www.apache.org (on) or 204.62.129.132 (off). # The default is off because it'd be overall better for the net if people # had to knowingly turn this feature on, since enabling it means that # each client request will result in AT LEAST one lookup request to the # nameserver. HostNameLookups: 客户日志或者仅其IP地址,如www.apache.org(on) 或者204.62.129.132 (off).默认为值设为off比较好,如果希望将此置为on将意味着第一次客户请求都至少要查询一次nameserver. # HostnameLookups Off
# # EnableMMAP: Control whether memory-mapping is used to deliver # files (assuming that the underlying OS supports it). # The default is on; turn this off if you serve from NFS-mounted # filesystems. On some systems, turning it off (regardless of # filesystem) can improve performance; for details, please see # http://httpd.apache.org/docs-2.0/mod/core.html#enablemmap # EnableMMAP: 控制是否通过内存映射的方式传送文件(须得操作系统支持) 默认值为on; 如果你使用NSF加载的文件系统(通常在linux下),应置为off. 在某些系统上,置off,不管使用什么文件系统,能够提高效率,详细情况,请参阅文档 #EnableMMAP off
# # EnableSendfile: Control whether the sendfile kernel support is # used to deliver files (assuming that the OS supports it). # The default is on; turn this off if you serve from NFS-mounted # filesystems. Please see # http://httpd.apache.org/docs-2.0/mod/core....#enablesendfile # EnableSendfile: 控制内核传送文件是否支持(需要OS支持)。默认为on,如果使用NFS,则使用off #EnableSendfile off
# # ErrorLog: The location of the error log file. # If you do not specify an ErrorLog directive within a <VirtualHost> # container, error messages relating to that virtual host will be # logged here. If you *do* define an error logfile for a <VirtualHost> # container, that host's errors will be logged there and not here. #ErrorLog: 出错日志文件 如果你想为虚拟主机定义Errorlog指令,则该虚拟主机的错误信息将被记录到这里 ErrorLog logs/error.log
# # LogLevel: Control the number of messages logged to the error.log. # Possible values include: debug, info, notice, warn, error, crit, # alert, emerg. # LogLever: 日志等级,(与log4j相似,译者注),决定哪些级别的出错信息将被记录,如debug,info,notice,warn,error, crit,alert,emerg等,在设定级别以上的信息就会被记录(译者注). LogLevel warn