Bug 2216093 - "error","msg":"No disk capacity" logging continuously in virt-launcher pod
Summary: "error","msg":"No disk capacity" logging continuously in virt-launcher pod
Keywords:
Status: POST
Alias: None
Product: Container Native Virtualization (CNV)
Classification: Red Hat
Component: Virtualization
Version: 4.13.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
: 4.15.0
Assignee: sgott
QA Contact: Kedar Bidarkar
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-06-20 05:55 UTC by nijin ashok
Modified: 2023-07-03 21:03 UTC (History)
0 users

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
Github kubevirt kubevirt pull 9999 0 None open Only enable expandDisksEnabled on PVC volumes 2023-06-29 08:19:54 UTC
Red Hat Issue Tracker CNV-30086 0 None None None 2023-06-20 05:56:51 UTC

Description nijin ashok 2023-06-20 05:55:14 UTC
Description of problem:

The cloud-init disk will not have "capacity" defined in the disk xml:

~~~
bas64 -d of Domain xml from the virt-launcher logs:


		<disk device="disk" type="block" model="virtio-non-transitional">
			<source dev="/dev/rootdisk" name="rootdisk"></source>
			<target bus="virtio" dev="vda"></target>
			<driver cache="none" error_policy="stop" io="native" name="qemu" type="raw" discard="unmap"></driver>
			<alias name="ua-rootdisk"></alias>
			<boot order="1"></boot>
			<filesystemOverhead>0</filesystemOverhead>
			<capacity>32212254720</capacity>
			<expandDisksEnabled>true</expandDisksEnabled>
		</disk>



		<disk device="disk" type="file" model="virtio-non-transitional">
			<source file="/var/run/kubevirt-ephemeral-disks/cloud-init-data/nijin-cnv/rhel8-i181f1yxkfqqrv83/noCloud.iso"></source>
			<target bus="virtio" dev="vdb"></target>
			<driver cache="none" error_policy="stop" name="qemu" type="raw" discard="unmap"></driver>
			<alias name="ua-cloudinitdisk"></alias>              <<<
			<boot order="2"></boot>
			<expandDisksEnabled>true</expandDisksEnabled>
		</disk>
~~~

This is expected since the capacity is obtained from "volumeStatus.PersistentVolumeClaimInfo" and the cloud-init doesn't have an associated PVC.

~~~
oc get vmi  rhel8-i181f1yxkfqqrv83 -o yaml |yq '.status.volumeStatus'
- name: cloudinitdisk
  size: 1048576
  target: vdb
- name: rootdisk
  persistentVolumeClaimInfo:
    accessModes:
      - ReadWriteMany
    capacity:
      storage: 30Gi
    filesystemOverhead: "0"
    requests:
      storage: "32212254720"
    volumeMode: Block
  target: vda
~~~

However, both offline and online disk extension monitor also look at the the cloudinit disk, and since it doesn't contains "capacity", it logs the below message repeatedly:

~~~
{"component":"virt-launcher","level":"error","msg":"No disk capacity","pos":"manager.go:684","timestamp":"2023-06-20T05:43:37.728102Z"}

# oc logs virt-launcher-rhel8-i181f1yxkfqqrv83-n2fzf |grep "No disk capacity" |wc -l
18
~~~



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

OpenShift Virtualization 4.13.0

How reproducible:

100%

Steps to Reproduce:

1. Start a VM with a cloud-init disk.
2. Watch the virt-launcher logs. It continuously logs "No disk capacity" error.

Actual results:

"error","msg":"No disk capacity" logging continuously in virt-launcher pod


Expected results:

Don't try to expand the cloud-init disk.


Additional info:

Comment 1 nijin ashok 2023-06-20 06:24:57 UTC
The same error will be logged if the VM has configmap or secret volumes.

Comment 2 Kedar Bidarkar 2023-06-21 12:35:22 UTC
Target version is set to 4.15 depending upon the severity of the bug. Currently it appears to be a log message only issue.


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