IntroductionWhen a CiviCRM site is upgraded to a new version, there are frequently changes to the structure of the database. This may include adding or dropping tables, columns, indexes and foreign keys. Generally, the SQL upgrade script provided with each new version does a decent job of modifying the existing database to match the new schema. However, there are occassionally issues during the upgrade which prevent a full implementation of the new schema. These issues generally show up as error messages or warnings during the upgrade. The procedures below are designed to reload the data into a new database which contains the exact schema needed to upgrade to the new release. We recommend you follow these steps if you've experienced any unexpected database errors or warning during an upgrade. We also recommend following these steps if your database as been through several version upgrades. After running these steps, you can be confident that your database schema matches the current production version exactly, with all indexes, foreign keys, defaults and other constraints. Procedure to rebuild schema for database versions 2.2.x or later
Browse through few civicrm pages to verify if civicrm is working fine along with all the custom data. Also make a few checks for e.g if number of contacts / custom-data are same in both the databases. Now the new database is ready for upgrade to next higher version. Procedure for 1.8 -> 1.9 upgradeThese procedures use upgrading from version 1.8 to 1.9 as an example - you should alter the database names and version references as needed for your situation. Upgrade a Copy of Your DatabaseIf you've already followed the verions upgrade procedures and upgraded your database, skip to the next section. Otherwise follow these steps first. (Complete version upgrade procedures can be found here). Open your CiviCRM settings file (drupal_root/sites/xxx/civicrm.settings.php) in your favorite editor and verify the following information:
Load Your Data into a Newly Built Database
|
Ensuring Schema Integrity on Upgrades
Labels
