httpd-bugs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 10503] New: - Alias and ScriptAlias do not work when VirtualDocumentRoot is used
Date Fri, 05 Jul 2002 11:05:27 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10503>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10503

Alias and ScriptAlias do not work when VirtualDocumentRoot is used

           Summary: Alias and ScriptAlias do not work when
                    VirtualDocumentRoot is used
           Product: Apache httpd-2.0
           Version: 2.0.39
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: Major
          Priority: Other
         Component: mod_vhost_alias
        AssignedTo: bugs@httpd.apache.org
        ReportedBy: bugzilla@vampire.com.hk


I reported this to users@httpd.apache.org on 30 June, I've received no response
so I'm submitting this.

I've been using Apache 1.3.9 on Linux with multiple virtual hosts and
shared directories for icons and cgi scripts. In srm.conf I have:

Alias /icons/ /usr/share/apache/icons/
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/

and in httpd.conf:

VirtualDocumentRoot /home/sites/%4/%3/%2/%1

Then I set up another server and installed Apache 2.0.39 to replace the
old server. After I took note of the configuration directive changes for
version 2, the server would run and serve pages from the different virtual
hosts, but the icons and script directories were not accessible through
the virtual hosts.

A typical entry from the error log is:

[Sun Jun 30 01:46:43 2002] [error] [client 210.184.87.231] File does not
exist: /home/sites/hk/com/candies/www/icons, referer:
http://www.candies.com.hk/

With the corresponding entry from the access log:

www.candies.com.hk 210.184.87.231 - - [30/Jun/2002:01:46:43 +0800] "GET
/icons/logos/yklogo_n.gif HTTP/1.0" 404 222 "http://www.candies.com.hk/"
"Mozilla/4.79 [en] (WinNT; U)" 0 "en,zh-CN,zh-TW"

I could access those directories through the default host. I no longer
have a srm.conf file, so the Alias and ScriptAlias directives are in
httpd.conf now. I have tried many variantions on the config file. I
noticed there was a configuration with a similar purpose in:
http://httpd.apache.org/docs-2.0/vhosts/mass.html#combinations that shows
ScriptAlias being used with VirtualDocumentRoot, so I tried a similar
configuration:

<VirtualHost 210.184.87.232:80 127.0.0.1:80>
    ServerName prawn.yuikee.com.hk 
    DocumentRoot /home/sites/hk/com/yuikee
    Alias /icons/ /usr/local/apache2/icons/ 
    ScriptAlias /cgi-bin/ /usr/local/apache2/cgi-bin/
    VirtualDocumentRoot /home/sites/%4/%3/%2/%1 

</VirtualHost>

to no avail. NameVirtualHost made no difference either. It is not a client
caching problem, I did many of the tests using telnet to port 80.

I know the aliasing is working because I can leave an IP address out of
the VirtualHost directive and access the icons and scripts directories
through the default host. I can see the virtual hosting working. But the
aliasing doesn't work with the VirtualDocumentRoot, even though it used to
work in version 1.3.9

What am I missing? I checked the "Upgrading to 2.0 from 1.3" notes and
found nothing relevant. Is there some trick to doing this, or is it broken
in version 2?

Thanks,

Allan Dyer, YKCL

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


Mime
View raw message