Upgrade from Tripal v2.0 to v2.1

 

Step 1:  Backup your Site

Before proceeding with the upgade please review the site backup instructions to ensure you can restore your site if the upgrade fails.

Step 2: Upgrade Tripal

  1. Place the site into maintenance mode.  This way visitors to the site will receive a message that the site is currently under maintenance.  You can easily do this with the following drush command:

    drush vset site_offline 1
    
  2. The following command will retrieve the Tripal 2.1 version:
    drush pm-download tripal-7.x-2.1
  3. Next, apply the Tripal updates:
    drush updatedb
  4. Execute the jobs that were added by the ugprade
    drush trp-run-jobs --username=administrator
  5. Re-enable your site:
    drush vset site_offline 0
  6. Upgrade is now complete!

Step 3:  Upgrade Extension Modules

In Concert with the release of Tripal v2.1 some of the functional annotation have also been released.   If you use the Tripal Blast Analysis, Tripal InterPro Analysis, Tripal KEGG Analysis or Tripal GO Analysis modules please consider upgrading those.  They can upgrade in the same way as any other Drupal module by using the following two commands:

drush pm-update
durhs updatedb

Note, the two steps above will upgrade all other 3rd party modules as well.

Step 4: (Optional) Upgrade Chado

Tripal v2.1 provides support for Chado v1.3.  It is not necessary to upgrade Chado as Tripal v2.1 supports both Chado v1.2 and v1.3.  But Chado v1.3 offers new tables and larger table sizes.  Before proceeding please review the following issues that you may encounter:

  • PostgreSQL version 9.1 is required to perform this upgrade. If your Tripal site uses an older version of PostgreSQL please upgrade before proceeding.
  • A major change between Chado v1.2 and v1.3 is that primary and foreign keys were upgraded from integers to big integers. If your site has custom materialized views that will hold data derived from fields then you may need to alter the views to change the fields from integers to big integers and repopulate those views. If you have not added any materialized views you can ignore this issue.
  • Custom PL/pgSQL functions that expect primary and foreign key fields to be integers will not work after the upgrade. Those functions will need to be altered to accept big integers. If you do not have any custom PL/pgSQL functions you can ignore this issue.
  • PostgreSQL Views that use fields that are converted to big integers will cause this upgrade to fail. You must first remove those views, perform the upgrade and then recreate them with the appropriate fields change to big integers. If you do not have custom PostgreSQL Views you can ignore this issue.
  • Several new tables were added to Chado v1.3. However, some groups have added these tables to their Chado v1.2 installation. The Tripal upgrader will alter the primary and foreign keys of those tables to be "bigints" if they already exist but will otherwise leave them the same. You should verify that any tables with Chado v1.3 names correctly match the v1.3 schema. Otherwise you may have problems using Tripal. If you have not added any Chado v1.3 tables to your Chado v1.2 database you can ignore this issue. These are the newly added tables: analysis_cvterm, analysis_dbxref, analysis_pub, analysis_relationship, contactprop, dbprop, feature_contact, featuremap_contact, featuremap_dbxref, featuremap_organism, featuremapprop, featureposprop, library_contact, library_expression, library_expressionprop, library_featureprop, library_relationship, library_relationship_pub, nd_experiment_analysis, organism_cvterm, organism_cvtermprop, organism_pub, organism_relationship, organismprop_pub, phenotypeprop, phylotreeprop, project_analysis, project_dbxref, project_feature, project_stock, pubauthor_contact, stock_feature, stock_featuremap, stock_library, stockcollection_db.
 

If you choose to upgrade Chado follow these steps:

  1. Navigate to Tripal → Setup Tripal Install Chado Schema.  Select the radio button that reads 'Upgrade existing Chado v1.2 to v1.3 (no data is lost)
  2. Execute the job that was added:

    drush trp-run-jobs --username=administrator
  3. Return to the Tripal → Setup Tripal → Install Chado Schema page (or refresh if still there).  You should see that the current installed version of Chado is now 1.3.