Aakash
Aakash

Reputation: 3171

Moving MySQL DB tables/data and web services from GoDaddy to Amazon Web Services

Here is the situation and I could use some help.

Currently I have a shared hosting domain with GoDaddy that has one MySQL DB and multiple web services that connect to the database when connected from a live Android App.

Godaddy gives 1GB for one single database to grow to on shared hosting and I have checked with them that they will not be able to increase that even with extra money. On moving to a dedicated server on GoDaddy they will have a new database connect string and password for me.

I am thinking of moving the database and web services to Amazon Web Services for long term scalability (which I should have thought about before).

Is there a way I can do this seamlessly so that the users of the Android App are not affected?

Here is the flow right now-

App pings -> PHPs (with specified DB connect strings to Godaddy DB) -> read write to DB on Godaddy and send response back to Android App Users.

Once I move everything the path to HTTPPost in the App will change and also the DB Connect Strings in the PHPs will change...so how can I achieve this seamlessly.

Thanks for sharing your experience and knowledge. Any help is very much appreciated.

Upvotes: 0

Views: 879

Answers (1)

dmcnelis
dmcnelis

Reputation: 2923

Once you have your Amazon server set up and working you should be able to mysqldump your database from go-daddy and then re-import it on amazon. It will take a little bit of time (from a few minutes to significantly longer, depending on the amount of data you're moving / file transfer speeds).

But once you have your database up on Amazon, you should be able to update your php code and be off to the races.

You can run some tests to see how long the migration takes, and then plan your application outage accordingly. But unless you set up replication between the two servers you might end up with not-up-to-date data.

Then, once you're ready to flip the switch, update your connection class to point to the new server location.

Upvotes: 1

Related Questions