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

ignore "CPU Util" #1

Closed
manajoe opened this issue Jul 6, 2023 · 3 comments
Closed

ignore "CPU Util" #1

manajoe opened this issue Jul 6, 2023 · 3 comments
Assignees
Labels
enhancement New feature or request

Comments

@manajoe
Copy link

manajoe commented Jul 6, 2023

Hi @jrbinks,
at first, thank you so much for your efforts to enable Rancid to grab the config of Aruba OS-Devices, in general it works like charm :-)

I had one "new" little issue, it seems to me, that it only happens since I installed ArubaOS-CX version 10.12.0006 on a switch.
Since then, I get two new lines:

"CPU Util (% avg 1 min) : 34"
"CPU Util (% avg 5 min) : 30"

in my Rancid config, which of course changes and generates new versions of the config.
With devices with older OS-versions I don't get this information.

I extended your arubaoscx.pm with the following lines after next if /^CPU Util \(%\)\s+: /;:
next if /^CPU Util \(% avg 1 min\)\s+: /; next if /^CPU Util \(% avg 5 min\)\s+: /;

I don't know if this is the best solution, maybe there is a smarter way to achieve this, but it worked ;-)

Thanks, maybe you would like to adapt your code or test for yourself

@jrbinks
Copy link
Owner

jrbinks commented Jul 6, 2023

Thanks, not running 10.12 anywhere yet.

I think this would be a neater change, added after the current CPU line (it would be possible to merge them, but in my view it gets harder to read):

        next if /^CPU Util \(% avg \d+ min\)\s+: /;

If you can test this and let me know if it is also OK for you, I will commit this change.

@jrbinks jrbinks added bug Something isn't working enhancement New feature or request and removed bug Something isn't working labels Jul 6, 2023
@jrbinks jrbinks self-assigned this Jul 6, 2023
@manajoe
Copy link
Author

manajoe commented Jul 6, 2023

Test successful, I substituted my two lines with your one-liner, works! You can commit the change.

Thanks again for your work!

@jrbinks
Copy link
Owner

jrbinks commented Jul 6, 2023

Now done, many thanks!

@jrbinks jrbinks closed this as completed Jul 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants