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

fix(chart/opensearch): metricsPort and plugins usage info in values.yaml #593

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

eyenx
Copy link
Contributor

@eyenx eyenx commented Sep 10, 2024

Description

Trying to figure out how to expose metrics, it was obvious that there is the need of installing an additional plugin to be able to expose prometheus metrics over the serviceMonitor. Also the default port exposing the metrics is 9200 and not 9600.

This fixes the default metricsPort and adds a comment about the plugin to be used in values.yaml

Issues Resolved

#590

Check List

  • Commits are signed per the DCO using --signoff

For any changes to files within Helm chart directories:

  • Helm chart version bumped
  • Helm chart CHANGELOG.md updated to reflect change

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@peterzhuamazon
Copy link
Member

Note: We are in the review of an older PR now so will come back to this a little later.

@eyenx
Copy link
Contributor Author

eyenx commented Oct 18, 2024

@peterzhuamazon any update here? Thanks!

@eyenx
Copy link
Contributor Author

eyenx commented Nov 5, 2024

@peterzhuamazon any update here?

Copy link
Member

@peterzhuamazon peterzhuamazon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @eyenx sorry for the delay we are in a few releases, and just completed 2.18.0 yesterday evening.

metricsPort: 9600
metricsPort: 9200
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The metrics port here is for Performance Analyzer which utilizes the 9600 port
69daf97

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if we need to add a new var for other metrics?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@eyenx if we want to use this metricsPort (The metrics port (for Performance Analyzer) that Kubernetes will use for the service) then it should be 9600 right ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will check tomorrow.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does the performance Analazer actually expose metrics in prometheus format? If not I would still go for this, ut add 9600 as separate port. How can I enale the performance Analyzer plugin?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So I enabled the plugin following the guide, but I still see no metrics when I try to curl the Port

opensearch-cluster-master-0:/$ curl localhost:9600/_plugins/_performanceanalyzer/metrics  -vvv
06:45:58.738363 [0-x] == Info: [READ] client_reset, clear readers
06:45:58.738550 [0-0] == Info: Host localhost:9600 was resolved.
06:45:58.738685 [0-0] == Info: IPv6: ::1
06:45:58.738793 [0-0] == Info: IPv4: 127.0.0.1
06:45:58.738918 [0-0] == Info: [SETUP] added
06:45:58.739051 [0-0] == Info:   Trying [::1]:9600...
06:45:58.939510 [0-0] == Info:   Trying 127.0.0.1:9600...
opensearch-cluster-master-0:/$ curl -k https://localhost:9200/_plugins/_performanceanalyzer/config -u user:pw
{"performanceAnalyzerEnabled":true,"rcaEnabled":false,"loggingEnabled":false,"shardsPerCollection":0,"batchMetricsEnabled":false,"threadContentionMonitoringEnabled":false,"batchMetricsRetentionPeriodMinutes":7}

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think when you enable PA you would need to query through 9600
https://opensearch.org/docs/latest/monitoring-your-cluster/pa/index/#example-api-query-and-response

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As mentioned above, I tried curling 9600, but no response. So this is why I went for 9200 at the end. Did anyone ever got this working?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You would need to separately start the PA process I think.
Not an expert on that tho.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

3 participants