This is a discussion on How to Re-direct to a Different Web Server within the Apache Web Server forums, part of the Web Server and Related Forums category; Hi there, I have a existing Apache web server for my company www.company.com with the IP of 100....
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Hi there,
I have a existing Apache web server for my company www.company.com with the IP of 100.100.100.100. Now, I am planning to move it from an ISP to another, so it's IP address has to be changed, and it would be 200.200.200.200. To zero the downtime, I'd like to set up a new server at the new ISP with the new IP, and keep the old server at the current ISP for a while and forward its access to http://200.200.200.200. The question is how to set up the forwarding/redirection on the current Apache, and it won't change the address in the browser's address field? Thanks a lot in advance, Ross |
|
|||
|
Ross wrote:
> Hi there, > I have a existing Apache web server for my company www.company.com with the > IP of 100.100.100.100. > Now, I am planning to move it from an ISP to another, so it's IP address has > to be changed, and it would be 200.200.200.200. > To zero the downtime, I'd like to set up a new server at the new ISP with > the new IP, and keep the old server at the current ISP for a while and > forward its access to http://200.200.200.200. > The question is how to set up the forwarding/redirection on the current > Apache, and it won't change the address in the browser's address field? > Thanks a lot in advance, I think to not change the address, you'd need some tricky RewriteEngine rule. Why not change the address? -- Paul Furman Photography http://www.edgehill.net/1 Bay Natives Nursery http://www.baynatives.com |
|
|||
|
Paul Furman wrote:
> Ross wrote: > >> Hi there, >> I have a existing Apache web server for my company www.company.com >> with the IP of 100.100.100.100. >> Now, I am planning to move it from an ISP to another, so it's IP >> address has to be changed, and it would be 200.200.200.200. >> To zero the downtime, I'd like to set up a new server at the new ISP >> with the new IP, and keep the old server at the current ISP for a >> while and forward its access to http://200.200.200.200. >> The question is how to set up the forwarding/redirection on the >> current Apache, and it won't change the address in the browser's >> address field? >> Thanks a lot in advance, > > I think to not change the address, you'd need some tricky RewriteEngine > rule. Why not change the address? > Either that or use iframes or something like that. I can only assume he wants to not change the IP to minimise clients not being able to view the site due to DNS caching. You could always just leave both servers running for a bit... -- DM davidm@cia.com.au The funny .sig is in the wash, I am your replacement. |
|
|||
|
hi Ross:
Ross wrote: > I have a existing Apache web server for my company www.company.com with the > IP of 100.100.100.100. > Now, I am planning to move it from an ISP to another, so it's IP address has > to be changed, and it would be 200.200.200.200. > To zero the downtime, I'd like to set up a new server at the new ISP with > the new IP, and keep the old server at the current ISP for a while and > forward its access to http://200.200.200.200. > The question is how to set up the forwarding/redirection on the current > Apache, and it won't change the address in the browser's address field? if i understand what you're asking, success depends as much on what you do with your DNS configuration as your apache setup. to switch from ISP.old to ISP.new with a minimum of disruption, try this: 1. reduce the dns refresh time on the company.com zone and ttl on the www.company.com resource record to 5 minutes. if your existing ttl/refresh is 8 hours, you need to do this at least 8 hours before the move. i would do it well in advance so that you don't have to worry about it. 2. prepare your website at ISP.new and configure apache to recognize and accept traffic for www.company.com 3. once the DNS ttl has propagated (hours or days after you've set it to 5 minutes), change the IP address of www.company.com in DNS from ISP.old to ISP.new. most traffic will switch and start landing at ISP.new within 5 minutes. 4. you can now safely assume that traffic arriving at ISP.old is ignoring DNS. after examining the nature of the traffic, you can drop it altogether (just turn off the old server if the traffic looks like robot noise), or if the remaining traffic looks legitimate, you can set the apache at ISP.old to redirect any/all traffic to ISP.new. in httpd.conf at ISP.old: RedirectMatch permanent ^/(.*)$ http://www.company.com/$1 which would hopefully force clients who have cached your IP to do a fresh lookup. if you really want to keep all of your bot traffic and whatever else is not properly respecting your DNS entry, you can redirect any/all traffic to the IP of your machine at ISP.new, like this: RedirectMatch permanent ^/(.*)$ http://200.200.200.200/$1 i doubt this will net you any human traffic of value, it will just increase robot noise on your new server. 5. restore your dns refresh/ttl to a more reasonable duration, allowing clients to cache your zone information for hours or days. --sean -- sean dreilinger - http://durak.org/sean/ |
|
|||
|
Thanks a lot, Sean!
That's what I want. Cheers, Ross "sean dreilinger" <sean-usenet@durak.org> wrote in message news:46A3A591.8070706@durak.org... > hi Ross: > > Ross wrote: >> I have a existing Apache web server for my company www.company.com with >> the IP of 100.100.100.100. >> Now, I am planning to move it from an ISP to another, so it's IP address >> has to be changed, and it would be 200.200.200.200. >> To zero the downtime, I'd like to set up a new server at the new ISP with >> the new IP, and keep the old server at the current ISP for a while and >> forward its access to http://200.200.200.200. >> The question is how to set up the forwarding/redirection on the current >> Apache, and it won't change the address in the browser's address field? > > if i understand what you're asking, success depends as much on what you do > with your DNS configuration as your apache setup. to switch from ISP.old > to ISP.new with a minimum of disruption, try this: > > 1. reduce the dns refresh time on the company.com zone and ttl on the > www.company.com resource record to 5 minutes. if your existing ttl/refresh > is 8 hours, you need to do this at least 8 hours before the move. i would > do it well in advance so that you don't have to worry about it. > > 2. prepare your website at ISP.new and configure apache to recognize and > accept traffic for www.company.com > > 3. once the DNS ttl has propagated (hours or days after you've set it to 5 > minutes), change the IP address of www.company.com in DNS from ISP.old to > ISP.new. most traffic will switch and start landing at ISP.new within 5 > minutes. > > 4. you can now safely assume that traffic arriving at ISP.old is ignoring > DNS. after examining the nature of the traffic, you can drop it altogether > (just turn off the old server if the traffic looks like robot noise), or > if the remaining traffic looks legitimate, you can set the apache at > ISP.old to redirect any/all traffic to ISP.new. in httpd.conf at ISP.old: > > RedirectMatch permanent ^/(.*)$ http://www.company.com/$1 > > which would hopefully force clients who have cached your IP to do a fresh > lookup. if you really want to keep all of your bot traffic and whatever > else is not properly respecting your DNS entry, you can redirect any/all > traffic to the IP of your machine at ISP.new, like this: > > RedirectMatch permanent ^/(.*)$ http://200.200.200.200/$1 > > i doubt this will net you any human traffic of value, it will just > increase robot noise on your new server. > > 5. restore your dns refresh/ttl to a more reasonable duration, allowing > clients to cache your zone information for hours or days. > > --sean > > -- > sean dreilinger - http://durak.org/sean/ |
| Thread Tools | |
| Display Modes | |
|
|