Skip to content
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

opensearch anomaly detection default detectors are not being created #596

Closed
mmguero opened this issue Oct 15, 2024 · 2 comments
Closed
Assignees
Labels
bug Something isn't working dashboards Relating to Malcolm's OpenSearch Dashboards interface opensearch Relating to Malcolm's use of OpenSearch regression It worked at one point...
Milestone

Comments

@mmguero
Copy link
Collaborator

mmguero commented Oct 15, 2024

Just noticed this today. Despite these logs:

dashboards-helper-1  | 2024-10-15T21:16:52Z  /data/shared-object-creation.sh: Creating opensearch anomaly detectors...
dashboards-helper-1  | 2024-10-15T21:16:52Z  /data/shared-object-creation.sh: Importing detector "action_result_user" (1729026846 > 0) ...
dashboards-helper-1  | 2024-10-15T21:16:52Z  /data/shared-object-creation.sh: 
dashboards-helper-1  | 2024-10-15T21:16:52Z  /data/shared-object-creation.sh: Importing detector "file_mime_type" (1729026846 > 0) ...
dashboards-helper-1  | 2024-10-15T21:16:52Z  /data/shared-object-creation.sh: 
dashboards-helper-1  | 2024-10-15T21:16:53Z  /data/shared-object-creation.sh: 
dashboards-helper-1  | 2024-10-15T21:16:53Z  /data/shared-object-creation.sh: Importing detector "network_protocol" (1729026846 > 0) ...
dashboards-helper-1  | 2024-10-15T21:16:53Z  /data/shared-object-creation.sh: 
dashboards-helper-1  | 2024-10-15T21:16:53Z  /data/shared-object-creation.sh: Importing detector "total_bytes" (1729026846 > 0) ...
dashboards-helper-1  | 2024-10-15T21:16:53Z  /data/shared-object-creation.sh: 

I see this:

image

But also it seems like the script is still running in the dashboards-helper container

   1068 pts/0    S      0:00              |   \_ /bin/sh -c /data/shared-object-creation.sh
   1069 pts/0    S      0:00              |       \_ /bin/bash /data/shared-object-creation.sh
   6079 pts/0    S      0:00              |           \_ sleep 5
@mmguero mmguero added bug Something isn't working opensearch Relating to Malcolm's use of OpenSearch dashboards Relating to Malcolm's OpenSearch Dashboards interface regression It worked at one point... labels Oct 15, 2024
@mmguero mmguero added this to the v24.10.1 milestone Oct 15, 2024
@mmguero mmguero assigned mmguero and unassigned mmguero Oct 15, 2024
@mmguero
Copy link
Collaborator Author

mmguero commented Oct 15, 2024

I'm thinking the creation of the dummy detector failed.

mmguero added a commit to mmguero-dev/Malcolm that referenced this issue Oct 15, 2024
@mmguero mmguero self-assigned this Oct 16, 2024
mmguero added a commit to mmguero-dev/Malcolm that referenced this issue Oct 16, 2024
…reated

two issues were present:

1. opensearch_status.sh -w was no longer behaving as previously, as now an empty index is being created that doesn't have any events in it (see idaholab#527 and idaholab#567). It's been adjusted so that now it waits for an index with docs.count > 0.
2. The shared_object_creation.sh script needed to create the dummy detector if the .opendistro-anomaly-detection-state doesn't exist, so this check has been put in place
@mmguero
Copy link
Collaborator Author

mmguero commented Oct 16, 2024

Fixed:

two issues were present:

  1. opensearch_status.sh -w was no longer behaving as previously, as now an empty index is being created that doesn't have any events in it (see automatically create empty document on startup to avoid "no data" message spamming by Dashboards #527 and Create Initial Opensearch Indices #567). It's been adjusted so that now it waits for an index with docs.count > 0.
  2. The shared_object_creation.sh script needed to create the dummy detector if the .opendistro-anomaly-detection-state doesn't exist, so this check has been put in place

@mmguero mmguero closed this as completed Oct 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working dashboards Relating to Malcolm's OpenSearch Dashboards interface opensearch Relating to Malcolm's use of OpenSearch regression It worked at one point...
Projects
Status: Done
Development

No branches or pull requests

1 participant