Icinga / Icinga/icinga2

icinga2 forcefully applies the last prefix to perfdata that does not follow the powershell like perfsdata name structure.

Open
#10,489 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

area/documentation area/metrics
Dominant language
C++
Stars
2.2k
Forks
616
Avg merge
5d 6h
Merged PRs (30d)
10

Description

Describe the bug

If you use an icinga powershell like perfdata name structure icinga2 forcefully applies the last prefix to perfdata that does not follow the structure.

To Reproduce

use this as perfdata:

testa::ifw_something::test2=2 testb::ifw_something::test2=2 testc=3

Image

results in:

Image

testc=3 will be prefixed with testb::ifw_something::

Expected behavior

Do not change perfdata names

Your Environment

Include as many relevant details about the environment you experienced the problem in

  • Version used (icinga2 --version): 2.15, but I thing this behaviour is way older
  • Operating System and version: 24.04
  • Enabled features (icinga2 feature list):
  • Icinga Web 2 version and modules (System - About): 2.12.4

Best Regards

Nicolas

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No source file or test is named. First reproduce the behavior with the provided perfdata string, then trace the perfdata parsing and prefix-handling entry points to find why testc=3 inherits the previous prefix. Done means mixed perfdata names remain unchanged, with a regression test covering the example.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
observability
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.