httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andy Ee" <>
Subject [users@httpd] Apache/2.2.12 Reverse Proxy
Date Tue, 08 Jun 2010 06:28:47 GMT
Dear all,
I am having JSP page redirecting problem with apache reverse proxy and
have been troubleshooting it for a month already. I really hope someone
may englighten me in this thread. Really appreciate and thanks.
The infra is setup as:
Internet <--> Apache2 Reverse Proxy <--> Tomcat
1. The apache2 is purely configured as a reverse proxy server and it's URL
2. The Tomcat is setup to host the JSP website internally, and its URL is
With the configurations given below, it maps to the internal url nicely. I
can see the JSP website by
However, when I click on hyperlink on the website that does internal PAGE
REDIRECT, the browser could not display the page. Apparently, the page
redirect action breaks the reverse proxy.
Did i miss out anything?
My reverse proxy config:
UseCanonicalName Off
ServerSignature Off
HostnameLookups Off
ServerTokens Prod
ServerRoot "/usr/local/apache2"
TraceEnable Off
DocumentRoot "/www/apache2/"
PidFile /usr/local/apache2/logs/
ScoreBoardFile /usr/local/apache2/logs/httpd.scoreboard
<IfModule dir_module>
    DirectoryIndex index.html
# =================================================
# HTTP and performance settings
# =================================================
Timeout 300
KeepAlive On
MaxKeepAliveRequests 100
KeepAliveTimeout 30
<IfModule prefork.c>
    MinSpareServers 5
    MaxSpareServers 10
    StartServers 5
    MaxClients 150
    MaxRequestsPerChild 0
# ================================================
# PHP5
# ===============================================
LoadModule php5_module        modules/
<IfModule php5_module>
AddType application/x-httpd-php .php .phtml
AddType application/x-httpd-php-source .phps
# =================================================
# Access control
# =================================================
<Directory />
    Options None
    AllowOverride none
    Order deny,allow
    Deny from all
<FilesMatch "^\.ht">
    Order allow,deny
    Deny from all
    Satisfy All
<Directory "/usr/local/apache2/cgi-bin">
    AllowOverride None
    Options None
    Order allow,deny
    Allow from all
# =================================================
# MIME encoding
# =================================================
<IfModule mod_mime.c>
    TypesConfig /usr/local/apache2/conf/mime.types
DefaultType text/plain
<IfModule mod_mime.c>
    AddEncoding x-compress              .Z
    AddEncoding x-gzip                  .gz .tgz
    AddType application/x-compress      .Z
    AddType application/x-gzip          .gz .tgz
    AddType application/x-tar           .tgz
    AddType application/x-x509-ca-cert  .crt
    AddType application/x-pkcs7-crl     .crl
<IfModule alias_module>
     ScriptAlias /cgi-bin/ /www/cgi-bin/
# =================================================
# Reverse Proxy settings
# =================================================
LoadModule  deflate_module       modules/
LoadModule xmlns_module modules/
LoadModule xhtml_module modules/
LoadModule rewrite_module modules/
LoadModule headers_module     modules/
LoadFile   /usr/lib/
LoadModule proxy_html_module modules/
LoadModule xml2enc_module modules/
    DocumentRoot /www/apache2/
    Userdir disabled
    ProxyHTMLLogVerbose On
    LogLevel Debug
    ProxyRequests Off
    RewriteEngine on
    RewriteRule ^/abc/mysite$ /abc/mysite/ [R]
    ProxyPass /abc/mysite/
    ProxyPassReverse /abc/mysite/
    <Proxy *>
      Order Deny,Allow
      Allow from all
    <Location /abc/mysite/>
     ProxyPassReverse /
     ProxyHTMLEnable On
     ProxyHTMLExtended On
     ProxyHTMLURLMap  /mysite/      /abc/mysite/
     RequestHeader    unset  Accept-Encoding
     ProxyHTMLLinks  a               href
     ProxyHTMLLinks  area            href
     ProxyHTMLLinks  link            href
     ProxyHTMLLinks  img             src longdesc usemap
     ProxyHTMLLinks  object          classid codebase data usemap
     ProxyHTMLLinks  q               cite
     ProxyHTMLLinks  blockquote      cite
     ProxyHTMLLinks  ins             cite
     ProxyHTMLLinks  del             cite
     ProxyHTMLLinks  form            action
     ProxyHTMLLinks  input           src usemap
     ProxyHTMLLinks  head            profile
     ProxyHTMLLinks  base            href
     ProxyHTMLLinks  script          src for
     ProxyHTMLLinks  iframe          src
     ProxyHTMLEvents onclick ondblclick onmousedown onmouseup \
                         onmouseover onmousemove onmouseout onkeypress \
                         onkeydown onkeyup onfocus onblur onload \
                         onunload onsubmit onreset onselect onchange
     ProxyHTMLURLMap url\([^\)]*)\)
url( $1) Rihe
    BrowserMatch ".*MSIE.*" nokeepalive ssl-unclean-shutdown downgrade-1.0
    ErrorLog logs/mysite-error_log
    CustomLog logs/mysite-access_log combined



Best Regards,
Andy Ee


View raw message