SQLStore3 migration

From semantic-mediawiki.org

This page contains outdated information and is thus OBSOLETE!
This documentation page applies to all SMW versions from 1.8 to 1.8.

SQLStore3 migration en 1.8 1.8

Table of Contents

Instructions to move to Store3 (version 1.8)


This process will guide you to the basic steps in migrating to Store3. Store3 has some major architectural changes, including new Database tables and their structure. Don't be scared to move to Store3, this process will keep your data in Store2 intact and you can switch back when needed.


Keep the wiki running in Store2. Switching to Store3 should only be done when all property tables for Store3 are created and counts updated. Update/create tables for Store3 and make entries of properties using migration script. To do this run SMW_migration.php in maintenance folder with option -setup

Data copying[edit]

Copies all Semantic data from Store2 to Store3 using a migration script keeping data for Store2 intact; this provides freedom to revert back as and when in trouble. To do this using maintenance script run SMW_migration.php in maintenance folder with option -migrate:

php extensions/SemanticMediaWiki/maintenance/SMW_migration.php -migrate

This will copy property-values for each property one by one into Store3. This can be slow process for a large semantic wiki. A rescue is to use arguments 'limit' and 'offset' that indicate ids of properties to move at one go.

Updating Statistics[edit]

SMW 1.8 maintains some stats on properties which are used by Special pages, keeping these intact is important.

Run SMW_resetStats.php in maintenance folder to rebuild stats for your wiki This script also has arguments 'limit' and 'offset' similar to the migration script.

Final Step[edit]

Now the Store3 must be all setup to be used. Switch your wiki to use this store by changing $smwgDefaultStore to use SMWSQLStore3. Check your wiki if it still works properly, if not drop a topic on the Talk page.