Problem with reverse proxy
11 posts
• Page 1 of 1
Problem with reverse proxy
Hi
We have isapi rewrite 3 on our system.
Now we need to configure a reverse proxy in order to call a virtual dir in
iis and proxy to an internal server on 8080 port where is Tomcat.
I read different examples on forum, for example:
RewriteEngine on
RewriteBase /
RewriteRule ^myApp/(.+)$ http://internalIpAddress:8080/myApp/$1 [NC,P]
or
ProxyPass /myApp/ http://internalIpAddress:8080/myApp/
ProxyPassReverse / myApp / http://internalIpAddress:8080/myApp/
but nothing works
I simply installed ISAPI_Rewrite.dll and ISAPI_RewriteProxy.dll on IIS
Is there any other things to configure in order to enable reverse proxy? In Apache Webserver I usually load mod_proxy module to enable reverseproxy. Here is the same? If yes, where can I load that module? If not, which is the right solution to do that?
Thanks
We have isapi rewrite 3 on our system.
Now we need to configure a reverse proxy in order to call a virtual dir in
iis and proxy to an internal server on 8080 port where is Tomcat.
I read different examples on forum, for example:
RewriteEngine on
RewriteBase /
RewriteRule ^myApp/(.+)$ http://internalIpAddress:8080/myApp/$1 [NC,P]
or
ProxyPass /myApp/ http://internalIpAddress:8080/myApp/
ProxyPassReverse / myApp / http://internalIpAddress:8080/myApp/
but nothing works
I simply installed ISAPI_Rewrite.dll and ISAPI_RewriteProxy.dll on IIS
Is there any other things to configure in order to enable reverse proxy? In Apache Webserver I usually load mod_proxy module to enable reverseproxy. Here is the same? If yes, where can I load that module? If not, which is the right solution to do that?
Thanks
Re: Problem with reverse proxy
Hello,
If it's ISAPI_Rewrite 3 you are using, then the rule should be like:
RewriteEngine on
RewriteBase /
RewriteRule ^myApp/(.+)$ http://internalIpAddress:8080/myApp/$1 [NC,P]
Can you specify the URL you request and the internal URL that needs to be pulled from Tomcat.
"I simply installed ISAPI_Rewrite.dll and ISAPI_RewriteProxy.dll on IIS"
- did you install ISAPI_Rewrite manually or used automatic installation?
If it's ISAPI_Rewrite 3 you are using, then the rule should be like:
RewriteEngine on
RewriteBase /
RewriteRule ^myApp/(.+)$ http://internalIpAddress:8080/myApp/$1 [NC,P]
Can you specify the URL you request and the internal URL that needs to be pulled from Tomcat.
"I simply installed ISAPI_Rewrite.dll and ISAPI_RewriteProxy.dll on IIS"
- did you install ISAPI_Rewrite manually or used automatic installation?
Re: Problem with reverse proxy
thanks for your reply.
I put those instructions and this is what I see inside rewrite.log:
init rewrite engine with requested uri /myApp/index.html
Htaccess process request C:\Program Files\Helicon\ISAPI_Rewrite3\httpd.conf
Htaccess process request d:\www\.htaccess
applying pattern '^myApp/(.+)$' to uri 'myApp/index.html'
forcing proxy-throughput with http://internalIp:8080/myApp/index.html
go-ahead with proxy request http://internalIp:8080/myApp/index.html [OK]
Rewrite URL to >> /myApp/index.htmlx.rwhlp?p=0
rewrite 'myApp/index.html' -> '/myApp/index.htmlx.rwhlp?p=0'
internal redirect with /myApp/index.htmlx.rwhlp?p=0 [INTERNAL REDIRECT]
I read that ".rwhlp?p=0" doesn't affect proxy. I have dll installed only on website. I added it manually in IIS isapi filters
It seems that the internal webapp is ok, but then i got a IIS error 404 with these info:
Requested URL: http://mysite/myApp/index.htmlx.rwhlp?p=0
Physycal path: D:\www\myApp\index.htmlx.rwhlp
Thanks for your help
I put those instructions and this is what I see inside rewrite.log:
init rewrite engine with requested uri /myApp/index.html
Htaccess process request C:\Program Files\Helicon\ISAPI_Rewrite3\httpd.conf
Htaccess process request d:\www\.htaccess
applying pattern '^myApp/(.+)$' to uri 'myApp/index.html'
forcing proxy-throughput with http://internalIp:8080/myApp/index.html
go-ahead with proxy request http://internalIp:8080/myApp/index.html [OK]
Rewrite URL to >> /myApp/index.htmlx.rwhlp?p=0
rewrite 'myApp/index.html' -> '/myApp/index.htmlx.rwhlp?p=0'
internal redirect with /myApp/index.htmlx.rwhlp?p=0 [INTERNAL REDIRECT]
I read that ".rwhlp?p=0" doesn't affect proxy. I have dll installed only on website. I added it manually in IIS isapi filters
It seems that the internal webapp is ok, but then i got a IIS error 404 with these info:
Requested URL: http://mysite/myApp/index.htmlx.rwhlp?p=0
Physycal path: D:\www\myApp\index.htmlx.rwhlp
Thanks for your help
Re: Problem with reverse proxy
Hello,
"I read that ".rwhlp?p=0" doesn't affect proxy. I have dll installed only on website. I added it manually in IIS isapi filters"
- please clarify: you have performed automatic installation of ISAPI_Rewrite and then registered ISAPI_Rewrite dlls manually for the site?
If yes, then please remove the dlls from the site setting as ISAPI_Rewrite automatically registers the dlls globally and there's no need to additionally do that.
"I read that ".rwhlp?p=0" doesn't affect proxy. I have dll installed only on website. I added it manually in IIS isapi filters"
- please clarify: you have performed automatic installation of ISAPI_Rewrite and then registered ISAPI_Rewrite dlls manually for the site?
If yes, then please remove the dlls from the site setting as ISAPI_Rewrite automatically registers the dlls globally and there's no need to additionally do that.
Re: Problem with reverse proxy
I suppose the first installation was automatic (another person did that before me). But I removed the dll from iis node, so there is only one dll defined for my site now. I removed all occurrency of isapi dll from iss and then added it manually to my site node
Thanks
Thanks
Re: Problem with reverse proxy
Hello,
It seems that handler for *.rwhlp file extension is not registered. Please set ISAPI_RewriteProxy.dll as ISAPI extension to handle it.
It seems that handler for *.rwhlp file extension is not registered. Please set ISAPI_RewriteProxy.dll as ISAPI extension to handle it.
Re: Problem with reverse proxy
Now I added also ISAPI_RewriteProxy_x64.dll in IIS isapi filters. Now every url gives error 500 (I try to translate error from italian):
Impossible to call GetProcAddress on ISAPI filter "C:\Program Files\Helicon\ISAPI_Rewrite3\ISAPI_RewriteProxy_x64.dll"
Thanks
Impossible to call GetProcAddress on ISAPI filter "C:\Program Files\Helicon\ISAPI_Rewrite3\ISAPI_RewriteProxy_x64.dll"
Thanks
Re: Problem with reverse proxy
I noticed that nowhere inside IIS "Mapping Gestori" (I think is "handler mapping" in english) I have something for *.rwhlp files
I added script mapping with request path: *.rwhlp and executable pointing to ISAPI_RewriteProxy_x64
Bu I get always the same error. I think there is something missing in IIS configuration
Thanks
I added script mapping with request path: *.rwhlp and executable pointing to ISAPI_RewriteProxy_x64
Bu I get always the same error. I think there is something missing in IIS configuration
Thanks
Re: Problem with reverse proxy
Hello,
"Impossible to call GetProcAddress on ISAPI filter "C:\Program Files\Helicon\ISAPI_Rewrite3\ISAPI_RewriteProxy_x64.dll""
- this error indicated that you have registered filter to handle .rwhlp extension not handler. Please fix it.
"Impossible to call GetProcAddress on ISAPI filter "C:\Program Files\Helicon\ISAPI_Rewrite3\ISAPI_RewriteProxy_x64.dll""
- this error indicated that you have registered filter to handle .rwhlp extension not handler. Please fix it.
11 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 0 guests