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

feat: add turbostat plugin #1469

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

pimlie
Copy link
Contributor

@pimlie pimlie commented Jan 8, 2025

See embedded plugin docs for description etc

It might be weird that this is a multigraph plugin with only one graph, but wanted to be prepared for if I overlooked something other useful to monitoring using turbostat. Feel free to let me know if you have suggestions which graphs to add, but things like temperatures can already be monitored using the sensors_ plugin which uses the same source so imho not really useful to add those in this plugin too

Comment on lines 160 to 173
function in_array {
local e match
match="$1"
shift
for e; do [[ "$e" == "$match" ]] && return 0; done
return 1
}

# Join array elements by separator
function join {
local IFS="$1"
shift
echo "$*"
}
Copy link
Member

Choose a reason for hiding this comment

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

Indentation style for these two functions doesn't match the rest of the file. Do you want to fix that?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed, you got me copying code from SO instead of writing it myself ;)

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

Successfully merging this pull request may close these issues.

2 participants