-
Notifications
You must be signed in to change notification settings - Fork 24.9k
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
red* (asterisk) index health #52304
Comments
I suspect this is related to #51456 which converted the ILM history index to a hidden index, from #50452. Hidden indices are not expanded, which means they shouldn't resolve in health/stats calls. When we can't get this information, we mark an index as @gwbrown @jaymode Can you think about the proper handling of this? |
Pinging @elastic/es-ui (:ES-UI) |
Still digging into this, but some notes:
@jaymode, this also caused me to realize that there's currently no way to view hidden indices in the |
Pinging @elastic/es-core-infra (:Core/Infra/Core) |
It sounds like yet another consequence of #32238 (and the connected issues). My preference (but there's a variety of different views across the ES team) is actually to move wildcard resolution from being in a pre-action interceptor to being in a pluggable core component. Right now security tries to replace wildcards with fixed names before the action runs. That means we replace If we move wildcard expansion into some pluggable component, then the actions always deal with wildcards, but security would be able to take responsibility for filtering that expansion to only include indices that the user has access to.
I think this is the same situation as above (per my "I guess..."). Good luck with that one @jaymode - I guess you'll never really get to escape this probem :)
What semantics do we intend to have when there is an alias to a hidden index? |
I knew that the cat APIs had hardcoded their indices options from when I went through all of the REST APIs to see where we needed to update for hidden indices. My thought at the time was that hidden indices could be left out of the cat apis and I vaguely remember that this was discussed during the last EAH. Currently we have code like elasticsearch/server/src/main/java/org/elasticsearch/rest/action/cat/RestIndicesAction.java Line 93 in cecee07
My suggestion is to simply modify this to: final IndicesOptions indicesOptions = IndicesOptions.fromRequest(request, IndicesOptions.strictExpand());
This is true and has always been problematic with security. Ultimately part of the problem is the feature where actions can be authorized against an alias without the user having permissions against the underlying index.
It is the same issue where security doesn't introspect anything about an alias when doing expansion Lines 419 to 425 in a9afdd7
|
In some cases, the alias should also be hidden in my opinion. The reason why I think that should be the case is that we have ILM, which write aliases are a part of that and if we think about some of our hidden indices, I think ILM makes sense to be used for those. So if expanding wildcards and an alias points to only hidden indices, then the alias should also be hidden. When hidden and non-hidden are mixed in an alias, that's when we start getting into the cases where it gets muddy. My suggestion:
Item 4 is the ugliest aspect especially when it comes to the API for managing aliases and I think we could get away with just doing items 1-3. |
Since aliases are supposed to act like indices on their own, why does what they point to matter? Could we decouple them so that they can point to any mix of hidden and non-hidden indices, and only the hidden property on the alias matters for visibility? This would match with the dot prefix behavior in linux filesystems we have modeled hidden indices on, where an alias is like a symlink. |
I dropped a sentence in my reply while editing; I was using the write index support and attempting to align this with that. In that case, there is the implicit write index on an alias when the alias only points to a single index. Hidden and write indices are different so they aren't going to align exactly, so we can avoid that implicit support. |
@jaymode and I discussed this issue and the underlying issues today. We concluded:
We're also going to hold off on recommending other teams transition to using hidden indices until we've made some progress on resolving the problems with aliases and hidden indices, as most of the use cases for hidden indices involve an alias. |
This should be fixed with #53248. Closing this issue. |
Is this a bug on master? Cat indices reports an index as having
red*
health. This seems like a recent change because our client-side logic in Kibana expects health to be eithergreen
,yellow
, orred
.The text was updated successfully, but these errors were encountered: