Help:Special page "SemanticMediaWiki" - data rebuild

< Special page "SemanticMediaWiki"
Special page "SemanticMediaWiki"Help:Special page "SemanticMediaWiki" - data rebuild
Data rebuild
Allows to rebuild the semantic data in the storage backend
Function type

This page describes the data rebuild function accessible via special page "SemanticMediaWiki". It is located in its "Data repair and update" section and allows to repair the data stored by rebuilding and refreshing the semantic data storage backend.

NoteNote: It is recommended to only use this function in case no shell access to the server is available to the wiki operator. If access to the shell is available the "rebuildData.php" maintenance script is the method of choice to do this task.

By default all users who are administrators (user group "sysop") or Semantic MediaWiki administrators (user group "smwadministrator") may use this feature. This feature can be disabled by removing the SMW_ADM_REFRESH constant from configuration parameter $smwgAdminFeatures. See the linked help page for information on how this is done.


To initiate the rebuild of the semantic data the button labeled "Start updating data" provided in the "Data rebuild" subsection of the "Data repair and update" section on the "SemanticMediaWiki" special page has to be clicked. After doing so the system message "An update is already in progress." appears together with a bar displaying the approximate progress of the data rebuild together with a respective percentage information. Also a button labeled "Stop this update" together with a checkbox field requesting confirmation "Yes, I am sure" appears at the same time. This allows to cancel the process in case it has mistakenly been initiated or if the process halted for some technical reason.

Once initiated, the update takes time varying from wiki to wiki since this function creates jobs for doing the task which are added to MediaWiki's job queue. The more data is stored on the wiki the more jobs are being created and the longer this process will take. Moreover since the update progresses during each page view it will be faster if many people view your wiki. Also note that it is normal that the update progresses faster until it reaches 50%, since only property pages are refreshed during that part of the process. The actual update of all wiki pages starts at 50%.

The button labeled "Start updating data" is shown again once the data rebuild jobs were completed.


The work on the job queue is governed by MediaWiki is also influenced by its configuration setting $wgJobRunRate in conjunction with configuration setting $wgRunJobsAsync. Alternatively if configuration setting $wgJobRunRate is set to "0" a cron job for MediaWiki's maintenance script "runJobs.php" will have to be set up by the wiki's system operator to ensure that the job queue is being worked on in due time. This is the recommended approach though it is preferable in this case to disable the function described on this page and run maintenance script "rebuildData.php" directly.

See also[edit]