Tuesday 13 September 2011

Migration Log

After weeks of preparation, I am ready to migrate my site to the new host. I am logging each step taken so that in the event things go wrong, I can easily pin point the cause.

* Monitor your website traffic and choose a day where traffic is the lowest. Fortunately for me, Friday night is when my traffic is at the lowest and it is also at the end of my work week.

Friday, 9 September, 2011

2030 hrs
- Start of site migration.
- Create new cPanel account.
- Check that anonymous FTP is disabled.

2035
- Scan through the files in the old host to ensure no abnormally large files e.g. error_log
- Download files via cPanel backup manager.

2040
- took 5mins to download 185MB into tar.gz format
- Extract the files via winRAR but encountered error.
- Extract only the specific folder instead of all files and folders – successful.

2045
- create new mySQL database, user ID, password and assign full privilege to the database

2050
- Check .htaccess file.
- Change the path name because my old host use a sub domain.

2055
- Use Filezilla to upload all the files to my new host.
- Have to use root account because I have not updated my domain registrar to the new host name servers.

2215
- Filezilla uploaded completed. I heave a sign of relief as no files fail to be transferred over.
- Going to wait till 2300 to take the last mySQL backup

Saturday, 10 September, 2011

0031 hrs
- 1.5hrs overdue. Was preoccupied with other stuff. I did mention that Friday was my rest day ya.
- Exported the database in gzipped format.

0042
- Import SQL database

0054
- SQL error. Duplicate entry 502.
- Deleted, re-create and export the database but error still persist.
- I check through wp_posts and wp_comments and the number of records tally with that on the old host.
- The size of the database in the new host is larger than the old host.
- Decided to ignore the error.

0115
- Updated the name servers of my domain registrar to that of my new web hosts.
- Have to wait up to 48hrs.
- Ping my domain and still resolving to my old host IP.
- Going to bed and hopefully my site will be up when I wake up.

0600
- Ping my domain name and still resolving to my old host IP.

1020
- Ping now resolved to my new host IP. However, when I log in, it still showing the old WordPress version of my old host. Weird.
- It’s Saturday and I have a gathering later. Got to leave it till Sunday. Fortunately my site is still running.

Sunday, 11 September, 2011

0930 hrs
- Half awake hoping my site will work.
- Bam, internal server error 500.
- After some research, I think the problem lies with the permission of my .htaccess and/or probably all my files and folders.
- Was it my mistake to use root to upload my files as normal users/groups may not have the permission?
- It will take too much time to identify the permissions for each file.
- Good news that my domain registrar is resolving to my new host.
- I deleted the entire cPanel account and re-do from scratch. This time using my account (non-root) credentials since my domain has been resolved.

1300
- Finished all the steps but now it is pointing to cgi-default page. It can resolved to http://mydomain.com/. (with a dot at the end though).
- Raise a support ticket with my web host.

Monday, 12 September, 2011

0000 hrs
- Another day has passed and suddenly I can resolved to http://mydomain.com/ (without the dot). My web host did not reveal what the solution was and I was too tired to ask.
- Tested my site and found out the site is loading very slowly with insufficient memory allocation.

0030
- Updated php.ini to allow 500MB memory and restarted Apache service.
- Basic test OK.
- Email to support to install two missing PHP modules required for one of my application.
-  Finally going to get some sleep and do a full test later.
0900
- Internal Server Error again!
- I tried uploading an empty htaccess file but the error persist. How can it suddenly go down when it was working earlier?
- Has my site been hacked? Even my test domain is facing the same problem.
- Log a ticket with support. Hope it can be resolve quickly.

Update on 14 September 2011
- Internal server error solved.
- According to support, the internal server error was caused by php memory being set to 'maximum'. They have changed it to 256MB.
- Still facing several problems but at least normal viewing of the site is fine.

No comments:

Post a Comment