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

riemann-net: Initial packet drop not reported as warning #179

Open
sslavic opened this issue Jul 20, 2017 · 2 comments
Open

riemann-net: Initial packet drop not reported as warning #179

sslavic opened this issue Jul 20, 2017 · 2 comments

Comments

@sslavic
Copy link
Contributor

sslavic commented Jul 20, 2017

Issue

What's the issue...?
If there are packets dropped on boot, riemann-net will measure dropped packets count as initial value, but since there's no old/previous value, warning will not be reported.

I believe https://github.com/riemann/riemann-tools/blob/master/bin/riemann-net#L77
should be replaced with something like

    if not @old_state.has_key?(service)
      @old_state[service] = 0
    end

What's your riemann-tools version?

0.2.6 but same logic is on trunk

What platform are you on?

Ubuntu 14.04.5 LTS (GNU/Linux 4.4.0-66-generic x86_64)

@jamtur01
Copy link
Member

Seems reasonable - happy to take a patch on this.

@smortex
Copy link
Member

smortex commented Oct 21, 2022

I feel concerned about this one: if a system has a non-zero error count, each time riemann-net start it will send a critical event. So a single error can end up reported multiple times, which is not good, and I think worse that not reporting an error that happened in the past.

Also, beyond the error metrics, and because they are rates, the initial value when riemann-net restart will be wrong (because the value is divided by the interval, and instead of a count from the last event, the value is a count from system boot). Adjusting this special case to divide by the system uptime is also likely to create a metric which is multiple orders of magnitude offset to the actual rate at the time riemann-net started.

So the current behavior of not sending the first batch of events seems a sensible choice.

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