由 冷雪 在 07-25-2003 23:54 发表:
有关apache 的问题,高手过来看看。
RH 9.0.93
eth0: 192.168.0.8
dns : www.god.com 192.168.0.8
dns : www.go.com 192.168.0.8
dns : www.cool.com 192.168.0.8
分别建立三个虚拟主机god,go ,cool
以下是httpd.conf 配置文件:
Based upon the NCSA server configuration files originally by Rob McCool.
This is the main Apache server configuration file. It contains the
configuration directives that give the server its instructions.
See
1<url: docs-2.0="" http:="" httpd.apache.org=""> for detailed information about
2
3# the directives.
4
5#
6
7# Do NOT simply read the instructions in here without understanding
8
9# what they do. They're here only as hints or reminders. If you are unsure
10
11# consult the online docs. You have been warned.
12
13#
14
15# The configuration directives are grouped into three basic sections:
16
17# 1. Directives that control the operation of the Apache server process as a
18
19# whole (the 'global environment').
20
21# 2. Directives that define the parameters of the 'main' or 'default' server,
22
23# which responds to requests that aren't handled by a virtual host.
24
25# These directives also provide default values for the settings
26
27# of all virtual hosts.
28
29# 3. Settings for virtual hosts, which allow Web requests to be sent to
30
31# different IP addresses or hostnames and have them handled by the
32
33# same Apache server process.
34
35#
36
37# Configuration and logfile names: If the filenames you specify for many
38
39# of the server's control files begin with "/" (or "drive:/" for Win32), the
40
41# server will use that explicit path. If the filenames do *not* begin
42
43# with "/", the value of ServerRoot is prepended -- so "logs/foo.log"
44
45# with ServerRoot set to "/etc/httpd" will be interpreted by the
46
47# server as "/etc/httpd/logs/foo.log".
48
49#
50
51
52
53### Section 1: Global Environment
54
55#
56
57# The directives in this section affect the overall operation of Apache,
58
59# such as the number of concurrent requests it can handle or where it
60
61# can find its configuration files.
62
63#
64
65
66
67#
68
69# Don't give away too much information about all the subcomponents
70
71# we are running. Comment out this line if you don't mind remote sites
72
73# finding out what major optional modules you are running
74
75ServerTokens OS
76
77
78
79#
80
81# ServerRoot: The top of the directory tree under which the server's
82
83# configuration, error, and log files are kept.
84
85#
86
87# NOTE! If you intend to place this on an NFS (or otherwise network)
88
89# mounted filesystem then please read the LockFile documentation
90
91# (available at <url: core.html#lockfile="" docs-2.0="" http:="" httpd.apache.org="" mod=""> );
92
93# you will save yourself a lot of trouble.
94
95#
96
97# Do NOT add a slash at the end of the directory path.
98
99#
100
101ServerRoot "/etc/httpd"
102
103
104
105#
106
107# ScoreBoardFile: File used to store internal server process information.
108
109# If unspecified (the default), the scoreboard will be stored in an
110
111# anonymous shared memory segment, and will be unavailable to third-party
112
113# applications.
114
115# If specified, ensure that no two invocations of Apache share the same
116
117# scoreboard file. The scoreboard file MUST BE STORED ON A LOCAL DISK.
118
119#
120
121#ScoreBoardFile run/httpd.scoreboard
122
123
124
125#
126
127# PidFile: The file in which the server should record its process
128
129# identification number when it starts.
130
131#
132
133PidFile run/httpd.pid
134
135
136
137#
138
139# Timeout: The number of seconds before receives and sends time out.
140
141#
142
143Timeout 300
144
145
146
147#
148
149# KeepAlive: Whether or not to allow persistent connections (more than
150
151# one request per connection). Set to "Off" to deactivate.
152
153#
154
155KeepAlive Off
156
157
158
159#
160
161# MaxKeepAliveRequests: The maximum number of requests to allow
162
163# during a persistent connection. Set to 0 to allow an unlimited amount.
164
165# We recommend you leave this number high, for maximum performance.
166
167#
168
169MaxKeepAliveRequests 100
170
171
172
173#
174
175# KeepAliveTimeout: Number of seconds to wait for the next request from the
176
177# same client on the same connection.
178
179#
180
181KeepAliveTimeout 15
182
183
184
185##
186
187## Server-Pool Size Regulation (MPM specific)
188
189##
190
191
192
193# prefork MPM
194
195# StartServers: number of server processes to start
196
197# MinSpareServers: minimum number of server processes which are kept spare
198
199# MaxSpareServers: maximum number of server processes which are kept spare
200
201# MaxClients: maximum number of server processes allowed to start
202
203# MaxRequestsPerChild: maximum number of requests a server process serves
204
205<ifmodule prefork.c="">
206
207StartServers 8
208
209MinSpareServers 5
210
211MaxSpareServers 20
212
213MaxClients 150
214
215MaxRequestsPerChild 1000
216
217</ifmodule>
218
219
220
221# worker MPM
222
223# StartServers: initial number of server processes to start
224
225# MaxClients: maximum number of simultaneous client connections
226
227# MinSpareThreads: minimum number of worker threads which are kept spare
228
229# MaxSpareThreads: maximum number of worker threads which are kept spare
230
231# ThreadsPerChild: constant number of worker threads in each server process
232
233# MaxRequestsPerChild: maximum number of requests a server process serves
234
235<ifmodule worker.c="">
236
237StartServers 2
238
239MaxClients 150
240
241MinSpareThreads 25
242
243MaxSpareThreads 75
244
245ThreadsPerChild 25
246
247MaxRequestsPerChild 0
248
249</ifmodule>
250
251
252
253# perchild MPM
254
255# NumServers: constant number of server processes
256
257# StartThreads: initial number of worker threads in each server process
258
259# MinSpareThreads: minimum number of worker threads which are kept spare
260
261# MaxSpareThreads: maximum number of worker threads which are kept spare
262
263# MaxThreadsPerChild: maximum number of worker threads in each server process
264
265# MaxRequestsPerChild: maximum number of connections per server process
266
267<ifmodule perchild.c="">
268
269NumServers 5
270
271StartThreads 5
272
273MinSpareThreads 5
274
275MaxSpareThreads 10
276
277MaxThreadsPerChild 20
278
279MaxRequestsPerChild 0
280
281</ifmodule>
282
283
284
285#
286
287# Listen: Allows you to bind Apache to specific IP addresses and/or
288
289# ports, in addition to the default. See also the <virtualhost>
290
291# directive.
292
293#
294
295# Change this to Listen on specific IP addresses as shown below to
296
297# prevent Apache from glomming onto all bound IP addresses (0.0.0.0)
298
299#
300
301#Listen 12.34.56.78:80
302
303Listen 80
304
305
306
307#
308
309# Dynamic Shared Object (DSO) Support
310
311#
312
313# To be able to use the functionality of a module which was built as a DSO you
314
315# have to place corresponding `LoadModule' lines at this location so the
316
317# directives contained in it are actually available _before_ they are used.
318
319# Statically compiled modules (those listed by `httpd -l') do not need
320
321# to be loaded here.
322
323#
324
325# Example:
326
327# LoadModule foo_module modules/mod_foo.so
328
329#
330
331LoadModule access_module modules/mod_access.so
332
333LoadModule auth_module modules/mod_auth.so
334
335LoadModule auth_anon_module modules/mod_auth_anon.so
336
337LoadModule auth_dbm_module modules/mod_auth_dbm.so
338
339LoadModule auth_digest_module modules/mod_auth_digest.so
340
341LoadModule ldap_module modules/mod_ldap.so
342
343LoadModule auth_ldap_module modules/mod_auth_ldap.so
344
345LoadModule include_module modules/mod_include.so
346
347LoadModule log_config_module modules/mod_log_config.so
348
349LoadModule env_module modules/mod_env.so
350
351LoadModule mime_magic_module modules/mod_mime_magic.so
352
353LoadModule cern_meta_module modules/mod_cern_meta.so
354
355LoadModule expires_module modules/mod_expires.so
356
357LoadModule headers_module modules/mod_headers.so
358
359LoadModule usertrack_module modules/mod_usertrack.so
360
361LoadModule unique_id_module modules/mod_unique_id.so
362
363LoadModule setenvif_module modules/mod_setenvif.so
364
365LoadModule mime_module modules/mod_mime.so
366
367LoadModule dav_module modules/mod_dav.so
368
369LoadModule status_module modules/mod_status.so
370
371LoadModule autoindex_module modules/mod_autoindex.so
372
373LoadModule asis_module modules/mod_asis.so
374
375LoadModule info_module modules/mod_info.so
376
377LoadModule dav_fs_module modules/mod_dav_fs.so
378
379LoadModule vhost_alias_module modules/mod_vhost_alias.so
380
381LoadModule negotiation_module modules/mod_negotiation.so
382
383LoadModule dir_module modules/mod_dir.so
384
385LoadModule imap_module modules/mod_imap.so
386
387LoadModule actions_module modules/mod_actions.so
388
389LoadModule speling_module modules/mod_speling.so
390
391LoadModule userdir_module modules/mod_userdir.so
392
393LoadModule alias_module modules/mod_alias.so
394
395LoadModule rewrite_module modules/mod_rewrite.so
396
397LoadModule proxy_module modules/mod_proxy.so
398
399LoadModule proxy_ftp_module modules/mod_proxy_ftp.so
400
401LoadModule proxy_http_module modules/mod_proxy_http.so
402
403LoadModule proxy_connect_module modules/mod_proxy_connect.so
404
405LoadModule cache_module modules/mod_cache.so
406
407LoadModule disk_cache_module modules/mod_disk_cache.so
408
409LoadModule file_cache_module modules/mod_file_cache.so
410
411LoadModule mem_cache_module modules/mod_mem_cache.so
412
413LoadModule cgi_module modules/mod_cgi.so
414
415
416
417#
418
419# Load config files from the config directory "/etc/httpd/conf.d".
420
421#
422
423Include conf.d/*.conf
424
425
426
427#
428
429# ExtendedStatus controls whether Apache will generate "full" status
430
431# information (ExtendedStatus On) or just basic information (ExtendedStatus
432
433# Off) when the "server-status" handler is called. The default is Off.
434
435#
436
437#ExtendedStatus On
438
439
440
441### Section 2: 'Main' server configuration
442
443#
444
445# The directives in this section set up the values used by the 'main'
446
447# server, which responds to any requests that aren't handled by a
448
449# <virtualhost> definition. These values also provide defaults for
450
451# any <virtualhost> containers you may define later in the file.
452
453#
454
455# All of these directives may appear inside <virtualhost> containers,
456
457# in which case these default settings will be overridden for the
458
459# virtual host being defined.
460
461#
462
463
464
465#
466
467# If you wish httpd to run as a different user or group, you must run
468
469# httpd as root initially and it will switch.
470
471#
472
473# User/Group: The name (or #number) of the user/group to run httpd as.
474
475# . On SCO (ODT 3) use "User nouser" and "Group nogroup".
476
477# . On HPUX you may not be able to use shared memory as nobody, and the
478
479# suggested workaround is to create a user www and use that user.
480
481# NOTE that some kernels refuse to setgid(Group) or semctl(IPC_SET)
482
483# when the value of (unsigned)Group is above 60000;
484
485# don't use Group #-1 on these systems!
486
487#
488
489User nobody
490
491Group nobody
492
493
494
495#
496
497# ServerAdmin: Your address, where problems with the server should be
498
499# e-mailed. This address appears on some server-generated pages, such
500
501# as error documents. e.g. [email protected]
502
503#
504
505ServerAdmin root@localhost
506
507
508
509#
510
511# ServerName gives the name and port that the server uses to identify itself.
512
513# This can often be determined automatically, but we recommend you specify
514
515# it explicitly to prevent problems during startup.
516
517#
518
519# If this is not set to valid DNS name for your host, server-generated
520
521# redirections will not work. See also the UseCanonicalName directive.
522
523#
524
525# If your host doesn't have a registered DNS name, enter its IP address here.
526
527# You will have to access it by its address anyway, and this will make
528
529# redirections work in a sensible way.
530
531#
532
533ServerName www.god.com:80
534
535
536
537#
538
539# UseCanonicalName: Determines how Apache constructs self-referencing
540
541# URLs and the SERVER_NAME and SERVER_PORT variables.
542
543# When set "Off", Apache will use the Hostname and Port supplied
544
545# by the client. When set "On", Apache will use the value of the
546
547# ServerName directive.
548
549#
550
551UseCanonicalName Off
552
553
554
555#
556
557# DocumentRoot: The directory out of which you will serve your
558
559# documents. By default, all requests are taken from this directory, but
560
561# symbolic links and aliases may be used to point to other locations.
562
563#
564
565DocumentRoot "/var/www/html"
566
567
568
569#
570
571# Each directory to which Apache has access can be configured with respect
572
573# to which services and features are allowed and/or disabled in that
574
575# directory (and its subdirectories).
576
577#
578
579# First, we configure the "default" to be a very restrictive set of
580
581# features.
582
583#
584
585<directory></directory>
586
587Options FollowSymLinks
588
589AllowOverride None
590
591
592
593
594
595#
596
597# Note that from this point forward you must specifically allow
598
599# particular features to be enabled - so if something's not working as
600
601# you might expect, make sure that you have specifically enabled it
602
603# below.
604
605#
606
607
608
609#
610
611# This should be changed to whatever you set DocumentRoot to.
612
613#
614
615<directory "="" html"="" var="" www="">
616
617
618
619#
620
621# Possible values for the Options directive are "None", "All",
622
623# or any combination of:
624
625# Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI Multiviews
626
627#
628
629# Note that "MultiViews" must be named *explicitly* --- "Options All"
630
631# doesn't give it to you.
632
633#
634
635# The Options directive is both complicated and important. Please see
636
637# http://httpd.apache.org/docs-2.0/mod/core.html#options
638
639# for more information.
640
641#
642
643Options Indexes FollowSymLinks
644
645
646
647#
648
649# AllowOverride controls what directives may be placed in .htaccess files.
650
651# It can be "All", "None", or any combination of the keywords:
652
653# Options FileInfo AuthConfig Limit
654
655#
656
657AllowOverride None
658
659
660
661#
662
663# Controls who can get stuff from this server.
664
665#
666
667Order allow,deny
668
669Allow from all
670
671
672
673</directory>
674
675
676
677#
678
679# Disable autoindex for the root directory, and present a
680
681# default Welcome page if no other index page is present.
682
683#
684
685<locationmatch "^="" $="">
686
687Options -Indexes
688
689ErrorDocument 403 /error/noindex.html
690
691</locationmatch>
692
693
694
695#
696
697# UserDir: The name of the directory that is appended onto a user's home
698
699# directory if a ~user request is received.
700
701#
702
703# The path to the end user account 'public_html' directory must be
704
705# accessible to the webserver userid. This usually means that ~userid
706
707# must have permissions of 711, ~userid/public_html must have permissions
708
709# of 755, and documents contained therein must be world-readable.
710
711# Otherwise, the client will only receive a "403 Forbidden" message.
712
713#
714
715# See also: http://httpd.apache.org/docs/misc/FAQ.html#forbidden
716
717#
718
719<ifmodule mod_userdir.c="">
720
721#
722
723# UserDir is disabled by default since it can confirm the presence
724
725# of a username on the system (depending on home directory
726
727# permissions).
728
729#
730
731UserDir disable
732
733
734
735#
736
737# To enable requests to /~user/ to serve the user's public_html
738
739# directory, remove the "UserDir disable" line above, and uncomment
740
741# the following line instead:
742
743#
744
745#UserDir public_html
746
747
748
749</ifmodule>
750
751
752
753#
754
755# Control access to UserDir directories. The following is an example
756
757# for a site where these directories are restricted to read-only.
758
759#
760
761#<directory *="" home="" public_html="">
762
763# AllowOverride FileInfo AuthConfig Limit
764
765# Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec
766
767# <limit get="" options="" post="">
768
769# Order allow,deny
770
771# Allow from all
772
773# </limit>
774
775# <limitexcept get="" options="" post="">
776
777# Order deny,allow
778
779# Deny from all
780
781# </limitexcept>
782
783#</directory>
784
785
786
787#
788
789# DirectoryIndex: sets the file that Apache will serve if a directory
790
791# is requested.
792
793#
794
795# The index.html.var file (a type-map) is used to deliver content-
796
797# negotiated documents. The MultiViews Option can be used for the
798
799# same purpose, but it is much slower.
800
801#
802
803DirectoryIndex index.html index.html.var
804
805
806
807#
808
809# AccessFileName: The name of the file to look for in each directory
810
811# for access control information. See also the AllowOverride directive.
812
813#
814
815AccessFileName .htaccess
816
817
818
819#
820
821# The following lines prevent .htaccess and .htpasswd files from being
822
823# viewed by Web clients.
824
825#
826
827<files "^\\.ht"="" ~="">
828
829Order allow,deny
830
831Deny from all
832
833</files>
834
835
836
837#
838
839# TypesConfig describes where the mime.types file (or equivalent) is
840
841# to be found.
842
843#
844
845TypesConfig /etc/mime.types
846
847
848
849#
850
851# DefaultType is the default MIME type the server will use for a document
852
853# if it cannot otherwise determine one, such as from filename extensions.
854
855# If your server contains mostly text or HTML documents, "text/plain" is
856
857# a good value. If most of your content is binary, such as applications
858
859# or images, you may want to use "application/octet-stream" instead to
860
861# keep browsers from trying to display binary files as though they are
862
863# text.
864
865#
866
867DefaultType text/plain
868
869
870
871#
872
873# The mod_mime_magic module allows the server to use various hints from the
874
875# contents of the file itself to determine its type. The MIMEMagicFile
876
877# directive tells the module where the hint definitions are located.
878
879#
880
881<ifmodule mod_mime_magic.c="">
882
883# MIMEMagicFile /usr/share/magic.mime
884
885MIMEMagicFile conf/magic
886
887</ifmodule>
888
889
890
891#
892
893# HostnameLookups: Log the names of clients or just their IP addresses
894
895# e.g., www.apache.org (on) or 204.62.129.132 (off).
896
897# The default is off because it'd be overall better for the net if people
898
899# had to knowingly turn this feature on, since enabling it means that
900
901# each client request will result in AT LEAST one lookup request to the
902
903# nameserver.
904
905#
906
907HostnameLookups Off
908
909
910
911#
912
913# EnableMMAP: Control whether memory-mapping is used to deliver
914
915# files (assuming that the underlying OS supports it).
916
917# The default is on; turn this off if you serve from NFS-mounted
918
919# filesystems. On some systems, turning it off (regardless of
920
921# filesystem) can improve performance; for details, please see
922
923# http://httpd.apache.org/docs-2.0/mo...html#enablemmap
924
925#
926
927#EnableMMAP off
928
929
930
931#
932
933# EnableSendfile: Control whether the sendfile kernel support is
934
935# used to deliver files (assuming that the OS supports it).
936
937# The default is on; turn this off if you serve from NFS-mounted
938
939# filesystems. Please see
940
941# http://httpd.apache.org/docs-2.0/mo...#enablesendfile
942
943#
944
945#EnableSendfile off
946
947#
948
949
950
951#
952
953# ErrorLog: The location of the error log file.
954
955# If you do not specify an ErrorLog directive within a <virtualhost>
956
957# container, error messages relating to that virtual host will be
958
959# logged here. If you *do* define an error logfile for a <virtualhost>
960
961# container, that host's errors will be logged there and not here.
962
963#
964
965ErrorLog logs/error_log
966
967
968
969#
970
971# LogLevel: Control the number of messages logged to the error_log.
972
973# Possible values include: debug, info, notice, warn, error, crit,
974
975# alert, emerg.
976
977#
978
979LogLevel warn
980
981
982
983#
984
985# The following directives define some format nicknames for use with
986
987# a CustomLog directive (see below).
988
989#
990
991LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
992
993LogFormat "%h %l %u %t \"%r\" %>s %b" common
994
995LogFormat "%{Referer}i -> %U" referer
996
997LogFormat "%{User-agent}i" agent
998
999
1000
1001#
1002
1003# The location and format of the access logfile (Common Logfile Format).
1004
1005# If you do not define any access logfiles within a <virtualhost>
1006
1007# container, they will be logged here. Contrariwise, if you *do*
1008
1009# define per-<virtualhost> access logfiles, transactions will be
1010
1011# logged therein and *not* in this file.
1012
1013#
1014
1015# CustomLog logs/access_log common
1016
1017CustomLog logs/access_log combined
1018
1019
1020
1021#
1022
1023# If you would like to have agent and referer logfiles, uncomment the
1024
1025# following directives.
1026
1027#
1028
1029#CustomLog logs/referer_log referer
1030
1031#CustomLog logs/agent_log agent
1032
1033
1034
1035#
1036
1037# If you prefer a single logfile with access, agent, and referer information
1038
1039# (Combined Logfile Format) you can use the following directive.
1040
1041#
1042
1043#CustomLog logs/access_log combined
1044
1045
1046
1047#
1048
1049# Optionally add a line containing the server version and virtual host
1050
1051# name to server-generated pages (error documents, FTP directory listings,
1052
1053# mod_status and mod_info output etc., but not CGI generated documents).
1054
1055# Set to "EMail" to also include a mailto: link to the ServerAdmin.
1056
1057# Set to one of: On | Off | EMail
1058
1059#
1060
1061ServerSignature On
1062
1063
1064
1065#
1066
1067# Aliases: Add here as many aliases as you need (with no limit). The format is
1068
1069# Alias fakename realname
1070
1071#
1072
1073# Note that if you include a trailing / on fakename then the server will
1074
1075# require it to be present in the URL. So "/icons" isn't aliased in this
1076
1077# example, only "/icons/". If the fakename is slash-terminated, then the
1078
1079# realname must also be slash terminated, and if the fakename omits the
1080
1081# trailing slash, the realname must also omit it.
1082
1083#
1084
1085# We include the /icons/ alias for FancyIndexed directory listings. If you
1086
1087# do not use FancyIndexing, you may comment this out.
1088
1089#
1090
1091Alias /icons/ "/var/www/icons/"
1092
1093
1094
1095<directory "="" icons"="" var="" www="">
1096
1097Options Indexes MultiViews
1098
1099AllowOverride None
1100
1101Order allow,deny
1102
1103Allow from all
1104
1105</directory>
1106
1107
1108
1109#
1110
1111# This should be changed to the ServerRoot/manual/. The alias provides
1112
1113# the manual, even if you choose to move your DocumentRoot. You may comment
1114
1115# this out if you do not care for the documentation.
1116
1117#
1118
1119Alias /manual "/var/www/manual"
1120
1121
1122
1123<directory "="" manual"="" var="" www="">
1124
1125Options Indexes FollowSymLinks MultiViews
1126
1127AllowOverride None
1128
1129Order allow,deny
1130
1131Allow from all
1132
1133</directory>
1134<ifmodule mod_dav_fs.c="">
1135
1136# Location of the WebDAV lock database.
1137
1138DAVLockDB /var/lib/dav/lockdb
1139
1140</ifmodule>
1141
1142
1143
1144#
1145
1146# ScriptAlias: This controls which directories contain server scripts.
1147
1148# ScriptAliases are essentially the same as Aliases, except that
1149
1150# documents in the realname directory are treated as applications and
1151
1152# run by the server when requested rather than as documents sent to the client.
1153
1154# The same rules about trailing "/" apply to ScriptAlias directives as to
1155
1156# Alias.
1157
1158#
1159
1160ScriptAlias /cgi-bin/ "/var/www/cgi-bin/"
1161
1162
1163
1164<ifmodule mod_cgid.c="">
1165
1166#
1167
1168# Additional to mod_cgid.c settings, mod_cgid has Scriptsock <path>
1169
1170# for setting UNIX socket for communicating with cgid.
1171
1172#
1173
1174Scriptsock run/httpd.cgid
1175
1176</path></ifmodule>
1177
1178
1179
1180#
1181
1182# "/var/www/cgi-bin" should be changed to whatever your ScriptAliased
1183
1184# CGI directory exists, if you have that configured.
1185
1186#
1187
1188<directory "="" cgi-bin"="" var="" www="">
1189
1190AllowOverride None
1191
1192Options None
1193
1194Order allow,deny
1195
1196Allow from all
1197
1198</directory>
1199
1200
1201
1202#
1203
1204# Redirect allows you to tell clients about documents which used to exist in
1205
1206# your server's namespace, but do not anymore. This allows you to tell the
1207
1208# clients where to look for the relocated document.
1209
1210# Example:
1211
1212# Redirect permanent /foo http://www.andsky.com/bar
1213
1214
1215
1216#
1217
1218# Directives controlling the display of server-generated directory listings.
1219
1220#
1221
1222
1223
1224#
1225
1226# FancyIndexing is whether you want fancy directory indexing or standard.
1227
1228# VersionSort is whether files containing version numbers should be
1229
1230# compared in the natural way, so that `apache-1.3.9.tar' is placed before
1231
1232# `apache-1.3.12.tar'.
1233
1234#
1235
1236IndexOptions FancyIndexing VersionSort NameWidth=*
1237
1238
1239
1240#
1241
1242# AddIcon* directives tell the server which icon to show for different
1243
1244# files or filename extensions. These are only displayed for
1245
1246# FancyIndexed directories.
1247
1248#
1249
1250AddIconByEncoding (CMP,/icons/compressed.gif) x-compress x-gzip
1251
1252
1253
1254AddIconByType (TXT,/icons/text.gif) text/*
1255
1256AddIconByType (IMG,/icons/image2.gif) image/*
1257
1258AddIconByType (SND,/icons/sound2.gif) audio/*
1259
1260AddIconByType (VID,/icons/movie.gif) video/*
1261
1262
1263
1264AddIcon /icons/binary.gif .bin .exe
1265
1266AddIcon /icons/binhex.gif .hqx
1267
1268AddIcon /icons/tar.gif .tar
1269
1270AddIcon /icons/world2.gif .wrl .wrl.gz .vrml .vrm .iv
1271
1272AddIcon /icons/compressed.gif .Z .z .tgz .gz .zip
1273
1274AddIcon /icons/a.gif .ps .ai .eps
1275
1276AddIcon /icons/layout.gif .html .shtml .htm .pdf
1277
1278AddIcon /icons/text.gif .txt
1279
1280AddIcon /icons/c.gif .c
1281
1282AddIcon /icons/p.gif .pl .py
1283
1284AddIcon /icons/f.gif .for
1285
1286AddIcon /icons/dvi.gif .dvi
1287
1288AddIcon /icons/uuencoded.gif .uu
1289
1290AddIcon /icons/script.gif .conf .sh .shar .csh .ksh .tcl
1291
1292AddIcon /icons/tex.gif .tex
1293
1294AddIcon /icons/bomb.gif core
1295
1296
1297
1298AddIcon /icons/back.gif ..
1299
1300AddIcon /icons/hand.right.gif README
1301
1302AddIcon /icons/folder.gif ^^DIRECTORY^^
1303
1304AddIcon /icons/blank.gif ^^BLANKICON^^
1305
1306
1307
1308#
1309
1310# DefaultIcon is which icon to show for files which do not have an icon
1311
1312# explicitly set.
1313
1314#
1315
1316DefaultIcon /icons/unknown.gif
1317
1318
1319
1320#
1321
1322# AddDescription allows you to place a short description after a file in
1323
1324# server-generated indexes. These are only displayed for FancyIndexed
1325
1326# directories.
1327
1328# Format: AddDescription "description" filename
1329
1330#
1331
1332#AddDescription "GZIP compressed document" .gz
1333
1334#AddDescription "tar archive" .tar
1335
1336#AddDescription "GZIP compressed tar archive" .tgz
1337
1338
1339
1340#
1341
1342# ReadmeName is the name of the README file the server will look for by
1343
1344# default, and append to directory listings.
1345
1346#
1347
1348# HeaderName is the name of a file which should be prepended to
1349
1350# directory indexes.
1351
1352ReadmeName README.html
1353
1354HeaderName HEADER.html
1355
1356
1357
1358#
1359
1360# IndexIgnore is a set of filenames which directory indexing should ignore
1361
1362# and not include in the listing. Shell-style wildcarding is permitted.
1363
1364#
1365
1366IndexIgnore .??* *~ *# HEADER* README* RCS CVS *,v *,t
1367
1368
1369
1370#
1371
1372# AddEncoding allows you to have certain browsers (Mosaic/X 2.1+) uncompress
1373
1374# information on the fly. Note: Not all browsers support this.
1375
1376# Despite the name similarity, the following Add* directives have nothing
1377
1378# to do with the FancyIndexing customization directives above.
1379
1380#
1381
1382AddEncoding x-compress Z
1383
1384AddEncoding x-gzip gz tgz
1385
1386
1387
1388#
1389
1390# DefaultLanguage and AddLanguage allows you to specify the language of
1391
1392# a document. You can then use content negotiation to give a browser a
1393
1394# file in a language the user can understand.
1395
1396#
1397
1398# Specify a default language. This means that all data
1399
1400# going out without a specific language tag (see below) will
1401
1402# be marked with this one. You probably do NOT want to set
1403
1404# this unless you are sure it is correct for all cases.
1405
1406#
1407
1408# * It is generally better to not mark a page as
1409
1410# * being a certain language than marking it with the wrong
1411
1412# * language!
1413
1414#
1415
1416# DefaultLanguage nl
1417
1418#
1419
1420# Note 1: The suffix does not have to be the same as the language
1421
1422# keyword --- those with documents in Polish (whose net-standard
1423
1424# language code is pl) may wish to use "AddLanguage pl .po" to
1425
1426# avoid the ambiguity with the common suffix for perl scripts.
1427
1428#
1429
1430# Note 2: The example entries below illustrate that in some cases
1431
1432# the two character 'Language' abbreviation is not identical to
1433
1434# the two character 'Country' code for its country,
1435
1436# E.g. 'Danmark/dk' versus 'Danish/da'.
1437
1438#
1439
1440# Note 3: In the case of 'ltz' we violate the RFC by using a three char
1441
1442# specifier. There is 'work in progress' to fix this and get
1443
1444# the reference data for rfc1766 cleaned up.
1445
1446#
1447
1448# Danish (da) - Dutch (nl) - English (en) - Estonian (et)
1449
1450# French (fr) - German (de) - Greek-Modern (el)
1451
1452# Italian (it) - Norwegian (no) - Norwegian Nynorsk (nn) - Korean (ko)
1453
1454# Portugese (pt) - Luxembourgeois* (ltz)
1455
1456# Spanish (es) - Swedish (sv) - Catalan (ca) - Czech(cz)
1457
1458# Polish (pl) - Brazilian Portuguese (pt-br) - Japanese (ja)
1459
1460# Russian (ru) - Croatian (hr)
1461
1462#
1463
1464AddLanguage da .dk
1465
1466AddLanguage nl .nl
1467
1468AddLanguage en .en
1469
1470AddLanguage et .et
1471
1472AddLanguage fr .fr
1473
1474AddLanguage de .de
1475
1476AddLanguage he .he
1477
1478AddLanguage el .el
1479
1480AddLanguage it .it
1481
1482AddLanguage ja .ja
1483
1484AddLanguage pl .po
1485
1486AddLanguage ko .ko
1487
1488AddLanguage pt .pt
1489
1490AddLanguage nn .nn
1491
1492AddLanguage no .no
1493
1494AddLanguage pt-br .pt-br
1495
1496AddLanguage ltz .ltz
1497
1498AddLanguage ca .ca
1499
1500AddLanguage es .es
1501
1502AddLanguage sv .sv
1503
1504AddLanguage cz .cz
1505
1506AddLanguage ru .ru
1507
1508AddLanguage tw .tw
1509
1510AddLanguage zh-tw .tw
1511
1512AddLanguage hr .hr
1513
1514
1515
1516#
1517
1518# LanguagePriority allows you to give precedence to some languages
1519
1520# in case of a tie during content negotiation.
1521
1522#
1523
1524# Just list the languages in decreasing order of preference. We have
1525
1526# more or less alphabetized them here. You probably want to change this.
1527
1528#
1529
1530LanguagePriority en da nl et fr de el it ja ko no pl pt pt-br ltz ca es sv tw
1531
1532
1533
1534#
1535
1536# ForceLanguagePriority allows you to serve a result page rather than
1537
1538# MULTIPLE CHOICES (Prefer) [in case of a tie] or NOT ACCEPTABLE (Fallback)
1539
1540# [in case no accepted languages matched the available variants]
1541
1542#
1543
1544ForceLanguagePriority Prefer Fallback
1545
1546
1547
1548#
1549
1550# Specify a default charset for all pages sent out. This is
1551
1552# always a good idea and opens the door for future internationalisation
1553
1554# of your web site, should you ever want it. Specifying it as
1555
1556# a default does little harm; as the standard dictates that a page
1557
1558# is in iso-8859-1 (latin1) unless specified otherwise i.e. you
1559
1560# are merely stating the obvious. There are also some security
1561
1562# reasons in browsers, related to javascript and URL parsing
1563
1564# which encourage you to always set a default char set.
1565
1566#
1567
1568AddDefaultCharset UTF-8
1569
1570
1571
1572#
1573
1574# Commonly used filename extensions to character sets. You probably
1575
1576# want to avoid clashes with the language extensions, unless you
1577
1578# are good at carefully testing your setup after each change.
1579
1580# See http://www.iana.org/assignments/character-sets for the
1581
1582# official list of charset names and their respective RFCs
1583
1584#
1585
1586AddCharset ISO-8859-1 .iso8859-1 .latin1
1587
1588AddCharset ISO-8859-2 .iso8859-2 .latin2 .cen
1589
1590AddCharset ISO-8859-3 .iso8859-3 .latin3
1591
1592AddCharset ISO-8859-4 .iso8859-4 .latin4
1593
1594AddCharset ISO-8859-5 .iso8859-5 .latin5 .cyr .iso-ru
1595
1596AddCharset ISO-8859-6 .iso8859-6 .latin6 .arb
1597
1598AddCharset ISO-8859-7 .iso8859-7 .latin7 .grk
1599
1600AddCharset ISO-8859-8 .iso8859-8 .latin8 .heb
1601
1602AddCharset ISO-8859-9 .iso8859-9 .latin9 .trk
1603
1604AddCharset ISO-2022-JP .iso2022-jp .jis
1605
1606AddCharset ISO-2022-KR .iso2022-kr .kis
1607
1608AddCharset ISO-2022-CN .iso2022-cn .cis
1609
1610AddCharset Big5 .Big5 .big5
1611
1612# For russian, more than one charset is used (depends on client, mostly):
1613
1614AddCharset WINDOWS-1251 .cp-1251 .win-1251
1615
1616AddCharset CP866 .cp866
1617
1618AddCharset KOI8-r .koi8-r .koi8-ru
1619
1620AddCharset KOI8-ru .koi8-uk .ua
1621
1622AddCharset ISO-10646-UCS-2 .ucs2
1623
1624AddCharset ISO-10646-UCS-4 .ucs4
1625
1626AddCharset UTF-8 .utf8
1627
1628
1629
1630# The set below does not map to a specific (iso) standard
1631
1632# but work</virtualhost></virtualhost></virtualhost></virtualhost></virtualhost></virtualhost></virtualhost></virtualhost></url:></url:>