New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to delete patterns if the indices don't exist #9224
Comments
i also had this, had to recreate the index on ES so i could remove it :) |
This might be related to #8373. |
I am also having this issue, with 5.2 |
I am also having this problem on 5.3 |
Hi @branchnetconsulting. I'm unable to reproduce the error in 5.3, but I'm also not really sure what the error actually is. Can you provide some more information on steps to reproduce and also what the error actually looks like? |
@chrisronline It is simple: -Create a index on ES As the index does not exist anymore, you can not select it to remove the pattern, forcing the admin to create the index again, remove pattern and then remove the index for good. |
Thanks for the added information @danielmotaleite. I'm still having some issues so I just want to verify something while also getting a little more information. What version of ES and Kibana are you seeing this? Thanks |
I saw this issue with ElasticStack 5.3.0. In Kibana, go to
Management->Index Patterns. If any of the index patterns listed there have
no existing indexes in Elasticsearch, then the page will not respond all to
you left clicking on those patterns, making it impossible to highlight the
pattern you want to delete. The only solution I am aware of is to create a
matching index, at which point Kibana will let you delete the index
pattern, and then you can delete the dummy index.
Kevin
…On Tue, May 16, 2017 at 1:35 PM, Chris Roberson ***@***.***> wrote:
Thanks for the added information @danielmotaleite
<https://github.com/danielmotaleite>.
I'm still having some issues so I just want to verify something while also
getting a little more information.
What version of ES and Kibana are you seeing this?
Can you attach a screenshot of the management page when you are unable to
select the index pattern?
Thanks
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#9224 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AMj33vFN8VfUPWjV-LkMAWpENt3NNpumks5r6d5kgaJpZM4K8w61>
.
|
Thanks for the clarification @branchnetconsulting I'm attempting to follow those same steps in 5.3.0 but after I manually delete the index from ES (through a curl command) and refresh Kibana, I can still see, select, and delete the index pattern. It'd helpful if I can see maybe a video or at least some screenshots of the error scenario so it might help me track down the root cause. Unfortunately, I can't find any code within Kibana that would result in the index pattern showing up in the list, but not be clickable. |
Chris, there may be some lag time involved. I recall that after creating a
dummy index, it didn't actually let me delete the matching Kibana index
pattern until a few minutes later, and possibly after restarting Kibana
and/or Chrome.
Kevin
…On Tue, May 16, 2017 at 2:52 PM, Chris Roberson ***@***.***> wrote:
Thanks for the clarification @branchnetconsulting
<https://github.com/branchnetconsulting>
I'm attempting to follow those same steps in 5.3.0 but after I manually
delete the index from ES (through a curl command) and refresh Kibana, I can
still see, select, and delete the index pattern. It'd helpful if I can see
maybe a video or at least some screenshots of the error scenario so it
might help me track down the root cause. Unfortunately, I can't find any
code within Kibana that would result in the index pattern showing up in the
list, but not be clickable.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#9224 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AMj33nyU5l4CScJWXs9ylhUhlhJtq8v7ks5r6fBegaJpZM4K8w61>
.
|
@branchnetconsulting Thanks Kevin. Just so I fully understand, you're saying that you eventually could delete the Kibana index pattern, but it just took some time before Kibana let you do it? |
Yes, I used curl to create a dummy index that matched the index pattern
that previously had no matching indexes, and after a few minutes Kibana and
a restart of Kibana and/or Chrome, it let me delete the Kibana index
pattern.
…On Tue, May 16, 2017 at 3:04 PM, Chris Roberson ***@***.***> wrote:
@branchnetconsulting <https://github.com/branchnetconsulting> Thanks
Kevin.
Just so I fully understand, you're saying that you eventually could delete
the Kibana index pattern, but it just took some time before Kibana let you
do it?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#9224 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AMj33r4xY4K0GuhlhyU2AUekJT33puTBks5r6fMpgaJpZM4K8w61>
.
|
Thanks for the clarification @branchnetconsulting. Does this match the behavior you're seeing too @danielmotaleite? |
I just tried this on 5.4.0 and I couldn't replicate. |
You probably need to restart kibana and/or maybe the browser to be able to be unable to select the pattern, if you do not do that, you are still using some cached info that allow you to select it.
No! you both are talking about different steps, one after the index removal, the other after the index re-creation! :) After creating the index and the kibana pattern, if you remove the index, you probably need to restart kibana, the browser or both. After that you are unable to select the removed index pattern in kibana. As you can not select it, you can not remove it. Then, as workaround, you have to create the index (or something that match that index pattern) and restart kibana/browser or again both, you can then select the pattern in kibana and finally remove it |
Here is a video I took trying to reproduce the problem on https://www.youtube.com/watch?v=d1M4CNYw-BQ&feature=youtu.be My steps:
I've also tried these same steps with another existing index pattern and I'm still able to properly select and delete the orphaned index pattern. Is there another step involved that reproduces the error? |
i'm on kibana 5.3.2 and creating the index, adding the pattern, removing the index, restart kibana and browser, i can still select the pattern!! :) But i know that is isn't fixed, as i still have one index pattern that i can not delete as the related index does not exist anymore. So there is something else missing to trigger this issue. Try to restart the elasticsearh cluster (i can't do that on mine, as it is live) , maybe there is some index cache on the ES that can change the test? or maybe the index or pattern must be created with a older (< v5.x) elasticsearch or kibana? Or maybe the pattern must be a wildcard (logstash-*), as all my patterns have wildcards i will wait for the nighly rotation and maintenance to see if that changes anything in my cluster. at least i have one broken pattern, so i can do some tests there. In the browser when i press the broken pattern i get this in the browser console:
|
@danielmotaleite That stack trace is VERY helpful! I'm seeing some area of the code that might be causing it. I'll update when I know more |
Hey @danielmotaleite, for this index pattern that is un-deletable, would you mind making the following request against your Elasticsearch cluster and posting its results here?
Thanks! |
Sure:
|
@danielmotaleite Thanks for providing that. Quick question, do you recall when this index pattern was created? I have a hunch it might have been created before ES 5.0. |
All the index patterns that I could not delete were definitely created pre
ES 5.0.
Kevin
…On Thu, May 18, 2017 at 9:42 AM, Chris Roberson ***@***.***> wrote:
@danielmotaleite <https://github.com/danielmotaleite> Thanks for
providing that.
Quick question, do you recall when this index pattern was created? I have
a hunch it might have been created before ES 5.0.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#9224 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AMj33lSesJA-5chcZ6Klb2gRbUqwZG6Xks5r7ErZgaJpZM4K8w61>
.
|
the same thing here, those patterns are old, more than one year old... and not even used for a long time That was a debug pattern for a weird bug that i had and that i forgot until i upgraded to ELK 5.0 |
Okay thanks so much for all the information @danielmotaleite and @branchnetconsulting. Please keep an eye on the PR and I'll update this ticket once the fix is ready to use. |
As a followup, I just wanted to explain what we think happened. The issue is the affected index patterns do not contain searchable or aggregatable fields which can happen from a couple reasons, per @Bargs
Hopefully this can help identify potentially stale index patterns that need their fields refreshed in your cluster(s) but the fix will now allow you to properly delete orphaned index patterns. |
Thanks for the update and the fix! by the way, what happens when one press "refresh fields list" on one of those patterns? as there is no index, i assume it would simply fail and report one error and not open a new kind of bug :) |
@danielmotaleite That's right. The behavior will mostly match when you're seeing now, but it won't break the page. It will just report the same error in the notification section at the top. |
Might be a bit late to the conversation but this may help those who need to manually delete index patterns. |
curl -XGET "host:9200/.kibana/index-pattern/index-pattern" |
for kibana/es 6.3.x (and above) it should be a restart of kibana is not really required (but a browser refresh maybe) |
Kibana version: 5.0.1
Elasticsearch version: 5.0.1
Server OS version: Ubuntu 14.04
Browser version: Chrome
Browser OS version: OS X 10.12.1
Original install method (e.g. download page, yum, from source, etc.): apt
Description of the problem including expected versus actual behavior:
If an index pattern exists in the KB settings, but not in ES, you cannot delete that pattern.
Are we able to allow the user to go to the pattern definition, display a warning that the index doesn't exist, and at least offer the ability to delete said pattern at least?
Steps to reproduce:
Errors in browser console (if relevant):
Provide logs and/or server output (if relevant):
The text was updated successfully, but these errors were encountered: