Link to home
Start Free TrialLog in
Avatar of -pH
-pH

asked on

site migration

anybody have experience with host, dns, live database migration best practice?

what i am trying to accomplish is to migrate my site that has a live db running that can only be down for a very minimal amount of time to a more dependable host (domain.com is horrible btw).

what i am thinking so far, get the site replicated to the new host sans db > update A records to the new host > when we hit our maintenance window, lock and move the db > change name servers > pray.

anybody a lot better than me on this want to chime in, i usually end up with a bit of down time and really cant afford to go past my window.
Avatar of johanntagle
johanntagle
Flag of Philippines image

I guess your on a shared host, but just in case you're not and have full control of the database then look into mysql master-slave replication or just updating the new database using the binary logs.  With master-slave replication you can have the database on the new host updated shortly after the last change on the previous one.  The next best thing is using the binary logs so you only need to replicate the changes since the time you backed up the database and restored to the new host.

Other than that the only thing I can think of at the moment is to check the time to live (TTL) settings on your current DNS server.  I believe this is usually set to half an hour.  If so, at least half an hour before your maintenance window, set it to maybe 5 minutes.  So that when you change the DNS records, those who access the site just before the maintenance window will have your address expire in their cache and will get the updated record within 5 minutes after you make the change.
Avatar of -pH
-pH

ASKER

unfortunately we are on a shared host and migrating to a vps. is there still a way to configure a master-slave db setup?
ASKER CERTIFIED SOLUTION
Avatar of johanntagle
johanntagle
Flag of Philippines image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial