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 / apache 2.4
Author
ballexaa



Joined: 12 Nov 2015
Posts: 7

PostPosted: Thu 12 Nov '15 11:00    Post subject: reverse proxy / apache 2.4 Reply with quote

Hi,

I'm bothering with an reverseproxy dilema:

I have following arhitecture:


Apache1 2.4 -> WLS 12
|->Apache2 2.4-> GF3

Apache1 directs /AAA to WLS 12 and /aaa to Aapche2 -> GF3.

Unix/Java

I set ProxyPass and ProxyPassReverse



<proxypass url="https://server-url/aaa/" path="/aaa/"/>



<proxypassreverse url="https://server-url/aaa/" path="/aaa/"/>



but it doesn't work only with those configs.

What else do i need to configure? Do you know any arhitecture+configs docs/tools?


Thank you in advance!
Back to top
Steffen
Moderator


Joined: 15 Oct 2005
Posts: 3092
Location: Hilversum, NL, EU

PostPosted: Thu 12 Nov '15 11:25    Post subject: Reply with quote

See http://httpd.apache.org/docs/2.2/mod/mod_proxy.html#proxypass


You have "url=..."and "path=..", that are no options in the above docu.
Back to top
ballexaa



Joined: 12 Nov 2015
Posts: 7

PostPosted: Thu 12 Nov '15 12:04    Post subject: it's right Reply with quote

No, they are fine, i am not modifying the httpd.conf directly, i use this staging concept, where i complete one xml file and the httpd.conf file is automatically generated. In httpd.conf file looks right:

ProxyPass /aaa/ https://server-url/aaa/

ProxyPassReverse /aaa/ https://server-url/aaa/
Back to top
Steffen
Moderator


Joined: 15 Oct 2005
Posts: 3092
Location: Hilversum, NL, EU

PostPosted: Thu 12 Nov '15 12:22    Post subject: Reply with quote

You wrote:

but it doesn't work only with those configs.

Do not understand.

What happens ?
Back to top
ballexaa



Joined: 12 Nov 2015
Posts: 7

PostPosted: Thu 12 Nov '15 13:09    Post subject: Reply with quote

When i open the window (that should call Apache2-> GF server) i get 'This project didn't deploy yet', but there is no issue on this apache2-> gf part, because this part is also used by other apaches 2.0.

I tried a trick: i put the reverse the other way back:

ProxyPassReverse https://server-url/aaa/ /aaa/

If i already have the /AAA application opened in the browser+F5 -> /aaa also opens and works fine.
But if i wish to open /AAA appl in a new IE window, i get HTTP 404 Not found (after login).

I think the reverse it's correctly configured (ProxyPassReverse /aaa/ https://server-url/aaa/ ) but i don't figure out what other forwarding rules/missing configs can cause this issue.
Back to top
James Blond
Moderator


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

PostPosted: Thu 12 Nov '15 18:53    Post subject: Reply with quote

Change your config to ( aka remove the slash at the end)
Code:

ProxyPass /aaa https://server-url/aaa
ProxyPassReverse /aaa https://server-url/aaa
Back to top
ballexaa



Joined: 12 Nov 2015
Posts: 7

PostPosted: Thu 12 Nov '15 18:59    Post subject: Reply with quote

No Change...

I also get this error in the logs:

Error during SSL Handshake with remote server

and

pass request body failed
Back to top
James Blond
Moderator


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

PostPosted: Thu 12 Nov '15 19:01    Post subject: Reply with quote

Then you may try adding the following

Code:

SSLProxyEngine on
SSLProxyVerify none
SSLProxyCheckPeerCN off
SSLProxyCheckPeerName off
SSLProxyCheckPeerExpire off
Back to top
ballexaa



Joined: 12 Nov 2015
Posts: 7

PostPosted: Thu 12 Nov '15 19:11    Post subject: Reply with quote

still doesn't solve the reverse...it's not firewall, it's not certificate... i don't know what it is
Back to top
James Blond
Moderator


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

PostPosted: Thu 12 Nov '15 19:16    Post subject: Reply with quote

ballexaa wrote:

it's not firewall, it's not certificate


The following indicates that it can't connect over ssl.

ballexaa wrote:


Error during SSL Handshake with remote server


Does the backend service really provide SSL?

if you are logged on the computer on that apache is installed on can you open in the browser https://server-url/aaa/ ??
Back to top
ballexaa



Joined: 12 Nov 2015
Posts: 7

PostPosted: Tue 17 Nov '15 11:09    Post subject: Reply with quote

By login in /AAA gets overwriten with /aaa:

302 HTTPS /AAA/webdesign/login.jsp
404 HTTPS /aaa/webdesign/home.jsp ->which does not exist

or 502 HTTPS /aaa/webdesign/home.jsp
Back to top
jraute



Joined: 13 Sep 2013
Posts: 188
Location: Rheinland, Germany

PostPosted: Tue 17 Nov '15 13:35    Post subject: Reply with quote

Pls post your config.
The complete vhost-section and what kind of modules you are using...

Thanks!
Back to top
ballexaa



Joined: 12 Nov 2015
Posts: 7

PostPosted: Tue 17 Nov '15 16:31    Post subject: Reply with quote

mod note: moved config to: http://pastebin.com/Bbxf2F2K
Back to top
jraute



Joined: 13 Sep 2013
Posts: 188
Location: Rheinland, Germany

PostPosted: Wed 18 Nov '15 13:10    Post subject: Reply with quote

First of all with your configuration you are proxying not reverseproxying!

For reverseproxying there's an entry missing: ProxyRequests Off
https://httpd.apache.org/docs/2.4/mod/mod_proxy.html#proxyrequests

And then i would place it in a vhost section.
Back to top


Reply to topic   Topic: reverse proxy / apache 2.4 View previous topic :: View next topic
Post new topic   Forum Index -> Apache