The UK Home Automation Archive

Archive Home
Group Home
Search Archive


Advanced Search

The UKHA-ARCHIVE IS CEASING OPERATIONS 31 DEC 2024


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Apache Reverse proxying - WAS Introduction and first questions



OK - my own config had got a bit bizarre, and was coming up with odd
errors,
so I've installed a clean version on my test server :-)


1: Install Apache 2. (I'm using 2.0.48, because I had it handy - otherwise
get the latest from www.apache.org)

2: Go to start / programs / apache http server 2.x.x / configure ... / edit
the configuration

2.1: Uncomment the following lines (about 3 screenfuls down in the config
file)

LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_connect_module modules/mod_proxy_connect.so
LoadModule proxy_http_module modules/mod_proxy_http.so


2: Add a name-based virtual host directives by pasting the bottom at the
end
of the file.

(You'll want to change the references to the server names and IP addresses
to reflect your network - I'd fairly odd in running 10.14/16 internally -
most people use 192.168...)

---------START ON NEXT LINE---------

NameVirtualHost *:80

<VirtualHost *:80>
ServerName harmony.ascentium.co.uk
proxyrequests on
proxypass / http://10.14.16.22/
proxypassreverse / http://10.14.16.22/
</VirtualHost>

<VirtualHost *:80>
ServerName xapcache.ascentium.co.uk
proxyrequests on
proxypass / http://10.14.16.14/
proxypassreverse / http://10.14.16.14/
</VirtualHost>

---------END ON PREVIOUS LINE---------


3: Create DNS entries....

3.1 Edit %windir%/system32/drivers/etc/hosts to add the server names as
specified in 2....

... note that ALL of these entries must point to the IP address of the
PROXY
server, not the server you are trying to proxy...

3.2 Run NBTSTAT -R

(note that the R must be upper-case, running it -r will show NetBios names,
whereas we want it to flush the NBT cache - if you understand it, weep at
my
crude hacking and do the name resolution properly, if you don't understand
it, just run the command !)


4: Test

Fire up your favourite web browser at the server names you set in 2 and
3....

Just done and tesed on my Win2k box, and all works fine....

.... with Internet explorer....




PEOPLE WHO USE FIREFOX AS THEIR WEB BROWSER READ ON...


The reverse proxying of some of the pages is rendering the entire page as
block-text showing the source... but it works with the Harmony web server
normally - it's only the proxying that's failing. I've noticed that it has
trouble with caching of sites all over the place, so I'm wondering if there
is something funny with its HTTP1.1 support???? Anyone else get these
problems?


Mark




Home | Main Index | Thread Index

Comments to the Webmaster are always welcomed, please use this contact form . Note that as this site is a mailing list archive, the Webmaster has no control over the contents of the messages. Comments about message content should be directed to the relevant mailing list.