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

High CPU usage on the switches when using the exporter #205

Open
ademenfis opened this issue Dec 8, 2022 · 2 comments
Open

High CPU usage on the switches when using the exporter #205

ademenfis opened this issue Dec 8, 2022 · 2 comments

Comments

@ademenfis
Copy link

Hi, I'm trying to use the exporter but I see the CPUs are spiking up when the scrape is happening.

Screenshot 2022-12-08 at 11 23 33

This shows the cpu usage since the target was added in week 39 has increased exponentially. I don't see anything particular in the switches logs.

Am I missing something? Should I enable some sort of caching in junos?

Thank you and sorry if this is not the right place to ask

@4xoc
Copy link
Contributor

4xoc commented Jan 12, 2023

Unfortunately this just happens and afaik cannot be avoided. Due to the nature of the exporter having to run multiple cli commands that, depending on hardware model, can cause a lot of cpu use. This should however not have a high impact, if any at all, for the performance of the device since the CPU usage is for the control plane only. Do fewer scrapes if a constant high cpu use is of concern to you.

@Nothing4You
Copy link
Contributor

considering the stated goal in the readme this is really baffling me:

The set of metrics is minimal to increase performance. We (a few friends from the Freifunk community and myself) used the generic snmp_exporter before. Since snmp_exporter is highly generic it comes with a lot of complexity at the cost of performance. We wanted to have an KIS and vendor specific exporter instead. This approach should allow us to scrape our metrics in a very time efficient way.

which performance is this supposed to increase?

i can see the configuration being much simpler and it being more flexible in the data available via CLI/RPC compared to what is available via snmp, as SNMP imposes some limitations e.g. in cluster scenarios, but the performance seems to be significantly worse, especially without using netconf (#190)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants