Jira Re-Indexing failed: failed to locate current segments_N file

Der Jira Index wurde beschädigt und kann nicht wiederhergestellt werden.

The issue index is inconsistent with the database state. Database has (5681) issues but the index has (0) issues.

Die Datenbank an sich ist noch intakt, jedoch wurde der Jira eigene Index zerstört.

Eine Neuindexierung über System – Advanced – Indexing schlägt fehl.

Im Catalina Log taucht folgende Meldung auf:
tail /opt/atlassian/jira/logs/catalina.out -f

[fusion_builder_container hundred_percent="yes" overflow="visible"][fusion_builder_row][fusion_builder_column type="1_1" background_position="left top" background_color="" border_size="" border_color="" border_style="solid" spacing="yes" background_image="" background_repeat="no-repeat" padding="" margin_top="0px" margin_bottom="0px" class="" id="" animation_type="" animation_speed="0.3" animation_direction="left" hide_on_mobile="no" center_content="no" min_height="none"][...]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at com.atlassian.jira.task.ForkedThreadExecutor$ForkedRunnableDecorator.run(ForkedThreadExecutor.java:216)
        at java.lang.Thread.run(Thread.java:745)
Caused by: org.apache.lucene.index.CorruptIndexException: failed to locate current segments_N file
        at org.apache.lucene.index.IndexFileDeleter.(IndexFileDeleter.java:219)
        at org.apache.lucene.index.IndexWriter.(IndexWriter.java:1173)
        at com.atlassian.jira.index.DefaultIndexEngine.clean(DefaultIndexEngine.java:176)
        ... 28 more

Zum Beheben, kann man Jira zwingen, den Index neu aufzubauen.
Dazu den Dienst stoppen, alle vorhandenen Indexdateien löschen/umbenennen und Jira neu starten.
service jira stop
cd /var/atlassian/application-data/jira/caches
mv indexes indexes_old
mkdir indexes
chown jira:jira indexes -R
service jira start

Achtung: Es werden bis zu Neuindexierung keinerlei Issues angezeigt!
Dann kann man die Neuindexierung im Menü starten.
jira-reindexing

[...]
JiraTaskExectionThread-1 INFO braun 628x131x1 7gi885 172.30.18.99,127.0.0.1 /secure/admin/IndexReIndex.jspa [c.a.j.w.a.admin.index.IndexAdminImpl] Re-indexing started
JiraTaskExectionThread-1 INFO braun 628x131x1 7gi885 172.30.18.99,127.0.0.1 /secure/admin/IndexReIndex.jspa [c.a.j.util.index.CompositeIndexLifecycleManager] Reindex All starting...
JiraTaskExectionThread-1 INFO braun 628x131x1 7gi885 172.30.18.99,127.0.0.1 /secure/admin/IndexReIndex.jspa [c.a.j.w.a.admin.index.IndexAdminImpl] Re-indexing is 0% complete. Current index: Issue
JiraTaskExectionThread-1 INFO braun 628x131x1 7gi885 172.30.18.99,127.0.0.1 /secure/admin/IndexReIndex.jspa [c.a.j.issue.index.DefaultIndexManager] ReindexAll in foreground: {indexIssues=true, indexChangeHistory=true, indexComments=true, indexWorklogs=true, forceReloadFromDatabase=false}
IssueIndexer:thread-7 INFO braun 628x131x1 7gi885 172.30.18.99,127.0.0.1 /secure/admin/IndexReIndex.jspa [c.a.j.w.a.admin.index.IndexAdminImpl] Re-indexing is 1% complete. Current index: Issue
[...]
JiraTaskExectionThread-1 INFO braun 628x131x1 7gi885 172.30.18.99,127.0.0.1 /secure/admin/IndexReIndex.jspa [c.a.j.w.a.admin.index.IndexAdminImpl] Re-indexing is 100% complete. Current index: PortalPage
JiraTaskExectionThread-1 INFO braun 628x131x1 7gi885 172.30.18.99,127.0.0.1 /secure/admin/IndexReIndex.jspa [c.a.j.util.index.CompositeIndexLifecycleManager] Reindex took: 390ms. Indexer: SharedEntityIndexManager: paths: []
JiraTaskExectionThread-1 INFO braun 628x131x1 7gi885 172.30.18.99,127.0.0.1 /secure/admin/IndexReIndex.jspa [c.a.j.w.a.admin.index.IndexAdminImpl] Re-indexing is 100% complete. Current index:
JiraTaskExectionThread-1 INFO braun 628x131x1 7gi885 172.30.18.99,127.0.0.1 /secure/admin/IndexReIndex.jspa [c.a.j.util.index.CompositeIndexLifecycleManager] Reindex All complete. Total time: 95451ms. Reindex run: 27

[/fusion_builder_column][/fusion_builder_row][/fusion_builder_container]

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s