Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 29th February 2008, 18:19
Cloud Cloud is offline
Junior Member
 
Join Date: Nov 2007
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Lightbulb Apache reverse proxy with mod_proxy and 302 redirection

Hi all,

I'm setting up a reverse proxy using apache and mod_proxy to redirect from one server to another (from A to B for example)
But in server B it has a redirect method that redirect with 302 code to another server (C)
The result is when I go to site A, the reverse proxy give me to access B, but the 302 redirection lead me to C, and showing C on the address bar
Do you have an idea to make reverse proxy work with this kind of redirection?

I tried with mod_rewrite to change my URL, but it seems to not working

Any idea/suggest would be really appreciated
Reply With Quote
Sponsored Links
  #2  
Old 1st March 2008, 09:16
topdog topdog is offline
Senior Member
 
Join Date: Jan 2008
Location: South Africa
Posts: 1,352
Thanks: 0
Thanked 153 Times in 150 Posts
Default

Why do you need to chain 3 servers, can you not do it in a more efficient way ?
__________________
----
http://www.topdog.za.net - Got Linux problems ? - I can help.
http://www.baruwa.org - Try it.
Reply With Quote
  #3  
Old 1st March 2008, 13:08
Cloud Cloud is offline
Junior Member
 
Join Date: Nov 2007
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Default

In my case, I have to do it with the 3 servers, and not to remove anything
Reply With Quote
  #4  
Old 1st March 2008, 14:10
topdog topdog is offline
Senior Member
 
Join Date: Jan 2008
Location: South Africa
Posts: 1,352
Thanks: 0
Thanked 153 Times in 150 Posts
Default

Instead of redirecting why dont you proxy from the second server as well.
__________________
----
http://www.topdog.za.net - Got Linux problems ? - I can help.
http://www.baruwa.org - Try it.
Reply With Quote
  #5  
Old 1st March 2008, 14:24
Cloud Cloud is offline
Junior Member
 
Join Date: Nov 2007
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Default

In this case, it's a little bit complex

Server B is behind the firewall and just allow access from server A, all it can do is redirect to C after checking for policy, etc.... that's why I ask for a reverse proxy with 302 redirection

I still want to do it, not another solution

Do you have any idea to implement this kind of reverse proxy?
Reply With Quote
  #6  
Old 1st March 2008, 14:28
topdog topdog is offline
Senior Member
 
Join Date: Jan 2008
Location: South Africa
Posts: 1,352
Thanks: 0
Thanked 153 Times in 150 Posts
Default

But the question is if the content is on server C why cann't server B just request it from server C and send it to server A

Internet <---> ServerA <-----> ServerB <------> ServerC
__________________
----
http://www.topdog.za.net - Got Linux problems ? - I can help.
http://www.baruwa.org - Try it.
Reply With Quote
  #7  
Old 1st March 2008, 14:55
Cloud Cloud is offline
Junior Member
 
Join Date: Nov 2007
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I can't make any changes on server B, that's the biggest problem
All I can do is on server A with the reverse proxy
Reply With Quote
Reply

Bookmarks

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

Forum Jump


All times are GMT +2. The time now is 01:30.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.