Search index error

Applies to: VisualSVN Server 5.0 and later

Starting from version 5.0, VisualSVN Server supports full-text search of your repositories. The following error message is displayed when a search cannot be performed due to issues with repository configuration:

Search index error
The search request has failed. Please contact your system administrator.

If you are seeing this message, please contact the system administrator for assistance.

Information for the administrator

The above-mentioned error message can be displayed in VisualSVN Server due to configuration issues that need the administrator's attention. Detailed symptoms of each of these problems and resolution steps are given below.

Cause 1. The repository has an old filesystem format version

Search and indexing capabilities require a repository with filesystem format 7 or newer (107 or newer for VDFS repositories). Older filesystem formats have to be upgraded to enable search.

Symptoms

When the repository has an old filesystem format version, the following errors are logged into the corresponding event logs.

VisualSVN Server event log:

Search failed for repository 'MyRepo', because its filesystem format does not support capabilities required to obtain a search index ID.

VisualSVN Server Search event log:

The repository filesystem format does not support capabilities required to obtain a search index ID. Search and indexing capabilities will be unavailable for this repository.

When viewing the Search Index Status in the VisualSVN Server Manager console, the following error is displayed for the repositories with unsupported filesystem format version:

The repository filesystem format does not support capabilities required to obtain a search index ID.

Resolution

The administrator needs to upgrade the filesystem format of the repository to enable search and indexing capabilities. The upgrade procedure is described in the article KB142: Upgrading the filesystem format of a repository.

Cause 2. A repository search index ID conflict

The search index ID conflict occurs when the repositories share the same instance ID. If the conflict occurs, search and indexing capabilities are disabled for all repositories with conflicting instance IDs.

Note

Instance ID is a special UUID (Universal Unique Identifier) that belongs to a repository in addition to the repository UUID. Instance ID is internally used to uniquely identify the repository. But unlike repository UUID, instance ID cannot be directly viewed or managed by Subversion admin tools.

The repository instance ID is guaranteed to be unique when all admin operations with the repository are performed through the corresponding Subversion admin tools (i.e., the VisualSVN Server Manager console, VisualSVN Server PowerShell or the svnadmin utility). However, when repository administration tasks are performed outside of the admin tools (for example, when copying the repository with Windows File Explorer), it can happen in practice that several repositories share the same instance ID.

The conflict has to be resolved to allow the repositories to be indexed and become searchable. The administrator needs to generate a new unique instance ID for all repositories with a conflicting value to resolve this issue.

Symptoms

When there is a search index ID conflict, the following errors are logged into the corresponding event logs.

VisualSVN Server event log:

Search failed for repository 'MyRepo' due to a search index ID conflict.

VisualSVN Server Search event log:

The service has encountered a search index ID conflict. Search and indexing capabilities will be unavailable for this repository.

When viewing the Search Index Status in the VisualSVN Server Manager console, the following error is displayed for the repositories with conflicting search index IDs:

Search index ID conflict.

Resolution

The administrator needs to generate a new unique repository instance ID value to enable search and indexing capabilities. New instance ID has to be generated for all repositories with the conflict.

Note
There is no command for directly updating the instance ID. But you can update the repository UUID to the same value as the current value and the repository's instance ID automatically receives a new unique value. Updating the repository UUID is the only supported way for updating the instance ID.

An administrator should follow these steps to update the search index ID of a repository:

  1. Stop the VisualSVN Server services.
  2. Open the VisualSVN Server PowerShell console. Read the article KB165: Using VisualSVN Server PowerShell module for instructions on how to open the console.
  3. Run the following two PowerShell commands to update the instance ID of the repository without changing its actual repository UUID:

    $repos = Get-SvnRepository MyRepo
    svnadmin setuuid $repos.Path $repos.UUID

    These commands have to be run for every repository mentioned in the error messages from the Symptoms section above.

    Make sure to replace the MyRepo placeholder name with an actual name of a repository. The name corresponds to the name of the repository in the error message logged into the server's logs.

  4. Start the VisualSVN Server services.

The instance ID and therefore the search index ID of the repository will be updated to a unique value and the search indexing capabilities become available.

See also

KB142: Upgrading the filesystem format of a repository
KB135: Understanding the Subversion repository types and formats
KB178: Getting started with full-text search

Last Modified: