Great! I have installed the new kernel in my test VM.

I tested my original node_exporter in a local k8s cluster

Old, Linux 6.14.0-36-generic #36-Ubuntu SMP PREEMPT_DYNAMIC Sat Oct 11 02:18:29 
UTC 2025 x86_64 x86_64 x86_64 GNU/Linux
```
[...]
node_scrape_collector_duration_seconds{collector="perf"} 7.0563e-05
node_scrape_collector_success{collector="perf"} 1
[...]
```
No perf related metrics.

With the new kernel Linux k8s 6.14.0-37-generic #37-Ubuntu SMP PREEMPT_DYNAMIC 
Fri Nov 14 22:10:32 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux
```
# HELP node_perf_branch_instructions_total Number of CPU branch instructions
# TYPE node_perf_branch_instructions_total counter
node_perf_branch_instructions_total{cpu="0"} 1.07274662e+08
[...]
# HELP node_perf_branch_misses_total Number of CPU branch misses
# TYPE node_perf_branch_misses_total counter
node_perf_branch_misses_total{cpu="0"} 8.273487e+06
[...]
# HELP node_perf_cache_misses_total Number of cache misses
# TYPE node_perf_cache_misses_total counter
node_perf_cache_misses_total{cpu="0"} 1.4965659e+07
[...]
node_scrape_collector_duration_seconds{collector="perf"} 0.004012192
node_scrape_collector_success{collector="perf"} 1
```

I also ran the reproducer code on 6.14.0-36-generic #36-Ubuntu SMP 
PREEMPT_DYNAMIC Sat Oct 11 02:18:29 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux
```
[*] Current perf_event_paranoid level: 4.
[*] This is a custom Ubuntu paranoid level.

[*] Current capabilities: cap_wake_alarm=i cap_perfmon+ep

[!] CPU_CYCLES: Impossible to open perf event
[!] INSTRUCTIONS: Impossible to open perf event
[!] CACHE_REFERENCES: Impossible to open perf event

Some events were not accessible with current capabilities
```

and on Linux k8s 6.14.0-37-generic #37-Ubuntu SMP PREEMPT_DYNAMIC Fri Nov 14 
22:10:32 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux
```
[*] Current perf_event_paranoid level: 4.
[*] This is a custom Ubuntu paranoid level.

[*] Current capabilities: cap_wake_alarm=i cap_perfmon+ep

[*] CPU_CYCLES: Successfully opened perf event
[*] INSTRUCTIONS: Successfully opened perf event
[*] CACHE_REFERENCES: Successfully opened perf event

All perf events accessible with current capabilities
```

So this works as intended for my usecase.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2131046

Title:
  CAP_PERFMON insufficient to get perf data

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/2131046/+subscriptions


-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to