Reindexing a component in an existing index
Reindex data in an HCL Connections component.
About this task
Procedure
- Disable any scheduled search indexing
tasks. You must disable scheduled tasks because the default indexing
task indexes all HCL Connections
services. However, to add a component, only a subset of services are
to be indexed. Also, it is useful not to have a foreground indexing
process contending with the background operation for system resources.
Disabling search indexing tasks also it makes it easier to distinguish
messages about foreground operations from background operations in
the logs.
- Use the following command to back up the current search index: SearchService.backupIndexNow(). This command copies a new backup of the search index to the backup folder specified in the WebSphere® variable SEARCH_INDEX_DIR.
- Make a copy of the index backup to work on. When you work with a background index, you should perform all operations on a copy of the background index. Make you copy on the local file system (not a network share). This copy is referred to the as the "working copy".
- Use the following command to build the components into
the working copy of the index: SearchService.startBackgroundFeatureReindex
(persistenceLocation, extractedFileContentLocation, indexLocation,
application). When the operation is complete, a marker file
that is called INDEX.READY is placed in the index
folder. Check the logs to confirm that there were no errors during
the operation. For example:
SearchService.startBackgroundFeatureReindex("/opt/IBM/Connections/data/local/search/backgroundCrawl", "/opt/IBM/Connections/data/local/search/backgroundExtracted", "/opt/IBM/Connections/data/local/search/backgroundIndex", "people_finder")
Note: Valid values for application parameter are as follows: activities, blogs, calendar, communities, dogear, ecm_files, files, forums, people_finder, profiles, status_updates, wikis - Restore the modified index across the deployment. When the background index operation is complete, you must roll out the working copy of the index across the deployment. For more information, see Restoring the Search index.
- Enable any scheduled search indexing tasks that you disabled
in step 1. Use the following command to enable the new indexing task
to run on the defined schedule: SearchService.enableTask().
For example:
SearchService.enableTask("15min-new-search-indexing-task")