Bug 2041865

Summary: [RFE] virtualization overview page top consumers fall back to pod name when vm name is missing
Product: OpenShift Container Platform Reporter: Yaacov Zamir <yzamir>
Component: Console Kubevirt PluginAssignee: Phillip Bailey <phbailey>
Status: CLOSED DEFERRED QA Contact: Guohua Ouyang <gouyang>
Severity: medium Docs Contact:
Priority: medium    
Version: 4.10CC: aos-bugs, sradco, tnisan
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2023-03-09 01:11:19 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Yaacov Zamir 2022-01-18 12:16:48 UTC
Description of problem:
Some top consumers will be wrongly labeled and missing vm name in prometheus
see: https://bugzilla.redhat.com/show_bug.cgi?id=2033346

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.create a VMI
2.go to overview page
3.look for the VMI in the top consumer card

Actual results:
pod name is used instead of the missing vmi name

Expected results:
the VMI or VM (if exist) name is used

Additional info:
https://bugzilla.redhat.com/show_bug.cgi?id=2033346

Comment 1 Shirly Radco 2022-01-20 12:06:21 UTC
Note for QE: We must test this in scale to make sure it doesnt create to much load.
Around 2,500 VMs should be ok for the test (The amount that Sahibinden are running).

Comment 3 Shirly Radco 2022-02-10 10:50:30 UTC
We found another issue with the vm name label that will affect the overview dashboard.
If a VM was cloned the vm_name label is not updated and will have the value of the previous VM. 
This can result in many VMs with the same vm_name label value and in the dashboard you will incorrect data.

I asked João Vilaça to fixed the code, so that we don't check if the label is there and always override it if its there.
We need to check if we can fix the labels retroactively to all existing VMs.
And also ask to fix during the new VM creation the template, so that this label will be updated with the correct value.

Due to this I believe we must calculate the vm_name based on the pod name,
**for all the panels that use container metrics**, until this is fixed.

Comment 4 Phillip Bailey 2022-10-26 13:47:49 UTC
"We found another issue with the vm name label that will affect the overview dashboard.
If a VM was cloned the vm_name label is not updated and will have the value of the previous VM. 
This can result in many VMs with the same vm_name label value and in the dashboard you will incorrect data.

I asked João Vilaça to fixed the code, so that we don't check if the label is there and always override it if its there.
We need to check if we can fix the labels retroactively to all existing VMs.
And also ask to fix during the new VM creation the template, so that this label will be updated with the correct value."

@sradco Has this issue been fixed? If so, can you tell me what changes need to be made to the existing queries to ensure they don't fall back on the pod name?

Comment 5 Shiftzilla 2023-03-09 01:11:19 UTC
OpenShift has moved to Jira for its defect tracking! This bug can now be found in the OCPBUGS project in Jira.

https://issues.redhat.com/browse/OCPBUGS-9080

Comment 6 Red Hat Bugzilla 2023-09-18 04:30:23 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 120 days