MySource Matrix Resources

Main Content

MySource Matrix Rollback Management Guide

Introduction

This guide will show you how rollback support can be enabled and disabled for MySource Matrix. This guide requires you to have shell access to the MySource Matrix application server to run the rollback_management.php script.

Disabling Rollback Support

Configuration Settings

To disable rollback, first change the SQ_CONF_ROLLBACK_ENABLED configuration parameter in the main.inc configuration file from true to false.

define('SQ_CONF_ROLLBACK_ENABLED', false);

More information about MySource Matrix configuration settings can be found in the annotated guide to the main.inc configuration file.

Disable Database Triggers

Rollback is controlled through triggers on the database that copy data to history tables as it is modified. Disabling the rollback configuration setting will not stop these triggers from saving old versions of data. You must run the step_02.php installation script to disable them.

$ cd /path/to/matrix
$ php install/step_02.php /path/to/matrix

Enabling Rollback Support

Configuration Settings

To enable rollback, first change the SQ_CONF_ROLLBACK_ENABLED configuration parameter in the main.inc configuration file from false to true.

define('SQ_CONF_ROLLBACK_ENABLED', true);

More information about MySource Matrix configuration settings can be found in the annotated guide to the main.inc configuration file.

Initialise Rollback Data

The rollback data stored in the database needs to be initialised to the current data and time.

$ cd /path/to/matrix
$ php scripts/rollback_management.php -s /path/to/matrix --enable-rollback
Enable Database Triggers

Rollback is controlled through triggers on the database that copy data to history tables as it is modified. Enabling the rollback configuration setting will not allow these triggers to save old versions of data. You must run the step_02.php installation script to enable them.

$ cd /path/to/matrix
$ php install/step_02.php /path/to/matrix

Resetting Rollback

Resetting rollback is a process that should be completed after major upgrades of MySource Matrix. All existing rollback data is deleted and rollback is enabled. Essentially, the rollback system is reset to the current date and time.

Resetting rollback will delete all existing rollback data. This data will not be recoverable. Ensure you have made a backup of your system before resetting rollback.

See the MySource Matrix backup guide for help with backing up your system.

Configuration Settings

To reset rollback, first change the SQ_CONF_ROLLBACK_ENABLED configuration parameter in the main.inc configuration file from false to true.

define('SQ_CONF_ROLLBACK_ENABLED', true);

More information about MySource Matrix configuration settings can be found in the annotated guide to the main.inc configuration file.

Reset Rollback Data

The existing rollback data stored in the database needs to be deleted and initialised with new live data. This ensures rollback is restarted from the current date and time.

$ cd /path/to/matrix
$ php scripts/rollback_management.php -s /path/to/matrix --reset-rollback
Enable Database Triggers

Rollback is controlled through triggers on the database that copy data to history tables as it is modified. Enabling the rollback configuration setting will not allow these triggers to save old versions of data. You must run the step_02.php installation script to enable them.

$ cd /path/to/matrix
$ php install/step_02.php /path/to/matrix