How to track re-indexing in the application logs for Jira Data Center
Platform notice: Server and Data Center only. This article only applies to Atlassian products on the Server and Data Center platforms.
Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
In most cases, the re-indexing can be monitored using the UI. However, there are scenarios when this is not possible, such as when there is a need to track the first re-index after upgrading form 8.x to 9.x.
The contents of this KB is to provide an way to check details of the re-indexing, as well as track progress using the application log.
Environment
Jira 9.x
Steps
- Navigate to
$localjirahome/logs
directory. The application logatlassian-jira.log
by default can be found here as mentioned in Useful log files in Jira. Use the grep command to search for the string ReindexAll
% grep -i "ReindexAll" atlassian-jira.log 2023-08-04 09:22:40,163+1000 JiraTaskExecutionThread-1 INFO anonymous [c.a.j.issue.index.DefaultIndexManager] ReindexAll in foreground: {indexIssues=true, indexChangeHistory=true, indexComments=true, indexWorklogs=true} 2023-08-04 09:22:48,593+1000 JiraTaskExecutionThread-1 INFO anonymous [c.a.j.issue.index.DefaultIndexManager] ReindexAll took: 8426 ms in the foreground, index size is 80 KB
To read this sample log snippet, the start of the re-index from the
DefaultIndexManager
was at9:22:40
, when it mentionsReindexAll in foreground
with all the parameters related to the full lock re-index{indexIssues=true, indexChangeHistory=true, indexComments=true, indexWorklogs=true}
.2023-08-04 09:22:40,163+1000 JiraTaskExecutionThread-1 INFO anonymous [c.a.j.issue.index.DefaultIndexManager] ReindexAll in foreground: {indexIssues=true, indexChangeHistory=true, indexComments=true, indexWorklogs=true}
The end of the re-index is when it mentions
ReindexAll took xxx in the foreground
.2023-08-04 09:22:48,593+1000 JiraTaskExecutionThread-1 INFO anonymous [c.a.j.issue.index.DefaultIndexManager] ReindexAll took: 8426 ms in the foreground, index size is 80 KB
To monitor the progress, the grep command can make use of REGEX to watch the percentage of the progress. Please note that this sample was taken from a small instance which explains why the re-index finished very quickly. Larger instances will take significantly longer time compared to this sample snippet.
% grep -E "Re-indexing is.*complete" atlassian-jira.log* 2023-08-04 09:22:40,147+1000 JiraTaskExecutionThread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 0% complete. Current index: Issue 2023-08-04 09:22:47,137+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 4% complete. Current index: Issue 2023-08-04 09:22:47,212+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 8% complete. Current index: Issue 2023-08-04 09:22:47,219+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 12% complete. Current index: Issue 2023-08-04 09:22:47,230+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 16% complete. Current index: Issue 2023-08-04 09:22:47,234+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 20% complete. Current index: Issue 2023-08-04 09:22:47,240+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 24% complete. Current index: Issue 2023-08-04 09:22:47,249+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 28% complete. Current index: Issue 2023-08-04 09:22:47,254+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 32% complete. Current index: Issue 2023-08-04 09:22:47,256+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 36% complete. Current index: Issue 2023-08-04 09:22:47,260+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 40% complete. Current index: Issue 2023-08-04 09:22:47,263+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 44% complete. Current index: Issue 2023-08-04 09:22:47,268+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 48% complete. Current index: Issue 2023-08-04 09:22:47,277+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 52% complete. Current index: Issue 2023-08-04 09:22:47,436+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 56% complete. Current index: Issue 2023-08-04 09:22:47,441+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 60% complete. Current index: Issue 2023-08-04 09:22:47,445+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 64% complete. Current index: Issue 2023-08-04 09:22:47,448+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 68% complete. Current index: Issue 2023-08-04 09:22:47,451+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 72% complete. Current index: Issue 2023-08-04 09:22:47,455+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 76% complete. Current index: Issue 2023-08-04 09:22:47,459+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 80% complete. Current index: Issue 2023-08-04 09:22:47,462+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 84% complete. Current index: Issue 2023-08-04 09:22:47,465+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 88% complete. Current index: Issue 2023-08-04 09:22:47,468+1000 IssueIndexer:thread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 92% complete. Current index: Issue 2023-08-04 09:22:48,748+1000 JiraTaskExecutionThread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 92% complete. Current index: SearchRequest 2023-08-04 09:22:48,789+1000 JiraTaskExecutionThread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 96% complete. Current index: SearchRequest 2023-08-04 09:22:48,924+1000 JiraTaskExecutionThread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 96% complete. Current index: PortalPage 2023-08-04 09:22:48,930+1000 JiraTaskExecutionThread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 100% complete. Current index: PortalPage 2023-08-04 09:22:48,971+1000 JiraTaskExecutionThread-1 INFO anonymous [c.a.j.index.request.DefaultReindexRequestManager] Re-indexing is 100% complete. Current index: