Updating your HRM installation

Important: HRM 3.0 requires at least Huygens Core version 4.3.0-p2 to work! Older versions are not supported.

 

If you have upgraded the HRM in the past, you will know that some steps must be performed in addition to replacing the old HRM code with the new.

Updating the configuration files

There is only one change in the configuration file of HRM 3.0 with respect to HRM 2.1.x: the variable $omero_transfers={true|false} was added.

The 2.1.x hrm_{server|client}_config.inc configuration files were not modified from version 2.0.x, but showed several changes compared to the 1.2.x files. (see below)

Please mind that if you are upgrading straight from HRM 1.2.x, please notice that in HRM 2.0.x (and thus in 3.0) the configuration files were moved from {HRM_ROOT}/inc to {HRM_ROOT}/config, and the sample configuration files were moved from {HRM_ROOT}/resources to {HRM_ROOT}/config/samples: if you are upgrading from 1.2.x, make sure to move your configuration files to {HRM_ROOT}/config.

Checking the configuration files

An easy way to check for modifications is by running the {HRM_ROOT}/resources/checkConfig.php script. From the shell, run:

$ php checkConfig.php /var/www/hrm/config/hrm_server_config.inc

 

This example assumes that {HRM_ROOT} is /var/www/hrm.

Checking the 2.1.x files with the 3.0 checkConfig.php script will result in the following output:

 

Check against HRM v3.0.x.
* * * Error: variable omero_transfers not set or empty.
Check completed with errors! Please fix your configuration!

 

Checking the 1.2.x files with the 2.1.x checkConfig.php script will result in the following output:

 

Check against HRM v2.1.x.
* * * Error: variable max_upload_limit not set or empty.
* * * Error: variable max_post_limit not set or empty.
* * * Error: variable email_list_separator not set or empty.
* * * Error: variable resultImagesOwnedByUser must be removed from the configuration files!
* * * Error: variable resultImagesRenamed must be removed from the configuration files!
* * * Error: variable enable_code_for_huygens must be removed from the configuration files!
Check completed with errors! Please fix your configuration!

 

Please make sure to fix all problems. The {HRM_ROOT}/config/samples/hrm_{server|client}_config.inc.sample files and the installation instructions on this site will help you set the correct parameters.

Updating the database

Newer versions of the HRM might use slightly different/updated versions of the database back-end than previous ones. From HRM 1.2.3 to 2.0 the database revision number changed from 7 to 8; from HRM 2.0 to 2.1 the database revision changed to 9. From 2.1 to 3.0 the database revision changes to 10. For this reason, the first time you run HRM 3.0 you will be told that the database must be updated and that you are not allowed to continue until this has been done!

The following describes two possible ways to update the database.

 

Although we tested this procedure quite carefully, it is highly recommended to create a backup of the database before updating!

Updating from the web interface

Login to the HRM as the admin user: you will be brought directly to the Database update page. Click on the update button. If everything works properly (as it should...), the following message should be displayed.

 

Needed database revision for HRM v3.0 is number 10.
Current database revision is number 9.
Updating...

Database successfully updated to revision 10.

 

The database is now at the latest revision.

Updating from console

Alternatively, the database can be updated from the console (see here). Please pay attention to what the update process will report! The output should be the same as the one listed in the previous section, but if the update fails, you might want to report it.

 

Please see the installation instructions to finish the update!