Bug 2213272 - The metric for the alert LowKVMNodesCount cannot fired
Summary: The metric for the alert LowKVMNodesCount cannot fired
Keywords:
Status: ASSIGNED
Alias: None
Product: Container Native Virtualization (CNV)
Classification: Red Hat
Component: Virtualization
Version: 4.13.0
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: 4.15.0
Assignee: sgott
QA Contact: Kedar Bidarkar
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-06-07 17:11 UTC by Ohad
Modified: 2023-07-19 13:00 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed:
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker CNV-29501 0 None None None 2023-06-07 17:17:07 UTC

Description Ohad 2023-06-07 17:11:02 UTC
Description of problem:
The rule for producing the alert LowKVMNodesCount will never fire the alarm because the rule for this alert: 
(kubevirt_allocatable_nodes_count > 1) and (kubevirt_kvm_available_nodes_count < 2)
the kubevirt_allocatable_nodes_count  counts all nodes as allocatable including the master nodes.
The kubevirt_kvm_available_nodes_count expression is: intstr.FromString("kubevirt_allocatable_nodes_count - count(kube_node_status_allocatable{resource=\"devices_kubevirt_io_kvm\"} == 0)")

This expression will give us 3 so the alert will never fire

Comment 1 Krzysztof Majcher 2023-06-13 12:47:26 UTC
Assaf, can you please check which component this alert belongs to?

Comment 2 Assaf Admi 2023-06-13 13:09:19 UTC
Hi Krzysztof, it is coming from kubevirt - https://github.com/kubevirt/kubevirt/blob/main/pkg/virt-operator/resource/generate/components/prometheus.go#L135.


Note You need to log in before you can comment on or make changes to this bug.