"Archiva fails to start : ""Caused by: java.io.IOException: Error indexing workspace """

 

Overview

Archiva artifact repository fails to start.

Getting following exceptions.
jvm 1    | 2014-07-02 09:48:01.341:WARN::Failed startup of context o.e.j.w.WebAppContext{/archiva,file:/opt/Talend-5.3.1/tac/Talend-Artifact-Repository-V5.3.1/apps/archiva/},file:/opt/Talend-5.3.1/t...
jvm 1    | org.springframework
... ... .. ..

Caused by:
jvm 1    | javax.jcr.RepositoryException: Unable to initialize query handler: org.apache.jackrabbit.core.query.lucene.SearchIndex@6b127fc2
jvm 1    |     at org.apache.jackrabbit.core.config.RepositoryConfigurationParser$1.getQueryHandler(RepositoryConfigurationParser.java:649)
jvm 1    |     at org.apache.jackrabbit.core.config.WorkspaceConfig.getQueryHandler(WorkspaceConfig.java:215)

.. .. ....
jvm 1    |     at java.lang.Thread.run(Thread.java:744)
jvm 1    | Caused by:
jvm 1    | java.io.IOException: Error indexing workspace

Environment

Archiva

Symptoms/Description

It is not possible to  start Archiva Artifact repository as as standalone or as a service.
Getting following exception in TalendESB while executing

./archiva.sh console

jvm 1    | 2014-07-02 09:48:01.341:WARN::Failed startup of context o.e.j.w.WebAppContext{/archiva,file:/opt/Talend-5.3.1/tac/Talend-Artifact-Repository-V5.3.1/apps/archiva/},file:/opt/Talend-5.3.1/t...
jvm 1    | org.springframework
... ... .. ..

Caused by:
jvm 1    | javax.jcr.RepositoryException: Unable to initialize query handler: org.apache.jackrabbit.core.query.lucene.SearchIndex@6b127fc2
jvm 1    |     at org.apache.jackrabbit.core.config.RepositoryConfigurationParser$1.getQueryHandler(RepositoryConfigurationParser.java:649)
jvm 1    |     at org.apache.jackrabbit.core.config.WorkspaceConfig.getQueryHandler(WorkspaceConfig.java:215)

.. .. ....
jvm 1    |     at java.lang.Thread.run(Thread.java:744)
jvm 1    | Caused by:
jvm 1    | java.io.IOException: Error indexing workspace

Resolution

This could be possible that Archiva installation is corrupted and need reinstallation. As per the log, the reindexing is not working correctly. We would recommend the following to solve this issue.

1. First backup the complete Archiva installation folder. Verify the archiva.xml and locate the repositories location. Backup the repositories folder.

2. Verify whether there's any additional configurations done in Archiva. For example,  additional users/credentials. If required, one may need to backup the embedded derby database which stores user data.

3. Reinstall Archiva (unzip the installation) and copy the back up Repositories folder to the installation root directory (or edit the archiva.xml to point to the correct Repository folder).

4. Restart Archiva. This will then automatically reindex the Repositories.

Version history
Revision #:
1 of 1
Last update:
‎04-13-2017 10:22 PM
Updated by:
 
Labels (1)
Contributors