Networking Forums

Networking Forums > Computer Networking > Linux Networking > Apache mod_rewrite mod_proxy_html

Reply
Thread Tools Display Modes

Apache mod_rewrite mod_proxy_html

 
 
Henning Eiben
Guest
Posts: n/a

 
      01-03-2007, 05:54 AM
Hi,

I'm using Apache and mod_rewrite to rewrite all request from an external
URL to an internal URL. Unfortunatly the content contains sometimes FQDN
to the internal server, which needs to be mapped to the external URL
when access from the outside. So I figured mod_proxy_html should be the
module to use.

So I've set up a virtual host like this:

<VirtualHost 192.168.0.1:8000>

ErrorLog "/var/log/apache2/error.log"
# LogLevel debug

RewriteEngine On
RewriteLog "/var/log/apache2/rewrite.log"
# RewriteLogLevel 9

RewriteCond %{HTTP_HOST} ^[^.]+\.external\.domain\.com
RewriteRule ^(.+) http://%{HTTP_HOST}$1 [C]
RewriteRule ^http://([^.]+)\.external\.domain\.com:8000(.*)$
http://$1.internal.domain

ProxyHTMLLogVerbose On
#ProxyHTMLExtended On
ProxyHTMLURLMap http://([^.]+).internal.domain
http://$1.external.domain.com:8000
</VirtualHost>


If I understand the doc for mod_proxy_html I should see a bunch of
messages in the error-log because of "ProxyHTMLLogVerbose On"; but that
is not the case. Also the content is not being rewriten. Is there
something I'm missing?
 
Reply With Quote
 
 
 
 
Nick Kew
Guest
Posts: n/a

 
      01-03-2007, 09:31 PM
On Wed, 03 Jan 2007 07:54:56 +0100
Henning Eiben <(E-Mail Removed)> wrote:

> Is there
> something I'm missing?


Yes. You haven't configured a proxy at all. Nor have you
activated mod_proxy_html. All you've done is to define a
mapping that'll apply *if* you configure those two things.

I suggest reading the reverse proxying tutorial referenced on
the mod_proxy_html page. If that doesn't help, you can get
low-cost support by subscribing as a user of mod_proxy_html.

--
Nick Kew

Application Development with Apache - the Apache Modules Book
http://www.apachetutor.org/
 
Reply With Quote
 
Henning Eiben
Guest
Posts: n/a

 
      02-08-2007, 02:45 PM
Nick Kew schrieb:

>
>> Is there
>> something I'm missing?

>
> Yes. You haven't configured a proxy at all. Nor have you
> activated mod_proxy_html. All you've done is to define a
> mapping that'll apply *if* you configure those two things.
>
> I suggest reading the reverse proxying tutorial referenced on
> the mod_proxy_html page. If that doesn't help, you can get
> low-cost support by subscribing as a user of mod_proxy_html.



Well, I thought that mod_proxy_html was enabled, since it's included in
the "server-"attribute of the http-header

So how would I configure a proxy? What I basically want is to
reverse-proxy from the outside through apache to several web-servers on
the inside ...
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache mrdjmagnet@aol.com Linux Networking 1 12-14-2008 01:05 AM
mod_rewrite madness Michael Mol Linux Networking 3 02-08-2007 06:55 AM
mod_rewrite help needed google@w98.us Linux Networking 1 02-10-2005 07:55 AM
mod_rewrite: replace all occurance of a character jason.yfho@gmail.com Linux Networking 2 01-06-2005 03:34 PM
IIS vs Apache...???? gerry Home Networking 9 09-07-2004 07:15 PM



1 2 3 4 5 6 7 8 9 10 11