jira is not indexing properly.

hi,

We are using Jira 5.1. We are facing some problem frecquently.

The status of some particular requests are showing differently in the issue navigator and in issue.

ex : JIRA-123 status is showing as STATUS A in the navigator ,but if we go the ticket, it is showing STATUS B(which is correct).

If we do re-indexing , then the status is showing correctly(STATUS B) in the issue navigator also.

Any idea on this.

5 answers

1 accepted

This widget could not be displayed.

So far, you've had two different answers. They are both correct, and complementary, but to be clear, what's going on is:

1. Something is corrupting your index (you say "We are using Jira 5.1. We are facing some problem frecquently." so it's not a one-off). See Renjith's answer

2. Once the index is damaged, you are seeing problems.

You need to fix both of these. Re-indexing and clearing the caches will repair the damage. But they won't fix the root cause. You need to identify what is causing the damage and fix that, otherwise it will simply continue to corrupt your index, and you'll need to keep repairing it.

Mizan Community Champion Feb 05, 2013

Hi Nic ,

Can such issue occur after upgrading JIRA ? for us this use to happen after editing the issue .

An upgrade will perform a re-index as part of the process. I'd expect a vanilla installation of Jira to be absolutely fine after upgrading.

Adding/upgrading plugins afterwards may cause problems, but that depends entirely on them and your system. The worst case is that you should allow time for a second re-indexing run after an upgrade.

However, an upgrade is only one possibility of a root-cause, and if you've re-indexed after it, then you should not be seeing any index issues. If you are getting them after re-indexing, then something else is doing the damage.

Mizan Community Champion Feb 06, 2013

Thanks Nic ,

I am facing this same issue , I deleted the indexes folder but the issue still persisit , can you please help me in finding the root cause for this ? What can be the probable cause for this ?

I checked the post functions and the issues are reindexed .

The root cause is usually plugins that aren't indexing, are doing things that break the index, or are running in the wrong place.

You can also have problems if there are core errors - out of memory, lucene locks etc.

Two things to start looking at:

1) The log, for ANY errors. Your errors may not mention indexing, but they can have knock-on effects

2) Can you reproduce it reliably? Is it always when editing an issue? Or on certain transitions? Are the effects limited to particular projects?

As an aside, do you have any listeners configured?

Mizan Community Champion Feb 06, 2013

I see a null pointer exception given by a plugin , this went unnoticed till now. Can this be a reason ?

I cannot reporoduce this issue , its unpredictable and not limited to a single project .This issue have occured after editing and transitioning the issue .(not restricted to a certain transition)

Ok, so it's generalised. Good to know, although that makes it more difficult to trace.

The NPE from a plugin could easily be hiding an indexing problem, but it depends on the plugin - what is it? Or what does it trying to do?

The question is can you nail it down to a single point. Is it the *edit* that breaks, or the *transition*?

Mizan Community Champion Feb 06, 2013

The plugin does changes to the issue fields (customfields) copy and pastes values ,

It has a listener which works after the create issue event , a field value is then copied to another field.

That really does sound like it is the culprit. If it's not, then you still need to do the work to eliminate it from the possibilities.

Try a basic test - create an issue and let it copy the values. Then do a search based on the field that was copied to. Then open up the issue-view. If the indexing is failing, then you should see that the value is set correctly on the issue-view, but you cannot search for it. If the value is not on the issue-view, then the plugin is failing completely.

Mizan Community Champion Feb 18, 2013

Hi Nic ,

The listener was the culprit i guess :) not facing the issue anymore . Thanks

This widget could not be displayed.

Which means that you are modifying the issue either in plugins, script runner post functions, listeners etc. and not doing the step for individual issue reindex.

Yes ,we are using issueManager.updateIssue() in our post functions, it is causing problem

I seem to be experiencing something similar.... I'm updating some custom fields in a scripted listener, and ever since I started testing heavily with it our environment has been running into indexing and database corruption issues. What's the recommended way to make custom field updates in a scripted listener so that we don't run into these problems?

This widget could not be displayed.
Mizan Community Champion Feb 05, 2013

May be the indexes have got corrupted .

Folllow the below steps:

Stop JIRA , delete the indexes directory under JIRA_HOME/caches/ then restart JIRA .

This most probably might solve the issue .

This widget could not be displayed.
Ahmad Danial Atlassian Team Feb 05, 2013

Hey there, prathighantam.

As mentioned by Mizan earlier on, clearing your JIRA caches might help. What I would propose is a complete clean up of your JIRA instance as per the following:

  1. Shutdown JIRA instance
  2. Delete the contents of the JIRA Home Directory\plugins\.osgi-plugins directory
  3. Delete the contents of the JIRA Home Directory\plugins\.bundled-plugins directory
  4. Delete the contents of the JIRA Installation Directory\work directory
  5. Restart JIRA instance
  6. Try to perform the re-indexing

Hope it helps.

Warm regards,

Danial

Works like a charm, and we did the this step 1st though, stop JIRA delete the indexes directory under JIRA_HOME/caches/ then do step 2 from your instructions.

This widget could not be displayed.

I suggest you do the following:

1.- Stop Jira.

2.- Delete folder 'cache' in Jira Home.

3.- Start Jira.

4.- Reindex again (administration menu)

Hope it helps!

Daniel

Suggest an answer

Log in or Sign up to answer
Atlassian Summit 2018

Meet the community IRL

Atlassian Summit is an excellent opportunity for in-person support, training, and networking.

Learn more
Community showcase
Posted Aug 06, 2018 in Jira Service Desk

A is for Activate: Share your top Jira Service Desk onboarding tips for new users!

Hi, everyone! Molly here from the Jira Service Desk Product Marketing Team :).  In the spirit of this month's  august-challenge, we're sourcing stories of Jira Service Desk activation fro...

564 views 25 15
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you