com.atlassian.jira.util.RuntimeIOException: org.apache.lucene.index.CorruptIndexException: Unknown format version: -11 at com.atlassian.jira.index.DefaultIndexEngine.clean(DefaultIndexEngine.java:145) at com.atlassian.jira.index.DefaultManager.deleteIndexDirectory(DefaultManager.java:44) at com.atlassian.jira.issue.index.DefaultIssueIndexer.deleteIndexes(DefaultIssueIndexer.java:170) at com.atlassian.jira.issue.index.DefaultIndexManager.reIndexAll(DefaultIndexManager.java:219) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at com.atlassian.util.profiling.object.ObjectProfiler.profiledInvoke(ObjectProfiler.java:70) at com.atlassian.jira.config.component.SwitchingInvocationHandler.invoke(SwitchingInvocationHandler.java:28) at $Proxy56.reIndexAll(Unknown Source) at com.atlassian.jira.util.index.IndexLifecycleManager$Composite.reIndexAll(IndexLifecycleManager.java:113) at com.atlassian.jira.web.action.admin.index.ReIndexAsyncIndexerCommand.doReindex(ReIndexAsyncIndexerCommand.java:30) at com.atlassian.jira.web.action.admin.index.AbstractAsyncIndexerCommand.call(AbstractAsyncIndexerCommand.java:55) at com.atlassian.jira.web.action.admin.index.AbstractAsyncIndexerCommand.call(AbstractAsyncIndexerCommand.java:24) at com.atlassian.jira.task.TaskManagerImpl$TaskCallableDecorator.call(TaskManagerImpl.java:358) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) at com.atlassian.jira.task.ForkedThreadExecutor$ForkedRunnableDecorator.run(ForkedThreadExecutor.java:249) at java.lang.Thread.run(Thread.java:662) Caused by: org.apache.lucene.index.CorruptIndexException: Unknown format version: -11 at org.apache.lucene.index.SegmentInfos.read(SegmentInfos.java:247) at org.apache.lucene.index.IndexFileDeleter.<init>(IndexFileDeleter.java:173) at org.apache.lucene.index.IndexWriter.init(IndexWriter.java:1614) at org.apache.lucene.index.IndexWriter.<init>(IndexWriter.java:1079) at com.atlassian.jira.index.DefaultIndexEngine.clean(DefaultIndexEngine.java:141)
Please advise.
You won't see any issues until you've got a working index. Similarly for imports - the index needs to be usable.
The error you are seeing tells you that your index is completely broken. In some applications, this would be a serious issue, but in Jira, it's not painful because you can actually throw away the whole index and rebuild it from scratch, simply by clicking "re index"
However, you've got a serious error blocking that. As it's starting immediately, I'd say there's a critical problem with the index files - either you're out of space, the Jira user doesn't have read AND write AND delete permissions on the index directory, or you've got a damaged file system or disk. Simple fix -
(If I were to lay a bet on this, I'd say it's going to be "not enough delete permissions")
still not working. And I changed the permissions:
[root@integration logs]# cd /opt/jira/releases/ProdJIRA/caches/indexes/
[root@integration indexes]# ls -lr
total 16
drwxrwxrwx 2 root root 4096 Aug 29 10:49 issues
drwxrwxrwx 2 root root 4096 Aug 29 10:49 entities
drwxrwxrwx 2 root root 4096 Aug 29 10:49 comments
drwxrwxrwx 2 root root 4096 Aug 29 10:49 changes
running out of options.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
root# df -k ?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Sorry for the stupid question, but are you on the correct JiraHome ? Have you fsckd ?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You need to reindex your Jira.
Steps available here: https://confluence.atlassian.com/display/JIRAKB/Unable+to+Rebuild+JIRA+Index
Check first the drive for errors, though
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I tried the steps listed in the above link but I'm getting the same problem when I try to re-index.
And there are NO issues showing in JIRA at all. It also wont let me do a restore from a prior backup for the same reason.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Eric,
There's something really nasty on your disk. It can be permissions, for instance (you start jira as root, then as another user which has no perms to write to that dir). There can be a physical fault.
Edit: Saw that Nic just answered you, too. I fully agree with him.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
there is plenty of space and there are no errors of the disk.
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/sda2 20161204 6245120 12891944 33% /
/dev/sda1 1019864 49460 918596 6% /boot
/dev/sda8 637354280 346303368 258675120 58% /data
/dev/sda6 10080488 5591648 3976772 59% /home
none 4097840 0 4097840 0% /dev/shm
/dev/sda5 15116836 3795356 10553576 27% /usr
/dev/sda3 15116868 1087708 13261256 8% /var
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I'm pretty sure that its not the server because I have other applications running there using mysql.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
can I drop the database and recreate it and then do a restore from a backup?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The database is not the problem, it is the index, which is usually kept under the "jira home" directory.
I'm 99% sure it is the server. It's possible that the index is erroring because of something else, but as the log is basically saying "I can't clear the index to proceed with rebuilding it", I am almost certain it's that, which means it's something on the server.
Could you please find the index directory and delete it's contents completely, check the permissions on it, check the user who is running Jira and then restart Jira. Then re-index.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
here is the directory:
drwxrwxrwx 2 root root 4096 Aug 29 10:49 changes
drwxrwxrwx 2 root root 4096 Aug 29 10:49 comments
drwxrwxrwx 2 root root 4096 Aug 29 10:49 entities
drwxrwxrwx 2 root root 4096 Aug 29 10:49 issues
[root@integration indexes]# pwd
/opt/jira/releases/ProdJIRA/caches/indexes
I have removed them. recreated them. And given them 777 permission:
/opt/jira/releases/ProdJIRA/caches/indexes
[root@integration indexes]# rm -rf *
[root@integration indexes]#
[root@integration indexes]#
[root@integration indexes]# mkdir comments entities issues
[root@integration indexes]# ls
comments entities issues
[root@integration indexes]# ls -ltr
total 12
drwxr-xr-x 2 root root 4096 Aug 29 14:42 issues
drwxr-xr-x 2 root root 4096 Aug 29 14:42 entities
drwxr-xr-x 2 root root 4096 Aug 29 14:42 comments
[root@integration indexes]# chmod 777 *
[root@integration indexes]# ls -ltr
total 12
drwxrwxrwx 2 root root 4096 Aug 29 14:42 issues
drwxrwxrwx 2 root root 4096 Aug 29 14:42 entities
drwxrwxrwx 2 root root 4096 Aug 29 14:42 comments
i restarted the instance and tried re-indexing but the problem is still happening.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
i think that I have figured out what my problem was. The app was set for an alternate indexing path. I was cleaning up the default index path. I finally checked that and switched it to the default. The re-index finally ran successfully and the issues are showing again. Thanks for all of your help!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.