Ben's recommendations for upgrading
Posted: Thu 24. Feb 2005, 05:52
I recently upgraded a site from DEV 1.1.9 to DEV 1.2.1 and it occurred flawlessly! I sometimes read of people having unrecoverable issues when upgrading, so I thought I'd offer my 2 cents.
Aside from backing up all of the files and database, I would recommend the following as a fail-safe upgrade method that will leave your old installation intact while also allowing you to upgrade. It's not rocket surgery, just common sense.
1. Copy all files and database from the original version to your local PC.
2. Upload all files for the new version that you are going to upgrade to a subfolder, such as /upgrade
3. Create a new database and call it something like wcms121 and add a user, etc.
4. Upload the mySQL dump from your old installation to the new database.
5. Copy up the files from the old version's /phpwcms_filestorage to /upgrade/phpcms_filestorage.
6. Copy up any other layout images that you may have, as well as files from /picture
7. Go to http://www.domain.com/upgrade/setup/setup.php and run the installation script, but be careful not to create the database tables. You just want to create config.inc.php file and set folder permissions. NOTE: don't forget to connect to the new database, not the old. After you're done, upload the conf.inc.php file to the new installation.
8. Go to http://www.domain.com/upgrade/setup/setup.php and click the link to upgrade your installation.
9. Carefully follow the provided instructions.
10. If your upgrade attempts fail, it is of no consequence because your original installation was not touched.
11. If your upgrade attempts are successful, you may want to move the old installation into a /old folder and move the upgraded installation into the root. You'll just need to change the appropriate variables in conf.inc.php to keep it all running.
12. You'll probably want to go through frontend.css and conf.template_default.inc.php by hand to add in any changes made to the old version's styles.
What's nice about this upgrade path is that if you need to log into the old installation to grab a template or something that didn't work out in the upgrade, you can easily do it. Hopefully my instructions have been clear and will help someone.
Aside from backing up all of the files and database, I would recommend the following as a fail-safe upgrade method that will leave your old installation intact while also allowing you to upgrade. It's not rocket surgery, just common sense.
1. Copy all files and database from the original version to your local PC.
2. Upload all files for the new version that you are going to upgrade to a subfolder, such as /upgrade
3. Create a new database and call it something like wcms121 and add a user, etc.
4. Upload the mySQL dump from your old installation to the new database.
5. Copy up the files from the old version's /phpwcms_filestorage to /upgrade/phpcms_filestorage.
6. Copy up any other layout images that you may have, as well as files from /picture
7. Go to http://www.domain.com/upgrade/setup/setup.php and run the installation script, but be careful not to create the database tables. You just want to create config.inc.php file and set folder permissions. NOTE: don't forget to connect to the new database, not the old. After you're done, upload the conf.inc.php file to the new installation.
8. Go to http://www.domain.com/upgrade/setup/setup.php and click the link to upgrade your installation.
9. Carefully follow the provided instructions.
10. If your upgrade attempts fail, it is of no consequence because your original installation was not touched.
11. If your upgrade attempts are successful, you may want to move the old installation into a /old folder and move the upgraded installation into the root. You'll just need to change the appropriate variables in conf.inc.php to keep it all running.
12. You'll probably want to go through frontend.css and conf.template_default.inc.php by hand to add in any changes made to the old version's styles.
What's nice about this upgrade path is that if you need to log into the old installation to grab a template or something that didn't work out in the upgrade, you can easily do it. Hopefully my instructions have been clear and will help someone.