You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Neil Marjoram <n....@vam.ac.uk> on 2002/09/04 10:22:26 UTC
[users@httpd] Help with Virtual Hosting
I applogise if this subject has been posted before, I am a new member and have
missed it!
I have a small problem with ScriptAlias and virtual hosts. I currently run
Apache 1.3.6 on a Solaris system running a two vitual hosts, one of which is
obsolete. These hosts were set up so that Apache could call the content
management system using ProxyPass, and also some static pages we have
installed outside the content manager.
I have recently installed a new system RH 7.3 with Apache 1.3.23 to replace
the old Solaris system. Again two virtual hosts have been setup, one to call
the old content management system and serve the old static site now installed
on the new system, the other for a new site on the same system.
Both these sites have their own cgi-bin and DocumentRoot. Everything works
fine, except for ScriptAlias, the default ScriptAlias is set to /www/cgi-bin,
which is the new cgi bin for the first site. This is also set in the virtual
host section for the frst site, the second site is set within it's virtual
host to /www/tm/cgi-bin. The second site works fine, but the first does not
want to know, even when it is not specified in the virtual host section ( I
would expect it then to take it from the server default). The only difference
between the two v hosts is the use of ProxyPass. If I place a ProxyPass back
to the localhost it works (as shown in extract) I have copied out the section
in the httpd.conf file for the v hosts. Can anyone shed light on my problem -
I guess I have scrambled the Proxy setup! Or perhaps this is how it is
suppose to work ?
The cgi-directorys have ExecCGI set in the conf, the server listens on
locahost:8081 and port 80 to allow the ProxyPass.
NameVirtualHost 172.16.49.53
-- <VirtualHost 172.16.49.53>
ServerAdmin n.marjoram@vam.ac.uk
DocumentRoot /www/htdocs
ScriptAlias /cgi-bin/ /www/cgi-bin/ # Has no effect present or not
ServerName www.aname.ac.uk
CacheRoot "/var/cache/static"
CacheSize 5
CacheGcInterval 4
CacheMaxExpire 24
CacheLastModifiedFactor 0.1
CacheDefaultExpire 1
ProxyPass /cgi-bin/ http://127.0.0.1:8081/cgi-bin/ # This line allows cgi
to run but above ScriptAlias has no effect
ProxyPass /vastatic/ http://127.0.0.1:8081/vastatic/
ProxyPass /Explorer/Virtual/forums/
http://www.aname.ac.uk:8081/Explorer/Virtual/forums/
ProxyPass / http://oldserver.aname.ac.uk:8080/
ErrorLog /var/log/httpd/httpd-www-error.log
CustomLog /var/log/httpd/httpd-www-access.log common
</VirtualHost>
<VirtualHost 172.16.49.53>
ServerAdmin n.marjoram@vam.ac.uk
DocumentRoot /www/tm/docs
ScriptAlias /cgi-bin/ /www/tm/cgi-bin/ # This works fine
ServerName tm.aname.ac.uk
CacheRoot "/var/cache/tm"
CacheSize 5
CacheGcInterval 4
CacheMaxExpire 24
CacheLastModifiedFactor 0.1
CacheDefaultExpire 1
ErrorLog /var/log/httpd/httpd-tm-error.log
CustomLog /var/log/httpd/httpd-tm-access.log common
</VirtualHost>
Neil Marjoram.
Unix Systems Manager,
Victoria and Albert Museum,
Cromwell Road,
London.
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org