-
Bug
-
Resolution: Done-Errata
-
Normal
-
None
-
False
-
-
False
-
CLOSED
-
---
-
---
-
-
-
Storage Core Sprint 233
-
Medium
-
None
Description of problem:
Create a custom dataImportCronTemplate on HCO cr:
dataImportCronTemplates:
- metadata:
name: my-centos-stream8-image-cron
spec:
garbageCollect: Outdated
managedDataSource: my-centos-stream8
schedule: 0 */12 * * *
template:
spec:
source:
registry:
url: docker://quay.io/containerdisks/centos-stream:8
storage:
resources:
requests:
storage: 10Gi
without setting there:
- metadata:
annotations:
cdi.kubevirt.io/storage.bind.immediate.requested: "true"
if the storage classes of che cluster are configured with WaitForFirstConsumer,
the PVC for the golden image will never be bound waiting forever in WaitForFirstConsumer.
The workaround for this is explicitly setting:
- metadata:
annotations:
cdi.kubevirt.io/storage.bind.immediate.requested: "true"
on the dataImportCronTemplate
But this works only if done at the creation of the dataImportCronTemplate while if it's simply added later on it's not going to be propagated down do the DataVolume that is going to be stuck forever as the PVC and as the dataImportCron.
Currently the only option is explicitly deleting the DataVolume,
only in this case it will get recreated with:
apiVersion: cdi.kubevirt.io/v1beta1
kind: DataVolume
metadata:
annotations:
cdi.kubevirt.io/storage.bind.immediate.requested: "true"
cdi.kubevirt.io/storage.deleteAfterCompletion: "true"
and only now the PVC will be finally bound on the storage class with WaitForFirstConsumer.
Version-Release number of selected component (if applicable):
4.12.0
How reproducible:
100%
Steps to Reproduce:
1. deploy a cluster with a single storage class configured with VOLUMEBINDINGMODE=WaitForFirstConsumer
2. add a custom dataImportCronTemplate on HCO without explicitly setting the annotation cdi.kubevirt.io/storage.bind.immediate.requested=true
3. amend the dataImportCronTemplate setting cdi.kubevirt.io/storage.bind.immediate.requested=true
Actual results:
the DiC controller is not going to propagate the annotation down to the DataVolume that is going to be stuck forever in WaitForFirstConsumer
Expected results:
the DiC controller should amend or eventually recreate the DataVolume propagating there the cdi.kubevirt.io/storage.bind.immediate.requested=true annotation so that the PVC could be finally bound.
Additional info:
- blocks
-
CNV-27206 [2180801] [4.12]cdi.kubevirt.io/storage.bind.immediate.requested is not propagated down to the DataVolume if set on an existing DataImportCronTemplate
- Closed
- external trackers