Results 1 to 8 of 8
Hello, i have an CentOS (Redhat) Linux server and on it is installed OpenVZ which allows creating virtual machines there. Now to my CentOS host server is pointed a few ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 02-19-2014 #1
How to redirect an IP to a new IP
i have an CentOS (Redhat) Linux server and on it is installed OpenVZ which allows creating virtual machines there.
Now to my CentOS host server is pointed a few IP-RIPE addresses, these IPs are mentioned in several domains nameservers, i want to migrate virtual machines to another server and my question is how i can achieve that websites which domains pointing to old server will resolve and work and load from a new server? (meaning there will be redirection on server which redirect old ip request to a new IP of new server) If it would be possible, redirecting all kind of requests, but for simplicity, HTTP most important
- 02-19-2014 #2
My suggestion is to update the dns zone files.You must always face the curtain with a bow.
- 02-19-2014 #3
and replaced IPs there by new IPs, but the website still loading OK, i even added some random IP..
- 02-19-2014 #4
Assuming the new server also has a public IP, the workflow would be:
- configure the new webserver and possibly other daemons (ntp, rsyslog, db, mail, etc)
- copy/import/migrate data from the old machine
- test the new services and content via IP or better via staging hostnames
- lower the ttl of the dns zones containing the records of your old server
- Modify the records to point to the new server
Sent from my GT-I9505 using TapatalkYou must always face the curtain with a bow.
- 02-19-2014 #5
- 02-20-2014 #6
It depends whether you maintain the DNServers yourself or if you use the ones of your domain registrar.
If the dns is with the domain registrar, then there will be a way for customers to change their own zones. e.g. via a web gui.
If you host your own dns, then you can edit the zone files there.You must always face the curtain with a bow.
- 02-20-2014 #7
- 02-20-2014 #8
If both servers have the same content, and the new server has been tested, then there will be no downtime via the dns method.
There will be a timeframe, where browsers still get the old IP and therefore hit the old server. This is why I said to lower the ttl.
After the ttl has passed and you see no more requests on the old webserver, you can then shutdown/decomission the old machine.
Even if you redirect the requests from the old machine to the new via iptables, then you *still* have to do the changes in the dns zones.
Otherwise, the old machine stays a dependency to the service and adds complexity and is a SPOF.You must always face the curtain with a bow.