Skip to content

Feature request: expose linux softirq counters #2220

@jacobvosmaer

Description

@jacobvosmaer

Linux has counters in /proc that show how often different kinds of softirq handlers run. We would like to see these counters to get a hint of where the kernel is spending time in a recurring incident we see on some of our servers. Node_exporter currently does not expose these counters.

There are two ways we could add the counters.

  • /proc/stat. In prometheus/procfs, we already parse the softirq line of that file, which gives global softirq counts.
  • /proc/softirqs. This file gives counts per CPU.

I don't have a preference whether we expose the global counters or the per-CPU counters. Exposing the global counters is less development work (we already parse /proc/stat) and it saves a syscall. On the other hand, if somewhere down the line someone wants to see the per-cpu counters, it would be better if we spend our time exposing the per-CPU counters from the start.

  1. If I were to submit a PR, should it be with the global counters, or per-CPU?
  2. Does this fit under an existing collector, or should we add a new one?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions