View Single Post
Old 05-26-2008, 12:03 AM   · #2
qbert220
NamePros Member
 
qbert220's Avatar
 
Location: UK
Trader Rating: (24)
Join Date: Jul 2007
Posts: 137
NP$: 205.00 (Donate)
qbert220 is a jewel in the roughqbert220 is a jewel in the roughqbert220 is a jewel in the roughqbert220 is a jewel in the rough
Yes - you can do this without downtime.

First, you need to get your new hosting account setup. Use the control panel to create your subdomains, then add all of your content to it using FTP and the IP address of the server.

You may be able to test your new site using a preview URL (e.g. if it is a cPanel server http://12.123.123.123/~username - replace with the IP address of the server and your cPanel username). Ask your new web host if they provide a preview. Previewing does not always work correctly though since URLs are different than when you visit the site directly. For instance a <a href="/"> link will reference the wrong page.

You may be alse to preview subdomains using the subdomain directory like this:

http://123.123.123.123/~username/subdir

If your new host does not offer a preview (or if they do but it does not work correctly), then you can do it yourself by modifying your local hosts file. I'm assuming you're using windows. Open the folder c:\windows\system32\drivers\etc. Look for a file called hosts. If there is one, open it in a text editor (e.g. notepad). If not, then create it. NOTE there is no dot in the file name!

Now add the following line to your hosts file:

Code:
123.123.123.123 www.yourdomain.com 123.123.123.123 subdomain.yourdomain.com


Replace with the new servers IP address and your domain name and subdomains. You should have 1 line for each subdomain you want to test.

Now open your web site in your web browser and you should see the new site.

No one else can see the new server yet - they are still seeing the old server. Now it is time to start using the new server, so we need to chaneg the nameservers for your domain. Change them to the ones your new host has provided. There will be some delay between you making this change and all visitors seeing your new site - usually a few hours. This is bacause the old DNS entries are cached. If your site is static HTML this is not a problem. If you use databases then someone could update the database on the old server and then the change gets lost when the new DNS kicks in. To minimise this you could ask your old host to reduce the TTL and EXPIRE value on your DNS entries to 300. This is a dead giveaway that you are leaving them, so they may not be too happy about doing it! You then need to wait for the old TTL period (a day should do) before copying databases and changing the nameservers over.

Keep the old hosting account active for at least a day, preferably 2 after changing the nameservers to catch any DNS update stragglers.

If you modified your hosts file, don't forget to remove the changes a day after changing the nameservers.


Please register or log-in into NamePros to hide ads
__________________
DNSsy.com - DNS Test and Check
qbert220 is offline   Reply With Quote
Site Sponsors
Buy Flash Arcade Game Script Proof is in the Parking RealTechNetwork
Advertise your business at NamePros
All times are GMT -7. The time now is 04:46 PM.


Powered by: vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.