-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
[Alerting] 7.8 cloud returning 500 response for event log queries #68265
Comments
Pinging @elastic/kibana-alerting-services (Team:Alerting Services) |
So, it gets a little worse - it appears the mappings that got created were "dynamic" - it didn't use the mappings we set up in the index template. On further notice, the index is actually named This is probably still ok for 7.8, since we don't use the event log to query, but means the 7.8.x event logs are kind of hosed. No ILM. Looking in the logs at the first start of this Kibana instance, I can see the following with tag
That code is here: kibana/x-pack/plugins/event_log/server/es/cluster_client_adapter.ts Lines 41 to 53 in 1f3379a
However, I can
So, seems like a permissions problem perhaps? |
Hmm ... for a newly created user, doing the ILM check, I get a 403, with no message of "Bad Request" that I can see ... I wonder if it's |
I believe we structured this so that if there's any error doing the EL init, that we basically disable the event log, but it looks like that's not quite working, and ... not sure why. Looks like all the errors are being caught in the right places in the following files:
The problem is that if the init fails, the writes will end up create a new index with the non-ILM'd name (because we write to the alias, but with no alias, a new index with that name will be created), with no template, ilm etc, which will be hard to convert back to it's ILM-able version. |
Remembering now that we renamed the ILM policy to remove the leading |
In regards to missing permissions, its very likely because this change in Elasticsearch was required: elastic/elasticsearch#46894. Cloud has a different list of permissions they grant to Kibana user (for now) and it's a manual step to grant privileges to Kibana on cloud. We had a similar issue with API key where kibana user in cloud didn't auto-get the privileges after merging a PR in Elasticsearch.
EDIT: The permissions are granted on cloud. Also makes sense that we should fix the event log from logging events to Elasticsearch when it fails to initialize. |
It looks like we've only done 1/2 the work on "disabling" the event log in the case of initialization errors, unrelated to whatever the problem is here. Because the event log isn't "disabled", we end up writing to an index with the name of the alias we wanted to use, meaning we can't create the alias later. If we disable the event log, at least we won't be creating the index, and the next time we try to initialize, perhaps it will work (customer changes configuration that now allows it to work). I opened #68309 for this. |
resolves elastic#68265 This changes the ILM requests made by the eventLog from relative to absolute URLs. These requests test the existence of and create ILM policies, and are made with a cluster client using `transport.request`. Relative URLs work fine locally and in CI, however do not work on the cloud.
@mikecote just to confirm, anything to do from our side here? |
@nachogiljaldo Nothing to confirm anymore, I answered my own question. Sorry for the ping. |
Hopefully PR #68331 will resolve this. |
resolves #68265 This changes the ILM requests made by the eventLog from relative to absolute URLs. These requests test the existence of and create ILM policies, and are made with a cluster client using `transport.request`. Relative URLs work fine locally and in CI, however do not work on the cloud.
resolves elastic#68265 This changes the ILM requests made by the eventLog from relative to absolute URLs. These requests test the existence of and create ILM policies, and are made with a cluster client using `transport.request`. Relative URLs work fine locally and in CI, however do not work on the cloud.
resolves elastic#68265 This changes the ILM requests made by the eventLog from relative to absolute URLs. These requests test the existence of and create ILM policies, and are made with a cluster client using `transport.request`. Relative URLs work fine locally and in CI, however do not work on the cloud.
…8391) resolves #68265 This changes the ILM requests made by the eventLog from relative to absolute URLs. These requests test the existence of and create ILM policies, and are made with a cluster client using `transport.request`. Relative URLs work fine locally and in CI, however do not work on the cloud.
…8390) resolves #68265 This changes the ILM requests made by the eventLog from relative to absolute URLs. These requests test the existence of and create ILM policies, and are made with a cluster client using `transport.request`. Relative URLs work fine locally and in CI, however do not work on the cloud.
I can query the event log via it's HTTP endpoint in 7.8 when running locally, but when I run in the cloud I see the following error logged, and a 500 is returned from the HTTP request:
For 7.8 we have exposed the HTTP endpoint for event log queries, but are not actively using it, so it's not a blocker for 7.8.0, but something we should try to get in for 7.8.1.
The text was updated successfully, but these errors were encountered: