Discuz!官方免费开源建站系统

 找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索

请教Apache配置泛域名站点问题

[复制链接]
cookiedog 发表于 2008-8-24 12:47:25 | 显示全部楼层 |阅读模式
我服务器内一共有两个主要站点,四个域名。

gznf.net指向/home/www/gznf.net/目录,安装了一套Supersite、UCenter、Discuz
gznf.cn指向/home/www/gznf.net/home/目录,安装了一套Uchome,即访问在浏览器gznf.net/home也能访问,并且和gznf.net使用同一个UCenter通行证。

myluckdog.com指向/home/www/dog.gznf.net/目录,安装了一套Supersite、UCenter、Discuz
myluckdog.net指向/home/www/dog.gznf.net/home/目录,安装了一套Uchome,即访问在浏览器myluckdog.com/home也能访问,并且和myluckdog.com使用同一个UCenter通行证。

现在访问gznf.net和myluckdog.com都很正常,二级域名也没有问题,但奇怪的却是gznf.cn和myluckdog.net的指向不正确,gznf.cn指向了/home/www/gznf.net/而不是/home/www/gznf.net/home/,myluckdog.net指向/home/www/dog.gznf.net/而不/home/www/dog.gznf.net/home/。

我现在将httpd.conf传上来,希望高手能够指教。
  1. #
  2. # Based upon the NCSA server configuration files originally by Rob McCool.
  3. #
  4. # This is the main Apache server configuration file.  It contains the
  5. # configuration directives that give the server its instructions.
  6. # See <URL:http://httpd.apache.org/docs-2.0/> for detailed information about
  7. # the directives.
  8. #
  9. # Do NOT simply read the instructions in here without understanding
  10. # what they do.  They're here only as hints or reminders.  If you are unsure
  11. # consult the online docs. You have been warned.  
  12. #
  13. # The configuration directives are grouped into three basic sections:
  14. #  1. Directives that control the operation of the Apache server process as a
  15. #     whole (the 'global environment').
  16. #  2. Directives that define the parameters of the 'main' or 'default' server,
  17. #     which responds to requests that aren't handled by a virtual host.
  18. #     These directives also provide default values for the settings
  19. #     of all virtual hosts.
  20. #  3. Settings for virtual hosts, which allow Web requests to be sent to
  21. #     different IP addresses or hostnames and have them handled by the
  22. #     same Apache server process.
  23. #
  24. # Configuration and logfile names: If the filenames you specify for many
  25. # of the server's control files begin with "/" (or "drive:/" for Win32), the
  26. # server will use that explicit path.  If the filenames do *not* begin
  27. # with "/", the value of ServerRoot is prepended -- so "logs/foo.log"
  28. # with ServerRoot set to "/home/app/apache" will be interpreted by the
  29. # server as "/home/app/apache/logs/foo.log".
  30. #

  31. ### Section 1: Global Environment
  32. #
  33. # The directives in this section affect the overall operation of Apache,
  34. # such as the number of concurrent requests it can handle or where it
  35. # can find its configuration files.
  36. #

  37. #
  38. # ServerRoot: The top of the directory tree under which the server's
  39. # configuration, error, and log files are kept.
  40. #
  41. # NOTE!  If you intend to place this on an NFS (or otherwise network)
  42. # mounted filesystem then please read the LockFile documentation (available
  43. # at <URL:http://httpd.apache.org/docs-2.0/mod/mpm_common.html#lockfile>);
  44. # you will save yourself a lot of trouble.
  45. #
  46. # Do NOT add a slash at the end of the directory path.
  47. #
  48. ServerRoot "/usr/local/apache"

  49. #
  50. # The accept serialization lock file MUST BE STORED ON A LOCAL DISK.
  51. #
  52. <IfModule !mpm_winnt.c>
  53. <IfModule !mpm_netware.c>
  54. #LockFile logs/accept.lock
  55. </IfModule>
  56. </IfModule>

  57. #
  58. # ScoreBoardFile: File used to store internal server process information.
  59. # If unspecified (the default), the scoreboard will be stored in an
  60. # anonymous shared memory segment, and will be unavailable to third-party
  61. # applications.
  62. # If specified, ensure that no two invocations of Apache share the same
  63. # scoreboard file. The scoreboard file MUST BE STORED ON A LOCAL DISK.
  64. #
  65. <IfModule !mpm_netware.c>
  66. <IfModule !perchild.c>
  67. #ScoreBoardFile logs/apache_runtime_status
  68. </IfModule>
  69. </IfModule>


  70. #
  71. # PidFile: The file in which the server should record its process
  72. # identification number when it starts.
  73. #
  74. <IfModule !mpm_netware.c>
  75. PidFile logs/httpd.pid
  76. </IfModule>

  77. #
  78. # Timeout: The number of seconds before receives and sends time out.
  79. #
  80. Timeout 30

  81. #
  82. # KeepAlive: Whether or not to allow persistent connections (more than
  83. # one request per connection). Set to "Off" to deactivate.
  84. #
  85. KeepAlive On

  86. #
  87. # MaxKeepAliveRequests: The maximum number of requests to allow
  88. # during a persistent connection. Set to 0 to allow an unlimited amount.
  89. # We recommend you leave this number high, for maximum performance.
  90. #
  91. MaxKeepAliveRequests 100

  92. #
  93. # KeepAliveTimeout: Number of seconds to wait for the next request from the
  94. # same client on the same connection.
  95. #
  96. KeepAliveTimeout 15

  97. ##
  98. ## Server-Pool Size Regulation (MPM specific)
  99. ##

  100. # prefork MPM
  101. # StartServers: number of server processes to start
  102. # MinSpareServers: minimum number of server processes which are kept spare
  103. # MaxSpareServers: maximum number of server processes which are kept spare
  104. # MaxClients: maximum number of server processes allowed to start
  105. # MaxRequestsPerChild: maximum number of requests a server process serves
  106. <IfModule prefork.c>
  107. #ServerLimit 25
  108. StartServers         5
  109. MinSpareServers      5
  110. MaxSpareServers     10
  111. MaxClients         256
  112. MaxRequestsPerChild  0
  113. </IfModule>

  114. # worker MPM
  115. # StartServers: initial number of server processes to start
  116. # MaxClients: maximum number of simultaneous client connections
  117. # MinSpareThreads: minimum number of worker threads which are kept spare
  118. # MaxSpareThreads: maximum number of worker threads which are kept spare
  119. # ThreadsPerChild: constant number of worker threads in each server process
  120. # MaxRequestsPerChild: maximum number of requests a server process serves
  121. <IfModule worker.c>
  122. StartServers         2
  123. MaxClients         256
  124. MinSpareThreads     25
  125. MaxSpareThreads     75
  126. ThreadsPerChild     25
  127. MaxRequestsPerChild  0
  128. </IfModule>

  129. # perchild MPM
  130. # NumServers: constant number of server processes
  131. # StartThreads: initial number of worker threads in each server process
  132. # MinSpareThreads: minimum number of worker threads which are kept spare
  133. # MaxSpareThreads: maximum number of worker threads which are kept spare
  134. # MaxThreadsPerChild: maximum number of worker threads in each server process
  135. # MaxRequestsPerChild: maximum number of connections per server process
  136. <IfModule perchild.c>
  137. NumServers           5
  138. StartThreads         5
  139. MinSpareThreads      5
  140. MaxSpareThreads     10
  141. MaxThreadsPerChild  20
  142. MaxRequestsPerChild  0
  143. </IfModule>

  144. # WinNT MPM
  145. # ThreadsPerChild: constant number of worker threads in the server process
  146. # MaxRequestsPerChild: maximum  number of requests a server process serves
  147. <IfModule mpm_winnt.c>
  148. ThreadsPerChild 250
  149. MaxRequestsPerChild  0
  150. </IfModule>

  151. # BeOS MPM
  152. # StartThreads: how many threads do we initially spawn?
  153. # MaxClients:   max number of threads we can have (1 thread == 1 client)
  154. # MaxRequestsPerThread: maximum number of requests each thread will process
  155. <IfModule beos.c>
  156. StartThreads               10
  157. MaxClients                 256
  158. MaxRequestsPerThread       10000
  159. </IfModule>   

  160. # NetWare MPM
  161. # ThreadStackSize: Stack size allocated for each worker thread
  162. # StartThreads: Number of worker threads launched at server startup
  163. # MinSpareThreads: Minimum number of idle threads, to handle request spikes
  164. # MaxSpareThreads: Maximum number of idle threads
  165. # MaxThreads: Maximum number of worker threads alive at the same time
  166. # MaxRequestsPerChild: Maximum  number of requests a thread serves. It is
  167. #                      recommended that the default value of 0 be set for this
  168. #                      directive on NetWare.  This will allow the thread to
  169. #                      continue to service requests indefinitely.                          
  170. <IfModule mpm_netware.c>
  171. ThreadStackSize      65536
  172. StartThreads           250
  173. MinSpareThreads         25
  174. MaxSpareThreads        250
  175. MaxThreads            1000
  176. MaxRequestsPerChild      0
  177. MaxMemFree             100
  178. </IfModule>

  179. # OS/2 MPM
  180. # StartServers: Number of server processes to maintain
  181. # MinSpareThreads: Minimum number of idle threads per process,
  182. #                  to handle request spikes
  183. # MaxSpareThreads: Maximum number of idle threads per process
  184. # MaxRequestsPerChild: Maximum number of connections per server process
  185. <IfModule mpmt_os2.c>
  186. StartServers           2
  187. MinSpareThreads        5
  188. MaxSpareThreads       10
  189. MaxRequestsPerChild    0
  190. </IfModule>

  191. #
  192. # Listen: Allows you to bind Apache to specific IP addresses and/or
  193. # ports, instead of the default. See also the <VirtualHost>
  194. # directive.
  195. #
  196. # Change this to Listen on specific IP addresses as shown below to
  197. # prevent Apache from glomming onto all bound IP addresses (0.0.0.0)
  198. #
  199. #Listen 12.34.56.78:80

  200. Listen 80

  201. #
  202. # Dynamic Shared Object (DSO) Support
  203. #
  204. # To be able to use the functionality of a module which was built as a DSO you
  205. # have to place corresponding `LoadModule' lines at this location so the
  206. # directives contained in it are actually available _before_ they are used.
  207. # Statically compiled modules (those listed by `httpd -l') do not need
  208. # to be loaded here.
  209. #
  210. # Example:
  211. # LoadModule foo_module modules/mod_foo.so
  212. #
  213. LoadModule php4_module        modules/libphp4.so


  214. #
  215. # ExtendedStatus controls whether Apache will generate "full" status
  216. # information (ExtendedStatus On) or just basic information (ExtendedStatus
  217. # Off) when the "server-status" handler is called. The default is Off.
  218. #
  219. #ExtendedStatus On

  220. ### Section 2: 'Main' server configuration
  221. #
  222. # The directives in this section set up the values used by the 'main'
  223. # server, which responds to any requests that aren't handled by a
  224. # <VirtualHost> definition.  These values also provide defaults for
  225. # any <VirtualHost> containers you may define later in the file.
  226. #
  227. # All of these directives may appear inside <VirtualHost> containers,
  228. # in which case these default settings will be overridden for the
  229. # virtual host being defined.
  230. #

  231. <IfModule !mpm_winnt.c>
  232. <IfModule !mpm_netware.c>
  233. #
  234. # If you wish httpd to run as a different user or group, you must run
  235. # httpd as root initially and it will switch.  
  236. #
  237. # User/Group: The name (or #number) of the user/group to run httpd as.
  238. #  . On SCO (ODT 3) use "User nouser" and "Group nogroup".
  239. #  . On HPUX you may not be able to use shared memory as nobody, and the
  240. #    suggested workaround is to create a user www and use that user.
  241. #  NOTE that some kernels refuse to setgid(Group) or semctl(IPC_SET)
  242. #  when the value of (unsigned)Group is above 60000;
  243. #  don't use Group #-1 on these systems!
  244. #
  245. User lazyboy
  246. Group root
  247. </IfModule>
  248. </IfModule>

  249. #
  250. # ServerAdmin: Your address, where problems with the server should be
  251. # e-mailed.  This address appears on some server-generated pages, such
  252. # as error documents.  e.g. admin@your-domain.com
  253. #
  254. ServerAdmin sysop@gznf.net

  255. #
  256. # ServerName gives the name and port that the server uses to identify itself.
  257. # This can often be determined automatically, but we recommend you specify
  258. # it explicitly to prevent problems during startup.
  259. #
  260. # If this is not set to valid DNS name for your host, server-generated
  261. # redirections will not work.  See also the UseCanonicalName directive.
  262. #
  263. # If your host doesn't have a registered DNS name, enter its IP address here.
  264. # You will have to access it by its address anyway, and this will make
  265. # redirections work in a sensible way.
  266. #
  267. #ServerName www.example.com:80

  268. #
  269. # UseCanonicalName: Determines how Apache constructs self-referencing
  270. # URLs and the SERVER_NAME and SERVER_PORT variables.
  271. # When set "Off", Apache will use the Hostname and Port supplied
  272. # by the client.  When set "On", Apache will use the value of the
  273. # ServerName directive.
  274. #
  275. UseCanonicalName Off

  276. #
  277. # DocumentRoot: The directory out of which you will serve your
  278. # documents. By default, all requests are taken from this directory, but
  279. # symbolic links and aliases may be used to point to other locations.
  280. #
  281. #DocumentRoot "/home/app/apache/htdocs"

  282. #
  283. # Each directory to which Apache has access can be configured with respect
  284. # to which services and features are allowed and/or disabled in that
  285. # directory (and its subdirectories).
  286. #
  287. # First, we configure the "default" to be a very restrictive set of
  288. # features.  
  289. #
  290. <Directory />
  291.     Options FollowSymLinks
  292.     AllowOverride None
  293. </Directory>

  294. #
  295. # Note that from this point forward you must specifically allow
  296. # particular features to be enabled - so if something's not working as
  297. # you might expect, make sure that you have specifically enabled it
  298. # below.
  299. #

  300. #
  301. # This should be changed to whatever you set DocumentRoot to.
  302. #
  303. #<Directory "/home/app/apache/htdocs">

  304. #
  305. # Possible values for the Options directive are "None", "All",
  306. # or any combination of:
  307. #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
  308. #
  309. # Note that "MultiViews" must be named *explicitly* --- "Options All"
  310. # doesn't give it to you.
  311. #
  312. # The Options directive is both complicated and important.  Please see
  313. # http://httpd.apache.org/docs-2.0/mod/core.html#options
  314. # for more information.
  315. #
  316. #    Options Indexes FollowSymLinks

  317. #
  318. # AllowOverride controls what directives may be placed in .htaccess files.
  319. # It can be "All", "None", or any combination of the keywords:
  320. #   Options FileInfo AuthConfig Limit Indexes
  321. #
  322. #    AllowOverride None

  323. #
  324. # Controls who can get stuff from this server.
  325. #
  326. #    Order allow,deny
  327. #    Allow from all

  328. #</Directory>

  329. #
  330. # UserDir: The name of the directory that is appended onto a user's home
  331. # directory if a ~user request is received.
  332. #
  333. #UserDir public_html

  334. #
  335. # Control access to UserDir directories.  The following is an example
  336. # for a site where these directories are restricted to read-only.
  337. #
  338. #<Directory /home/*/public_html>
  339. #    AllowOverride FileInfo AuthConfig Limit Indexes
  340. #    Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec
  341. #    <Limit GET POST OPTIONS PROPFIND>
  342. #        Order allow,deny
  343. #        Allow from all
  344. #    </Limit>
  345. #    <LimitExcept GET POST OPTIONS PROPFIND>
  346. #        Order deny,allow
  347. #        Deny from all
  348. #    </LimitExcept>
  349. #</Directory>

  350. #
  351. # DirectoryIndex: sets the file that Apache will serve if a directory
  352. # is requested.
  353. #
  354. # The index.html.var file (a type-map) is used to deliver content-
  355. # negotiated documents.  The MultiViews Option can be used for the
  356. # same purpose, but it is much slower.
  357. #
  358. DirectoryIndex index.html index.html.var

  359. #
  360. # AccessFileName: The name of the file to look for in each directory
  361. # for additional configuration directives.  See also the AllowOverride
  362. # directive.
  363. #
  364. AccessFileName .htaccess

  365. #
  366. # The following lines prevent .htaccess and .htpasswd files from being
  367. # viewed by Web clients.
  368. #
  369. <FilesMatch "(^\.ht|^config)">
  370.     Order allow,deny
  371.     Deny from all
  372. </FilesMatch>

  373. #
  374. # TypesConfig describes where the mime.types file (or equivalent) is
  375. # to be found.
  376. #
  377. TypesConfig conf/mime.types

  378. #
  379. # DefaultType is the default MIME type the server will use for a document
  380. # if it cannot otherwise determine one, such as from filename extensions.
  381. # If your server contains mostly text or HTML documents, "text/plain" is
  382. # a good value.  If most of your content is binary, such as applications
  383. # or images, you may want to use "application/octet-stream" instead to
  384. # keep browsers from trying to display binary files as though they are
  385. # text.
  386. #
  387. DefaultType text/plain

  388. #
  389. # The mod_mime_magic module allows the server to use various hints from the
  390. # contents of the file itself to determine its type.  The MIMEMagicFile
  391. # directive tells the module where the hint definitions are located.
  392. #
  393. <IfModule mod_mime_magic.c>
  394.     MIMEMagicFile conf/magic
  395. </IfModule>

  396. #
  397. # HostnameLookups: Log the names of clients or just their IP addresses
  398. # e.g., www.apache.org (on) or 204.62.129.132 (off).
  399. # The default is off because it'd be overall better for the net if people
  400. # had to knowingly turn this feature on, since enabling it means that
  401. # each client request will result in AT LEAST one lookup request to the
  402. # nameserver.
  403. #
  404. HostnameLookups Off

  405. #
  406. # EnableMMAP: Control whether memory-mapping is used to deliver
  407. # files (assuming that the underlying OS supports it).
  408. # The default is on; turn this off if you serve from NFS-mounted
  409. # filesystems.  On some systems, turning it off (regardless of
  410. # filesystem) can improve performance; for details, please see
  411. # http://httpd.apache.org/docs-2.0/mod/core.html#enablemmap
  412. #
  413. #EnableMMAP off

  414. #
  415. # EnableSendfile: Control whether the sendfile kernel support is
  416. # used  to deliver files (assuming that the OS supports it).
  417. # The default is on; turn this off if you serve from NFS-mounted
  418. # filesystems.  Please see
  419. # http://httpd.apache.org/docs-2.0/mod/core.html#enablesendfile
  420. #
  421. #EnableSendfile off

  422. #
  423. # ErrorLog: The location of the error log file.
  424. # If you do not specify an ErrorLog directive within a <VirtualHost>
  425. # container, error messages relating to that virtual host will be
  426. # logged here.  If you *do* define an error logfile for a <VirtualHost>
  427. # container, that host's errors will be logged there and not here.
  428. #
  429. ErrorLog logs/error_log

  430. #
  431. # LogLevel: Control the number of messages logged to the error_log.
  432. # Possible values include: debug, info, notice, warn, error, crit,
  433. # alert, emerg.
  434. #
  435. LogLevel warn

  436. #
  437. # The following directives define some format nicknames for use with
  438. # a CustomLog directive (see below).
  439. #
  440. LogFormat "%h %l %u %t "%r" %>s %b "%{Referer}i" "%{User-Agent}i"" combined
  441. LogFormat "%h %l %u %t "%r" %>s %b" common
  442. LogFormat "%{Referer}i -> %U" referer
  443. LogFormat "%{User-agent}i" agent

  444. SetEnvIf Request_URI \.gif$ image
  445. SetEnvIf Request_URI \.jpg$ image
  446. SetEnvIf Request_URI \.css$ image
  447. SetEnvIf Request_URI \.jpeg$ image
  448. # You need to enable mod_logio.c to use %I and %O
  449. #LogFormat "%h %l %u %t "%r" %>s %b "%{Referer}i" "%{User-Agent}i" %I %O" combinedio

  450. #
  451. # The location and format of the access logfile (Common Logfile Format).
  452. # If you do not define any access logfiles within a <VirtualHost>
  453. # container, they will be logged here.  Contrariwise, if you *do*
  454. # define per-<VirtualHost> access logfiles, transactions will be
  455. # logged therein and *not* in this file.
  456. #
  457. CustomLog logs/access_log combined
  458. #
  459. # If you would like to have agent and referer logfiles, uncomment the
  460. # following directives.
  461. #
  462. #CustomLog logs/referer_log referer
  463. #CustomLog logs/agent_log agent

  464. #
  465. # If you prefer a single logfile with access, agent, and referer information
  466. # (Combined Logfile Format) you can use the following directive.
  467. #
  468. #CustomLog logs/access_log combined

  469. #
  470. # ServerTokens
  471. # This directive configures what you return as the Server HTTP response
  472. # Header. The default is 'Full' which sends information about the OS-Type
  473. # and compiled in modules.
  474. # Set to one of:  Full | OS | Minor | Minimal | Major | Prod
  475. # where Full conveys the most information, and Prod the least.
  476. #
  477. ServerTokens Full

  478. #
  479. # Optionally add a line containing the server version and virtual host
  480. # name to server-generated pages (internal error documents, FTP directory
  481. # listings, mod_status and mod_info output etc., but not CGI generated
  482. # documents or custom error documents).
  483. # Set to "EMail" to also include a mailto: link to the ServerAdmin.
  484. # Set to one of:  On | Off | EMail
  485. #
  486. ServerSignature On

  487. #
  488. # Aliases: Add here as many aliases as you need (with no limit). The format is
  489. # Alias fakename realname
  490. #
  491. # Note that if you include a trailing / on fakename then the server will
  492. # require it to be present in the URL.  So "/icons" isn't aliased in this
  493. # example, only "/icons/".  If the fakename is slash-terminated, then the
  494. # realname must also be slash terminated, and if the fakename omits the
  495. # trailing slash, the realname must also omit it.
  496. #
  497. # We include the /icons/ alias for FancyIndexed directory listings.  If you
  498. # do not use FancyIndexing, you may comment this out.
  499. #
  500. Alias /icons/ "/home/app/apache/icons/"

  501. <Directory "/home/app/apache/icons">
  502.     Options Indexes MultiViews
  503.     AllowOverride None
  504.     Order allow,deny
  505.     Allow from all
  506. </Directory>

  507. #
  508. # This should be changed to the ServerRoot/manual/.  The alias provides
  509. # the manual, even if you choose to move your DocumentRoot.  You may comment
  510. # this out if you do not care for the documentation.
  511. #
  512. AliasMatch ^/manual(?:/(?:de|en|es|fr|ja|ko|ru))?(/.*)?$ "/home/app/apache/manual$1"

  513. <Directory "/home/app/apache/manual">
  514.     Options Indexes
  515.     AllowOverride None
  516.     Order allow,deny
  517.     Allow from all

  518.     <Files *.html>
  519.         SetHandler type-map
  520.     </Files>

  521.     SetEnvIf Request_URI ^/manual/(de|en|es|fr|ja|ko|ru)/ prefer-language=$1
  522.     RedirectMatch 301 ^/manual(?:/(de|en|es|fr|ja|ko|ru)){2,}(/.*)?$ /manual/$1$2
  523. </Directory>

  524. #
  525. # ScriptAlias: This controls which directories contain server scripts.
  526. # ScriptAliases are essentially the same as Aliases, except that
  527. # documents in the realname directory are treated as applications and
  528. # run by the server when requested rather than as documents sent to the client.
  529. # The same rules about trailing "/" apply to ScriptAlias directives as to
  530. # Alias.
  531. #
  532. ScriptAlias /cgi-bin/ "/home/app/apache/cgi-bin/"

  533. <IfModule mod_cgid.c>
  534. #
  535. # Additional to mod_cgid.c settings, mod_cgid has Scriptsock <path>
  536. # for setting UNIX socket for communicating with cgid.
  537. #
  538. #Scriptsock            logs/cgisock
  539. </IfModule>

  540. #
  541. # "/home/app/apache/cgi-bin" should be changed to whatever your ScriptAliased
  542. # CGI directory exists, if you have that configured.
  543. #
  544. <Directory "/home/app/apache/cgi-bin">
  545.     AllowOverride None
  546.     Options None
  547.     Order allow,deny
  548.     Allow from all
  549. </Directory>

  550. #
  551. # Redirect allows you to tell clients about documents which used to exist in
  552. # your server's namespace, but do not anymore. This allows you to tell the
  553. # clients where to look for the relocated document.
  554. # Example:
  555. # Redirect permanent /foo http://www.example.com/bar

  556. #
  557. # Directives controlling the display of server-generated directory listings.
  558. #

  559. #
  560. # IndexOptions: Controls the appearance of server-generated directory
  561. # listings.
  562. #
  563. IndexOptions FancyIndexing VersionSort

  564. #
  565. # AddIcon* directives tell the server which icon to show for different
  566. # files or filename extensions.  These are only displayed for
  567. # FancyIndexed directories.
  568. #
  569. AddIconByEncoding (CMP,/icons/compressed.gif) x-compress x-gzip

  570. AddIconByType (TXT,/icons/text.gif) text/*
  571. AddIconByType (IMG,/icons/image2.gif) image/*
  572. AddIconByType (SND,/icons/sound2.gif) audio/*
  573. AddIconByType (VID,/icons/movie.gif) video/*

  574. AddIcon /icons/binary.gif .bin .exe
  575. AddIcon /icons/binhex.gif .hqx
  576. AddIcon /icons/tar.gif .tar
  577. AddIcon /icons/world2.gif .wrl .wrl.gz .vrml .vrm .iv
  578. AddIcon /icons/compressed.gif .Z .z .tgz .gz .zip
  579. AddIcon /icons/a.gif .ps .ai .eps
  580. AddIcon /icons/layout.gif .html .shtml .htm .pdf
  581. AddIcon /icons/text.gif .txt
  582. AddIcon /icons/c.gif .c
  583. AddIcon /icons/p.gif .pl .py
  584. AddIcon /icons/f.gif .for
  585. AddIcon /icons/dvi.gif .dvi
  586. AddIcon /icons/uuencoded.gif .uu
  587. AddIcon /icons/script.gif .conf .sh .shar .csh .ksh .tcl
  588. AddIcon /icons/tex.gif .tex
  589. AddIcon /icons/bomb.gif core

  590. AddIcon /icons/back.gif ..
  591. AddIcon /icons/hand.right.gif README
  592. AddIcon /icons/folder.gif ^^DIRECTORY^^
  593. AddIcon /icons/blank.gif ^^BLANKICON^^

  594. #
  595. # DefaultIcon is which icon to show for files which do not have an icon
  596. # explicitly set.
  597. #
  598. DefaultIcon /icons/unknown.gif

  599. #
  600. # AddDescription allows you to place a short description after a file in
  601. # server-generated indexes.  These are only displayed for FancyIndexed
  602. # directories.
  603. # Format: AddDescription "description" filename
  604. #
  605. #AddDescription "GZIP compressed document" .gz
  606. #AddDescription "tar archive" .tar
  607. #AddDescription "GZIP compressed tar archive" .tgz

  608. #
  609. # ReadmeName is the name of the README file the server will look for by
  610. # default, and append to directory listings.
  611. #
  612. # HeaderName is the name of a file which should be prepended to
  613. # directory indexes.
  614. ReadmeName README.html
  615. HeaderName HEADER.html

  616. #
  617. # IndexIgnore is a set of filenames which directory indexing should ignore
  618. # and not include in the listing.  Shell-style wildcarding is permitted.
  619. #
  620. IndexIgnore .??* *~ *# HEADER* README* RCS CVS *,v *,t

  621. #
  622. # DefaultLanguage and AddLanguage allows you to specify the language of
  623. # a document. You can then use content negotiation to give a browser a
  624. # file in a language the user can understand.
  625. #
  626. # Specify a default language. This means that all data
  627. # going out without a specific language tag (see below) will
  628. # be marked with this one. You probably do NOT want to set
  629. # this unless you are sure it is correct for all cases.
  630. #
  631. # * It is generally better to not mark a page as
  632. # * being a certain language than marking it with the wrong
  633. # * language!
  634. #
  635. # DefaultLanguage nl
  636. #
  637. # Note 1: The suffix does not have to be the same as the language
  638. # keyword --- those with documents in Polish (whose net-standard
  639. # language code is pl) may wish to use "AddLanguage pl .po" to
  640. # avoid the ambiguity with the common suffix for perl scripts.
  641. #
  642. # Note 2: The example entries below illustrate that in some cases
  643. # the two character 'Language' abbreviation is not identical to
  644. # the two character 'Country' code for its country,
  645. # E.g. 'Danmark/dk' versus 'Danish/da'.
  646. #
  647. # Note 3: In the case of 'ltz' we violate the RFC by using a three char
  648. # specifier. There is 'work in progress' to fix this and get
  649. # the reference data for rfc1766 cleaned up.
  650. #
  651. # Catalan (ca) - Croatian (hr) - Czech (cs) - Danish (da) - Dutch (nl)
  652. # English (en) - Esperanto (eo) - Estonian (et) - French (fr) - German (de)
  653. # Greek-Modern (el) - Hebrew (he) - Italian (it) - Japanese (ja)
  654. # Korean (ko) - Luxembourgeois* (ltz) - Norwegian Nynorsk (nn)
  655. # Norwegian (no) - Polish (pl) - Portugese (pt)
  656. # Brazilian Portuguese (pt-BR) - Russian (ru) - Swedish (sv)
  657. # Simplified Chinese (zh-CN) - Spanish (es) - Traditional Chinese (zh-TW)
  658. #
  659. AddLanguage ca .ca
  660. AddLanguage cs .cz .cs
  661. AddLanguage da .dk
  662. AddLanguage de .de
  663. AddLanguage el .el
  664. AddLanguage en .en
  665. AddLanguage eo .eo
  666. AddLanguage es .es
  667. AddLanguage et .et
  668. AddLanguage fr .fr
  669. AddLanguage he .he
  670. AddLanguage hr .hr
  671. AddLanguage it .it
  672. AddLanguage ja .ja
  673. AddLanguage ko .ko
  674. AddLanguage ltz .ltz
  675. AddLanguage nl .nl
  676. AddLanguage nn .nn
  677. AddLanguage no .no
  678. AddLanguage pl .po
  679. AddLanguage pt .pt
  680. AddLanguage pt-BR .pt-br
  681. AddLanguage ru .ru
  682. AddLanguage sv .sv
  683. AddLanguage zh-CN .zh-cn
  684. AddLanguage zh-TW .zh-tw

  685. #
  686. # LanguagePriority allows you to give precedence to some languages
  687. # in case of a tie during content negotiation.
  688. #
  689. # Just list the languages in decreasing order of preference. We have
  690. # more or less alphabetized them here. You probably want to change this.
  691. #
  692. LanguagePriority en ca cs da de el eo es et fr he hr it ja ko ltz nl nn no pl pt pt-BR ru sv zh-CN zh-TW

  693. #
  694. # ForceLanguagePriority allows you to serve a result page rather than
  695. # MULTIPLE CHOICES (Prefer) [in case of a tie] or NOT ACCEPTABLE (Fallback)
  696. # [in case no accepted languages matched the available variants]
  697. #
  698. ForceLanguagePriority Prefer Fallback

  699. #
  700. # Commonly used filename extensions to character sets. You probably
  701. # want to avoid clashes with the language extensions, unless you
  702. # are good at carefully testing your setup after each change.
  703. # See http://www.iana.org/assignments/character-sets for the
  704. # official list of charset names and their respective RFCs.
  705. #
  706. AddCharset ISO-8859-1  .iso8859-1  .latin1
  707. AddCharset ISO-8859-2  .iso8859-2  .latin2 .cen
  708. AddCharset ISO-8859-3  .iso8859-3  .latin3
  709. AddCharset ISO-8859-4  .iso8859-4  .latin4
  710. AddCharset ISO-8859-5  .iso8859-5  .latin5 .cyr .iso-ru
  711. AddCharset ISO-8859-6  .iso8859-6  .latin6 .arb
  712. AddCharset ISO-8859-7  .iso8859-7  .latin7 .grk
  713. AddCharset ISO-8859-8  .iso8859-8  .latin8 .heb
  714. AddCharset ISO-8859-9  .iso8859-9  .latin9 .trk
  715. AddCharset ISO-2022-JP .iso2022-jp .jis
  716. AddCharset ISO-2022-KR .iso2022-kr .kis
  717. AddCharset ISO-2022-CN .iso2022-cn .cis
  718. AddCharset Big5        .Big5       .big5
  719. # For russian, more than one charset is used (depends on client, mostly):
  720. AddCharset WINDOWS-1251 .cp-1251   .win-1251
  721. AddCharset CP866       .cp866
  722. AddCharset KOI8-r      .koi8-r .koi8-ru
  723. AddCharset KOI8-ru     .koi8-uk .ua
  724. AddCharset ISO-10646-UCS-2 .ucs2
  725. AddCharset ISO-10646-UCS-4 .ucs4
  726. AddCharset UTF-8       .utf8

  727. # The set below does not map to a specific (iso) standard
  728. # but works on a fairly wide range of browsers. Note that
  729. # capitalization actually matters (it should not, but it
  730. # does for some browsers).
  731. #
  732. # See http://www.iana.org/assignments/character-sets
  733. # for a list of sorts. But browsers support few.
  734. #
  735. AddCharset GB2312      .gb2312 .gb
  736. AddCharset utf-7       .utf7
  737. AddCharset utf-8       .utf8
  738. AddCharset big5        .big5 .b5
  739. AddCharset EUC-TW      .euc-tw
  740. AddCharset EUC-JP      .euc-jp
  741. AddCharset EUC-KR      .euc-kr
  742. AddCharset shift_jis   .sjis

  743. #
  744. # AddType allows you to add to or override the MIME configuration
  745. # file mime.types for specific file types.
  746. #
  747. #AddType application/x-tar .tgz
  748. #
  749. # AddEncoding allows you to have certain browsers uncompress
  750. # information on the fly. Note: Not all browsers support this.
  751. # Despite the name similarity, the following Add* directives have nothing
  752. # to do with the FancyIndexing customization directives above.
  753. #
  754. #AddEncoding x-compress .Z
  755. #AddEncoding x-gzip .gz .tgz
  756. #
  757. # If the AddEncoding directives above are commented-out, then you
  758. # probably should define those extensions to indicate media types:
  759. #
  760. AddType application/x-compress .Z
  761. AddType application/x-gzip .gz .tgz

  762. #
  763. # AddHandler allows you to map certain file extensions to "handlers":
  764. # actions unrelated to filetype. These can be either built into the server
  765. # or added with the Action directive (see below)
  766. #
  767. # To use CGI scripts outside of ScriptAliased directories:
  768. # (You will also need to add "ExecCGI" to the "Options" directive.)
  769. #
  770. #AddHandler cgi-script .cgi

  771. #
  772. # For files that include their own HTTP headers:
  773. #
  774. #AddHandler send-as-is asis

  775. #
  776. # For server-parsed imagemap files:
  777. #
  778. #AddHandler imap-file map

  779. #
  780. # For type maps (negotiated resources):
  781. # (This is enabled by default to allow the Apache "It Worked" page
  782. #  to be distributed in multiple languages.)
  783. #
  784. AddHandler type-map var

  785. #
  786. # Filters allow you to process content before it is sent to the client.
  787. #
  788. # To parse .shtml files for server-side includes (SSI):
  789. # (You will also need to add "Includes" to the "Options" directive.)
  790. #
  791. #AddType text/html .shtml
  792. #AddOutputFilter INCLUDES .shtml

  793. #
  794. # Action lets you define media types that will execute a script whenever
  795. # a matching file is called. This eliminates the need for repeated URL
  796. # pathnames for oft-used CGI file processors.
  797. # Format: Action media/type /cgi-script/location
  798. # Format: Action handler-name /cgi-script/location
  799. #

  800. #
  801. # Customizable error responses come in three flavors:
  802. # 1) plain text 2) local redirects 3) external redirects
  803. #
  804. # Some examples:
  805. #ErrorDocument 500 "The server made a boo boo."
  806. #ErrorDocument 404 /missing.html
  807. #ErrorDocument 404 "/cgi-bin/missing_handler.pl"
  808. #ErrorDocument 402 http://www.example.com/subscription_info.html
  809. #

  810. #
  811. # Putting this all together, we can internationalize error responses.
  812. #
  813. # We use Alias to redirect any /error/HTTP_<error>.html.var response to
  814. # our collection of by-error message multi-language collections.  We use
  815. # includes to substitute the appropriate text.
  816. #
  817. # You can modify the messages' appearance without changing any of the
  818. # default HTTP_<error>.html.var files by adding the line:
  819. #
  820. #   Alias /error/include/ "/your/include/path/"
  821. #
  822. # which allows you to create your own set of files by starting with the
  823. # /home/app/apache/error/include/ files and copying them to /your/include/path/,
  824. # even on a per-VirtualHost basis.  The default include files will display
  825. # your Apache version number and your ServerAdmin email address regardless
  826. # of the setting of ServerSignature.
  827. #
  828. # The internationalized error documents require mod_alias, mod_include
  829. # and mod_negotiation.  To activate them, uncomment the following 30 lines.

  830. #    Alias /error/ "/home/app/apache/error/"
  831. #
  832. #    <Directory "/home/app/apache/error">
  833. #        AllowOverride None
  834. #        Options IncludesNoExec
  835. #        AddOutputFilter Includes html
  836. #        AddHandler type-map var
  837. #        Order allow,deny
  838. #        Allow from all
  839. #        LanguagePriority en cs de es fr it ja ko nl pl pt-br ro sv tr
  840. #        ForceLanguagePriority Prefer Fallback
  841. #    </Directory>
  842. #
  843. #    ErrorDocument 400 /error/HTTP_BAD_REQUEST.html.var
  844. #    ErrorDocument 401 /error/HTTP_UNAUTHORIZED.html.var
  845. #    ErrorDocument 403 /error/HTTP_FORBIDDEN.html.var
  846. #    ErrorDocument 404 /error/HTTP_NOT_FOUND.html.var
  847. #    ErrorDocument 405 /error/HTTP_METHOD_NOT_ALLOWED.html.var
  848. #    ErrorDocument 408 /error/HTTP_REQUEST_TIME_OUT.html.var
  849. #    ErrorDocument 410 /error/HTTP_GONE.html.var
  850. #    ErrorDocument 411 /error/HTTP_LENGTH_REQUIRED.html.var
  851. #    ErrorDocument 412 /error/HTTP_PRECONDITION_FAILED.html.var
  852. #    ErrorDocument 413 /error/HTTP_REQUEST_ENTITY_TOO_LARGE.html.var
  853. #    ErrorDocument 414 /error/HTTP_REQUEST_URI_TOO_LARGE.html.var
  854. #    ErrorDocument 415 /error/HTTP_UNSUPPORTED_MEDIA_TYPE.html.var
  855. #    ErrorDocument 500 /error/HTTP_INTERNAL_SERVER_ERROR.html.var
  856. #    ErrorDocument 501 /error/HTTP_NOT_IMPLEMENTED.html.var
  857. #    ErrorDocument 502 /error/HTTP_BAD_GATEWAY.html.var
  858. #    ErrorDocument 503 /error/HTTP_SERVICE_UNAVAILABLE.html.var
  859. #    ErrorDocument 506 /error/HTTP_VARIANT_ALSO_VARIES.html.var


  860. #
  861. # The following directives modify normal HTTP response behavior to
  862. # handle known problems with browser implementations.
  863. #
  864. BrowserMatch "Mozilla/2" nokeepalive
  865. BrowserMatch "MSIE 4\.0b2;" nokeepalive downgrade-1.0 force-response-1.0
  866. BrowserMatch "RealPlayer 4\.0" force-response-1.0
  867. BrowserMatch "Java/1\.0" force-response-1.0
  868. BrowserMatch "JDK/1\.0" force-response-1.0

  869. #
  870. # The following directive disables redirects on non-GET requests for
  871. # a directory that does not include the trailing slash.  This fixes a
  872. # problem with Microsoft WebFolders which does not appropriately handle
  873. # redirects for folders with DAV methods.
  874. # Same deal with Apple's DAV filesystem and Gnome VFS support for DAV.
  875. #
  876. BrowserMatch "Microsoft Data Access Internet Publishing Provider" redirect-carefully
  877. BrowserMatch "MS FrontPage" redirect-carefully
  878. BrowserMatch "^WebDrive" redirect-carefully
  879. BrowserMatch "^WebDAVFS/1.[0123]" redirect-carefully
  880. BrowserMatch "^gnome-vfs" redirect-carefully
  881. BrowserMatch "^XML Spy" redirect-carefully
  882. BrowserMatch "^Dreamweaver-WebDAV-SCM1" redirect-carefully

  883. #
  884. # Allow server status reports generated by mod_status,
  885. # with the URL of http://servername/server-status
  886. # Change the ".example.com" to match your domain to enable.
  887. #
  888. #<Location /server-status>
  889. #    SetHandler server-status
  890. #    Order deny,allow
  891. #    Deny from all
  892. #    Allow from .example.com
  893. #</Location>

  894. #
  895. # Allow remote server configuration reports, with the URL of
  896. #  http://servername/server-info (requires that mod_info.c be loaded).
  897. # Change the ".example.com" to match your domain to enable.
  898. #
  899. #<Location /server-info>
  900. #    SetHandler server-info
  901. #    Order deny,allow
  902. #    Deny from all
  903. #    Allow from .example.com
  904. #</Location>


  905. #
  906. # Bring in additional module-specific configurations
  907. #
  908. <IfModule mod_ssl.c>
  909. #    Include conf/ssl.conf
  910. </IfModule>


  911. ### Section 3: Virtual Hosts
  912. #
  913. # VirtualHost: If you want to maintain multiple domains/hostnames on your
  914. # machine you can setup VirtualHost containers for them. Most configurations
  915. # use only name-based virtual hosts so the server doesn't need to worry about
  916. # IP addresses. This is indicated by the asterisks in the directives below.
  917. #
  918. # Please see the documentation at
  919. # <URL:http://httpd.apache.org/docs-2.0/vhosts/>
  920. # for further details before you try to setup virtual hosts.
  921. #
  922. # You may use the command line option '-S' to verify your virtual host
  923. # configuration.

  924. #
  925. # Use name-based virtual hosting.
  926. #
  927. NameVirtualHost *:80

  928. #
  929. # VirtualHost example:
  930. # Almost any Apache directive may go into a VirtualHost container.
  931. # The first VirtualHost section is used for requests without a known
  932. # server name.
  933. #
  934. #<VirtualHost *:80>
  935. #    ServerAdmin webmaster@dummy-host.example.com
  936. #    DocumentRoot /www/docs/dummy-host.example.com
  937. #    ServerName dummy-host.example.com
  938. #    ErrorLog logs/dummy-host.example.com-error_log
  939. #    CustomLog logs/dummy-host.example.com-access_log common
  940. #</VirtualHost>

  941. <VirtualHost *:80>
  942.         ServerAdmin sysop@gznf.net
  943.         DocumentRoot /home/www/gznf.net/home/
  944.         ServerName gznf.cn
  945.         ServerAlias www.gznf.cn gznf.cn *.gznf.cn
  946.         ErrorDocument 404 http://www.gznf.net/404.html
  947.         <directory "/home/www/gznf.net/home/">
  948.                 Options FollowSymLinks
  949.                 AllowOverride All
  950.                 Order allow,deny
  951.                 Allow from all
  952.                 Deny from 124.115.0.0/16
  953.                 Deny from 58.61.164.0/24
  954.                 Deny from 74.6.0.0/16
  955.                 #Order deny,allow
  956.                 #Deny from All
  957.                 #Allow from 219.137.50.200
  958.                 #Allow from 127.0.0.1
  959.                 #Allow from 61.142.80.71
  960.         </directory>

  961.         DirectoryIndex index.php index.html index.htm
  962.         ErrorLog logs/home.8da.org-error_log
  963.         CustomLog logs/home.8da.org-access_log combined env=!image
  964.         AddType application/x-httpd-php .php
  965.         Options FollowSymLinks MultiViews
  966.         <IfModule mod_rewrite.c>
  967.                 RewriteEngine On

  968.                 RewriteRule ^/home/(space|network)\-(.+)\.html$ /$1.php?rewrite=$2 [L]
  969.                 RewriteRule ^/home/(space|network)\.html$ /$1.php [L]
  970.                 RewriteRule ^/home/([0-9]+)$ /space.php?uid=$1 [L]

  971.         </IfModule>
  972. </VirtualHost>

  973. <VirtualHost *:80>
  974.         ServerAdmin sysop@gznf.net
  975.         DocumentRoot /home/www/gznf.net/
  976.         ServerName gznf.net
  977.         ServerAlias www.gznf.net gznf.net *.gznf.net
  978.         ErrorDocument 404 http://www.gznf.net/404.html
  979.         <directory "/home/www/gznf.net/">
  980.                 Options FollowSymLinks
  981.                 AllowOverride All
  982.                 Order allow,deny
  983.                 Allow from all
  984.                 Deny from 124.115.0.0/16
  985.                 Deny from 58.61.164.0/24
  986.                 Deny from 74.6.0.0/16
  987.                 #Order deny,allow
  988.                 #Deny from All
  989.                 #Allow from 219.137.50.200
  990.                 #Allow from 127.0.0.1
  991.                 #Allow from 61.142.80.71
  992.         </directory>

  993.         DirectoryIndex index.php index.html index.htm
  994.         ErrorLog logs/home.8da.org-error_log
  995.         CustomLog logs/home.8da.org-access_log combined env=!image
  996.         AddType application/x-httpd-php .php
  997.         Options FollowSymLinks MultiViews
  998.         <IfModule mod_rewrite.c>
  999.                 RewriteEngine On

  1000.                 RewriteRule ^/([0-9]+)/spacelist(.+)$ /index.php?uid/$1/action/spacelist/type$2 [L]
  1001.                 RewriteRule ^/([0-9]+)/viewspace(.+)$ /index.php?uid/$1/action/viewspace/itemid$2 [L]
  1002.                 RewriteRule ^/([0-9]+)/viewbbs(.+)$ /index.php?uid/$1/action/viewbbs/tid$2 [L]
  1003.                 RewriteRule ^/([0-9]+)/(.*)$ /index.php?uid/$1/$2 [L]
  1004.                 RewriteRule ^/([0-9]+)$ /index.php?uid/$1 [L]

  1005.                 RewriteRule ^/action(.+)$ /index.php?action$1 [L]
  1006.                 RewriteRule ^/category(.+)$ /index.php?action/category/catid$1 [L]
  1007.                 RewriteRule ^/viewnews(.+)$ /index.php?action/viewnews/itemid$1 [L]
  1008.                 RewriteRule ^/viewthread(.+)$ /index.php?action/viewthread/tid$1 [L]
  1009.                 RewriteRule ^/mygroup(.+)$ /index.php?action/mygroup/gid$1 [L]

  1010.                 RewriteRule ^(.*)/archiver/((fid|tid)-[\w\-]+\.html)$ $1/archiver/index.php?$2
  1011.                 RewriteRule ^(.*)/forum-([0-9]+)-([0-9]+)\.html$ $1/forumdisplay.php?fid=$2&page=$3
  1012.                 RewriteRule ^(.*)/thread-([0-9]+)-([0-9]+)-([0-9]+)\.html$ $1/viewthread.php?tid=$2&extra=page\%3D$4&page=$3
  1013.                 RewriteRule ^(.*)/space-(username|uid)-(.+)\.html$ $1/space.php?$2=$3
  1014.                 RewriteRule ^(.*)/tag-(.+)\.html$ $1/tag.php?name=$2

  1015.                 RewriteRule ^/home/(space|network)\-(.+)\.html$ /$1.php?rewrite=$2 [L]
  1016.                 RewriteRule ^/home/(space|network)\.html$ /$1.php [L]
  1017.                 RewriteRule ^/home/([0-9]+)$ /space.php?uid=$1 [L]

  1018.         </IfModule>
  1019. </VirtualHost>

  1020. <VirtualHost *:80>
  1021.         ServerAdmin sysop@gznf.net
  1022.         DocumentRoot /home/www/dog.gznf.net/
  1023.         ServerName myluckdog.com
  1024.         ServerAlias  www.myluckdog.com myluckdog.com *.myluckdog.com
  1025.         <directory "/home/www/dog.gznf.net/">
  1026.                 Options FollowSymLinks
  1027.                 AllowOverride All
  1028.                 Order allow,deny
  1029.                 Allow from all
  1030.                #Order deny,allow
  1031.                #Deny from All
  1032.                #Allow from 219.137.50.200
  1033.                #Allow from 127.0.0.1
  1034.                #Allow from 61.142.80.71
  1035.         </directory>

  1036.         DirectoryIndex index.php index.html index.htm
  1037.         ErrorLog logs/home.8da.org-error_log
  1038.         CustomLog logs/home.8da.org-access_log  combined env=!image
  1039.         AddType application/x-httpd-php .php
  1040.         Options FollowSymLinks MultiViews
  1041. </VirtualHost>

  1042. <VirtualHost *:80>
  1043.         ServerAdmin sysop@gznf.net
  1044.         DocumentRoot /home/www/dog.gznf.net/home/
  1045.         ServerName myluckdog.net

  1046.         ServerAlias www.myluckdog.net myluckdog.net *.myluckdog.net
  1047.         <directory "/home/www/dog.gznf.net/home/">
  1048.                 Options FollowSymLinks
  1049.                 AllowOverride All
  1050.                 Order allow,deny
  1051.                 Allow from all
  1052.                #Order deny,allow
  1053.                #Deny from All
  1054.                #Allow from 219.137.50.200
  1055.                #Allow from 127.0.0.1
  1056.                #Allow from 61.142.80.71
  1057.         </directory>

  1058.         DirectoryIndex index.php index.html index.htm
  1059.         ErrorLog logs/home.8da.org-error_log
  1060.         CustomLog logs/home.8da.org-access_log  combined env=!image
  1061.         AddType application/x-httpd-php .php
  1062.         Options FollowSymLinks MultiViews

  1063.         <IfModule mod_rewrite.c>
  1064.                 RewriteEngine On

  1065.                 RewriteRule ^/home/(space|network)\-(.+)\.html$ /$1.php?rewrite=$2 [L]
  1066.                 RewriteRule ^/home/(space|network)\.html$ /$1.php [L]
  1067.                 RewriteRule ^/home/([0-9]+)$ /space.php?uid=$1 [L]

  1068.         </IfModule>
  1069. </VirtualHost>


  1070. <VirtualHost *:80>
  1071.         ServerAdmin sysop@gznf.net
  1072.         DocumentRoot /home/www/gznf.net/forum/wap/
  1073.         ServerName wap.gznf.net
  1074.         ServerAlias wap.gznf.cn wap.gznf.net
  1075.         ErrorDocument 404 http://www.gznf.net/404.html
  1076.         <directory "/home/www/gznf.net/forum/wap/">
  1077.                 Options FollowSymLinks
  1078.                 AllowOverride All
  1079.                 Order allow,deny
  1080.                 Allow from all
  1081.                 Deny from 124.115.0.0/16
  1082.                 Deny from 58.61.164.0/24
  1083.                 Deny from 74.6.0.0/16
  1084.                 #Order deny,allow
  1085.                 #Deny from All
  1086.                 #Allow from 219.137.50.200
  1087.                 #Allow from 127.0.0.1
  1088.                 #Allow from 61.142.80.71
  1089.         </directory>

  1090.         DirectoryIndex index.php index.html index.htm
  1091.         ErrorLog logs/home.8da.org-error_log
  1092.         CustomLog logs/home.8da.org-access_log combined env=!image
  1093.         AddType application/x-httpd-php .php
  1094.         Options FollowSymLinks MultiViews

  1095.         <IfModule mod_rewrite.c>
  1096.                 RewriteEngine On

  1097.                 RewriteRule ^/([0-9]+)/spacelist(.+)$ /index.php?uid/$1/action/spacelist/type$2 [L]
  1098.                 RewriteRule ^/([0-9]+)/viewspace(.+)$ /index.php?uid/$1/action/viewspace/itemid$2 [L]
  1099.                 RewriteRule ^/([0-9]+)/viewbbs(.+)$ /index.php?uid/$1/action/viewbbs/tid$2 [L]
  1100.                 RewriteRule ^/([0-9]+)/(.*)$ /index.php?uid/$1/$2 [L]
  1101.                 RewriteRule ^/([0-9]+)$ /index.php?uid/$1 [L]

  1102.                 RewriteRule ^/action(.+)$ /index.php?action$1 [L]
  1103.                 RewriteRule ^/category(.+)$ /index.php?action/category/catid$1 [L]
  1104.                 RewriteRule ^/viewnews(.+)$ /index.php?action/viewnews/itemid$1 [L]
  1105.                 RewriteRule ^/viewthread(.+)$ /index.php?action/viewthread/tid$1 [L]
  1106.                 RewriteRule ^/mygroup(.+)$ /index.php?action/mygroup/gid$1 [L]

  1107.                 RewriteRule ^(.*)/archiver/((fid|tid)-[\w\-]+\.html)$ $1/archiver/index.php?$2
  1108.                 RewriteRule ^(.*)/forum-([0-9]+)-([0-9]+)\.html$ $1/forumdisplay.php?fid=$2&page=$3
  1109.                 RewriteRule ^(.*)/thread-([0-9]+)-([0-9]+)-([0-9]+)\.html$ $1/viewthread.php?tid=$2&extra=page\%3D$4&page=$3
  1110.                 RewriteRule ^(.*)/space-(username|uid)-(.+)\.html$ $1/space.php?$2=$3
  1111.                 RewriteRule ^(.*)/tag-(.+)\.html$ $1/tag.php?name=$2

  1112.                 RewriteRule ^/home/(space|network)\-(.+)\.html$ /$1.php?rewrite=$2 [L]
  1113.                 RewriteRule ^/home/(space|network)\.html$ /$1.php [L]
  1114.                 RewriteRule ^/home/([0-9]+)$ /space.php?uid=$1 [L]

  1115.         </IfModule>
  1116. </VirtualHost>



  1117.   <VirtualHost *:80>   
  1118.          ServerAdmin funboxcn@gmail.com
  1119.             DocumentRoot /home/app/awstats-6.5/wwwroot
  1120.             ServerName admin.funbox.cn
  1121.             ErrorLog logs/admin.funbox.cn-error_log
  1122.             CustomLog logs/admin.funbox.cn-access_log combined  env=!image
  1123.                 Alias /awstatsclasses "/home/app/awstats-6.5/wwwroot/classes/"
  1124.                 Alias /awstatscss "/home/app/awstats-6.5/wwwroot/css/"
  1125.                 Alias /awstatsicons "/home/app/awstats-6.5/wwwroot/icon/"
  1126.                 ScriptAlias /awstats/ "/home/app/awstats-6.5/wwwroot/cgi-bin/"
  1127.         <Directory "/home/app/awstats-6.5/wwwroot">
  1128.             Options None
  1129.             AllowOverride AuthConfig
  1130.             Order allow,deny
  1131.             Allow from all
  1132.         </Directory>
  1133. </VirtualHost>

  1134. #LoadModule caucho_module /home/app/apache/modules/mod_caucho.so

  1135. #ResinConfigServer localhost 6802
  1136. #CauchoConfigCacheDirectory /tmp
  1137. #CauchoStatus yes


  1138. # This is to permit URL access to scripts/files in AWStats directory.
  1139. #
  1140. <Directory "/home/app/awstats-6.5/wwwroot/cgi-bin/wwwroot">
  1141.     Options None
  1142.     AllowOverride All
  1143.     Order allow,deny
  1144.     Allow from all
  1145. </Directory>




复制代码

[ 本帖最后由 cookiedog 于 2008-8-30 11:01 编辑 ]

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?立即注册

x
复读生 发表于 2008-8-28 20:21:10 | 显示全部楼层
收藏了  喜欢你~
回复

使用道具 举报

xiaoyuwxz 发表于 2008-8-28 20:41:02 | 显示全部楼层
LSD太牛了,人家是求助的,你偏收藏了。

从上面看并没发现什么错,你可以先屏蔽下伪静态规则试下

所有的都设在httpd.conf里感觉有点乱,应该按虚拟主机设置,并不在此内加载伪静态规则,规则应该加载到  .htaccess 里,这样较容易发现问题。
回复

使用道具 举报

 楼主| cookiedog 发表于 2008-8-30 11:01:14 | 显示全部楼层
我已经解决了问题,

ServerName中的域名和ServerAlias的域名是不能重复的,重复了就出现莫名其妙的故障。

原帖由 xiaoyuwxz 于 2008-8-28 20:41 发表
LSD太牛了,人家是求助的,你偏收藏了。

从上面看并没发现什么错,你可以先屏蔽下伪静态规则试下

所有的都设在httpd.conf里感觉有点乱,应该按虚拟主机设置,并不在此内加载伪静态规则,规则应该加载到   ...
回复

使用道具 举报

grepercentile 发表于 2008-10-13 19:16:04 | 显示全部楼层
数据库没升级完整`
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

手机版|小黑屋|Discuz! 官方站 ( 皖ICP备16010102号 )star

GMT+8, 2024-11-23 21:40 , Processed in 0.031264 second(s), 4 queries , Gzip On, Redis On.

Powered by Discuz! X3.4

Copyright © 2001-2023, Tencent Cloud.

快速回复 返回顶部 返回列表