//设置apache手册的访问别名
Alias /manual “/var/www/manual”
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
Allow from all
//设置浏览器匹配
BrowserMatch “Mozilla/2″ nokeepalive
BrowserMatch “MSIE 4.0b2;” nokeepalive downgrade-1.0 force-response-1.0
BrowserMatch “RealPlayer 4.0″ force-response-1.0
BrowserMatch “/1.0″ force-response-1.0
BrowserMatch “JDK/1.0″ force-response-1.0
BrowserMatch “Microsoft Data Access Internet Publishing Provider” redirect-carefully
BrowserMatch “^WebDrive” redirect-carefully
#
# Allow server status reports, with the URL of …
# Change the “.your-domain.com” to match your domain to enable.
#
#
# SetHandler server-status
# Order deny,allow
# Deny from all
# Allow from .your-domain.com
# #
# Allow remote server configuration reports, with the URL of
# … (requires that mod_info.c be loaded).
# Change the “.your-domain.com” to match your domain to enable.
#
#
# SetHandler server-info
# Order deny,allow
# Deny from all
# Allow from .your-domain.com
# //设置APache为代理服务器
# Proxy Server directives. Uncomment the following lines to
# enable the proxy server:
#
#
#ProxyRequests On
#
#
# Order deny,allow
# Deny from all
# Allow from .your-domain.com
#
#
# Enable/disable the handling of HTTP/1.1 “Via:” headers.
# (“Full” adds the server version; “Block” removes all outgoing Via: headers)
# Set to one of: Off | On | Full | Block
#
#ProxyVia On
#
# To enable the cache as well, edit and uncomment the following lines:
# (no cacheing without CacheRoot)
#
#CacheRoot “/etc/httpd/proxy”
#CacheSize 5
#CacheGcInterval 4
#CacheMaxExpire 24
#CacheLastModifiedFactor 0.1
#CacheDefaultExpire 1
#NoCache a-domain.com another-domain.edu joes.garage-sale.com
# # End of proxy directives.
//设置虚拟主机
### Section 3: Virtual Hosts
#
# VirtualHost: If you want to maintain multiple domains/hostnames on your
# machine you can setup VirtualHost containers for them. Most configurations
# use only name-based virtual hosts so the server doesn’t need to worry about
# IP addresses. This is indicated by the asterisks in the directives below.
#
# Please see the documentation at
# <…
# for further details before you try to setup virtual hosts.
#
# You may use the command line option ‘-S’ to verify your virtual host
# configuration.
#
# Use name-based virtual hosting.
//指令监听本地计算机上所有的IP地址请求
#NameVirtualHost *
#
# VirtualHost example:
# Almost any Apache directive may go into a VirtualHost container.
# The first VirtualHost section is used for requests without a known
# server name.
#
#
//定义虚拟主机的设置,此设置将覆盖前面有的的相同指令
# ServerAdmin webmaster at dummy-host dot example.com
# DocumentRoot /www/docs/dummy-host.example.com
# ServerName dummy-host.example.com
# ErrorLog logs/dummy-host.example.com-error_log
# CustomLog logs/dummy-host.example.com-access_log common
# //指定DAV加锁数据库文件的存放位置
# Location of the WebDAV lock database.
DAVLockDB /var/lib/dav/lockdb
Alias /docs “/home/EMU/webmail/docs/”
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
Allow from all
# Location of the WebDAV lock database.
DAVLockDB /var/lib/dav/lockdb
//设置CGI目录的访问别名
ScriptAlias /cgi-bin/ “/var/www/cgi-bin/”
//由于red hat中不使用worker MPM运行方式,所以不加载mod_cgid.c模块
#
# Additional to mod_cgid.c settings, mod_cgid has Scriptsock
# for setting UNIX socket for communicating with cgid.
#
#Scriptsock logs/cgisock
//设置CGI目录的访问权限
AllowOverride None
Options None
Order allow,deny
Allow from all
//重定向连接
# Redirect permanent /foo
//设置自动生成目录列表的显示方式
//FancyIndexing 对每种类型的文件前加上一个小图标以示区别
//VersionSort 对同一个软件的多个版本进行排序
//NameWidth=* 文件名字段自动适应当前目录下的最长文件名
IndexOptions FancyIndexing VersionSort NameWidth=*
//当使用IndexOptions FancyIndexing之后,配置下面的参数
//用于告知服务器在遇到不同的文件类型或扩展名时采用MIME编码格式
//辨别文件类型并显示相应的图标
AddIconByEncoding (CMP,/icons/compressed.gif) x-compress x-gzip
AddIconByType (TXT,/icons/text.gif) text/*
AddIconByType (IMG,/icons/image2.gif) image/*
AddIconByType (SND,/icons/sound2.gif) audio/*
AddIconByType (VID,/icons/movie.gif) video/*
//当使用IndexOptions FancyIndexing之后,配置下面的参数
//用于告知服务器在遇到不同的文件类型或扩展名时采用所指定的格式
//并显示相应的图标
AddIcon /icons/binary.gif .bin .exe
AddIcon /icons/binhex.gif .hqx
AddIcon /icons/tar.gif .tar
AddIcon /icons/world2.gif .wrl .wrl.gz .vrml .vrm .iv
AddIcon /icons/compressed.gif .Z .z .tgz .gz .zip
AddIcon /icons/a.gif .ps .ai .eps
AddIcon /icons/layout.gif .html .shtml .htm .pdf
AddIcon /icons/text.gif .txt
AddIcon /icons/c.gif .c
AddIcon /icons/p.gif .pl .py
AddIcon /icons/f.gif .for
AddIcon /icons/dvi.gif .dvi
AddIcon /icons/uuencoded.gif .uu
AddIcon /icons/script.gif .conf .sh .shar .csh .ksh .tcl
AddIcon /icons/tex.gif .tex
AddIcon /icons/bomb.gif core
AddIcon /icons/back.gif ..
AddIcon /icons/hand.right.gif README
AddIcon /icons/folder.gif ^^DIRECTORY^^
AddIcon /icons/blank.gif ^^BLANKICON^^
//当使用IndexOptions FancyIndexing之后,且无法识别文件类型时
//显示此处定义的图标
DefaultIcon /icons/unknown.gif