logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Apache View previous topic :: View next topic
Reply to topic   Topic: reverse proxy URL problem
Author
stefanwilling



Joined: 13 Dec 2007
Posts: 2

PostPosted: Thu 13 Dec '07 12:09    Post subject: reverse proxy URL problem Reply with quote

Hi there,
I'm using Apache 2.2 with the mod_proxy module to allow the access to an application server from outside the local network.

http://reverseproxy/app/ is proxied to http://appserver/app

I'm running an ASP.NET project on the server. Everything works fine expect from one thing:
When a link inside a GriedView component is clicked, a new page should be loaded, but I get a 404 error. Let me give an example:

The user clicks on the Link inside the GridView and the page http://reverseproxy/app/production/dialog.aspx should be opened,
but the browser URL after that is http://app/production/dialog.aspx.

I can see, that the apache server is looking for the file in its local htdocs folder, inside the access log.

Can someone help me with this problem? Is the reverse-proxy configured correctly?

best regards,

Stefan
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7373
Location: Germany, Next to Hamburg

PostPosted: Thu 13 Dec '07 12:50    Post subject: Reply with quote

Du you use mod_proxy_html to fix your html links?
Back to top
stefanwilling



Joined: 13 Dec 2007
Posts: 2

PostPosted: Fri 14 Dec '07 10:35    Post subject: Reply with quote

Hi James,

yes, I use mod_proxy_html to fix the links.

Here is the part of my httpd.conf for the proxy configuration:
Code:


ProxyRequests Off
ProxyHTMLExtended Off
ProxyHTMLLogVerbose On

ProxyPass /app1/ http://192.168.100.20/
ProxyHTMLURLMap http://192.168.100.20 /app1

<Location /app1/ >
   ProxyPassReverse /
   ProxyHTMLDoctype html
   SetOutputFilter proxy-html
   ProxyHTMLURLMap / /app1/
   ProxyHTMLURLMap /app1 /app1
   RequestHeader unset Accept-Encoding
</Location>


Does the correction of HTML-Links not work correctyl?

Thanks for your help,

Stefan
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7373
Location: Germany, Next to Hamburg

PostPosted: Fri 14 Dec '07 11:37    Post subject: Reply with quote

I'm not deep into mod_proxy_html but from the tutorial I have a on more line

from
Code:

ProxyPass /app1/ http://192.168.100.20/
ProxyHTMLURLMap http://192.168.100.20 /app1


to
Code:

ProxyPass /app1/ http://192.168.100.20/
ProxyPassReverse /app1 http://192.168.0.8/
ProxyHTMLURLMap http://192.168.100.20 /app1


With that you can try. For me it works. I'm not sure if that "makes" the difference.
Back to top


Reply to topic   Topic: reverse proxy URL problem View previous topic :: View next topic
Post new topic   Forum Index -> Apache