Bug 1917124
| Summary: | Custom template - clone existing PVC - the name of the target VM's data volume is hard-coded; only one VM can be created | ||||||
|---|---|---|---|---|---|---|---|
| Product: | OpenShift Container Platform | Reporter: | Ruth Netser <rnetser> | ||||
| Component: | Console Kubevirt Plugin | Assignee: | Rastislav Wagner <rawagner> | ||||
| Status: | CLOSED ERRATA | QA Contact: | Guohua Ouyang <gouyang> | ||||
| Severity: | urgent | Docs Contact: | |||||
| Priority: | urgent | ||||||
| Version: | 4.7 | CC: | aos-bugs, gouyang, rawagner, yzamir | ||||
| Target Milestone: | --- | ||||||
| Target Release: | 4.7.0 | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | Doc Type: | No Doc Update | |||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2021-02-24 15:53:53 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: | |||||||
| Attachments: |
|
||||||
|
Description
Ruth Netser
2021-01-17 11:54:56 UTC
1st VM yaml:
apiVersion: kubevirt.io/v1alpha3
kind: VirtualMachine
metadata:
annotations:
kubevirt.io/latest-observed-api-version: v1alpha3
kubevirt.io/storage-observed-api-version: v1alpha3
name.os.template.kubevirt.io/rhel8.3: Red Hat Enterprise Linux 8.0 or higher
vm.kubevirt.io/flavor: small
vm.kubevirt.io/os: rhel8
vm.kubevirt.io/validations: |
[
{
"name": "minimal-required-memory",
"path": "jsonpath::.spec.domain.resources.requests.memory",
"rule": "integer",
"message": "This VM requires more memory.",
"min": 1610612736
}
]
vm.kubevirt.io/workload: server
selfLink: >-
/apis/kubevirt.io/v1alpha3/namespaces/default/virtualmachines/ten-dv-imaginative-carp
resourceVersion: '5014253'
name: ten-dv-imaginative-carp
uid: fb29224b-7cb9-4f77-b381-8f780dacbc93
creationTimestamp: '2021-01-17T11:09:00Z'
generation: 1
managedFields:
- apiVersion: kubevirt.io/v1alpha3
fieldsType: FieldsV1
fieldsV1:
'f:metadata':
'f:annotations':
.: {}
'f:name.os.template.kubevirt.io/rhel8.3': {}
'f:vm.kubevirt.io/flavor': {}
'f:vm.kubevirt.io/os': {}
'f:vm.kubevirt.io/validations': {}
'f:vm.kubevirt.io/workload': {}
'f:labels':
'f:vm.kubevirt.io/template.version': {}
'f:os.template.kubevirt.io/rhel8.3': {}
'f:vm.kubevirt.io/template.namespace': {}
'f:app': {}
.: {}
'f:vm.kubevirt.io/template.revision': {}
'f:workload.template.kubevirt.io/server': {}
'f:flavor.template.kubevirt.io/small': {}
'f:vm.kubevirt.io/template': {}
'f:spec':
.: {}
'f:dataVolumeTemplates': {}
'f:running': {}
'f:template':
.: {}
'f:metadata':
.: {}
'f:labels':
.: {}
'f:flavor.template.kubevirt.io/small': {}
'f:kubevirt.io/domain': {}
'f:kubevirt.io/size': {}
'f:os.template.kubevirt.io/rhel8.3': {}
'f:vm.kubevirt.io/name': {}
'f:workload.template.kubevirt.io/server': {}
'f:spec':
.: {}
'f:domain':
.: {}
'f:cpu':
.: {}
'f:cores': {}
'f:sockets': {}
'f:threads': {}
'f:devices':
.: {}
'f:disks': {}
'f:interfaces': {}
'f:networkInterfaceMultiqueue': {}
'f:rng': {}
'f:machine':
.: {}
'f:type': {}
'f:resources':
.: {}
'f:requests':
.: {}
'f:memory': {}
'f:evictionStrategy': {}
'f:hostname': {}
'f:networks': {}
'f:terminationGracePeriodSeconds': {}
'f:volumes': {}
manager: Mozilla
operation: Update
time: '2021-01-17T11:09:00Z'
- apiVersion: kubevirt.io/v1alpha3
fieldsType: FieldsV1
fieldsV1:
'f:metadata':
'f:annotations':
'f:kubevirt.io/latest-observed-api-version': {}
'f:kubevirt.io/storage-observed-api-version': {}
'f:status':
.: {}
'f:volumeSnapshotStatuses': {}
manager: virt-controller
operation: Update
time: '2021-01-17T11:09:00Z'
namespace: default
labels:
app: ten-dv-imaginative-carp
flavor.template.kubevirt.io/small: 'true'
os.template.kubevirt.io/rhel8.3: 'true'
vm.kubevirt.io/template: ten-dv
vm.kubevirt.io/template.namespace: default
vm.kubevirt.io/template.revision: '1'
vm.kubevirt.io/template.version: v0.13.0
workload.template.kubevirt.io/server: 'true'
spec:
dataVolumeTemplates:
- metadata:
creationTimestamp: null
name: ten-dv-rootdisk
spec:
pvc:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 15Gi
storageClassName: standard
volumeMode: Filesystem
source:
pvc:
name: fedora-dv-n
namespace: default
running: false
template:
metadata:
creationTimestamp: null
labels:
flavor.template.kubevirt.io/small: 'true'
kubevirt.io/domain: ten-dv-imaginative-carp
kubevirt.io/size: small
os.template.kubevirt.io/rhel8.3: 'true'
vm.kubevirt.io/name: ten-dv-imaginative-carp
workload.template.kubevirt.io/server: 'true'
spec:
domain:
cpu:
cores: 1
sockets: 1
threads: 1
devices:
disks:
- disk:
bus: virtio
name: cloudinitdisk
- bootOrder: 1
disk:
bus: virtio
name: rootdisk
interfaces:
- masquerade: {}
model: virtio
name: default
networkInterfaceMultiqueue: true
rng: {}
machine:
type: pc-q35-rhel8.3.0
resources:
requests:
memory: 2Gi
evictionStrategy: LiveMigrate
hostname: ten-dv-imaginative-carp
networks:
- name: default
pod: {}
terminationGracePeriodSeconds: 180
volumes:
- cloudInitNoCloud:
userData: |
#cloud-config
user: cloud-user
password: fg8n-6tzp-qig0
chpasswd:
expire: false
name: cloudinitdisk
- dataVolume:
name: ten-dv-rootdisk
name: rootdisk
status:
volumeSnapshotStatuses:
- enabled: false
name: cloudinitdisk
reason: Volume type does not suport snapshots
- enabled: false
name: rootdisk
reason: 'No Volume Snapshot Storage Class found for volume [rootdisk]'
2nd VM yaml:
apiVersion: kubevirt.io/v1alpha3
kind: VirtualMachine
metadata:
annotations:
kubevirt.io/latest-observed-api-version: v1alpha3
kubevirt.io/storage-observed-api-version: v1alpha3
name.os.template.kubevirt.io/rhel8.3: Red Hat Enterprise Linux 8.0 or higher
vm.kubevirt.io/flavor: small
vm.kubevirt.io/os: rhel8
vm.kubevirt.io/validations: |
[
{
"name": "minimal-required-memory",
"path": "jsonpath::.spec.domain.resources.requests.memory",
"rule": "integer",
"message": "This VM requires more memory.",
"min": 1610612736
}
]
vm.kubevirt.io/workload: server
selfLink: >-
/apis/kubevirt.io/v1alpha3/namespaces/default/virtualmachines/ten-dv-external-horse
resourceVersion: '5014716'
name: ten-dv-external-horse
uid: b2bbb621-99e0-463c-9f54-09de45e3bfcc
creationTimestamp: '2021-01-17T11:09:39Z'
generation: 1
managedFields:
- apiVersion: kubevirt.io/v1alpha3
fieldsType: FieldsV1
fieldsV1:
'f:metadata':
'f:annotations':
.: {}
'f:name.os.template.kubevirt.io/rhel8.3': {}
'f:vm.kubevirt.io/flavor': {}
'f:vm.kubevirt.io/os': {}
'f:vm.kubevirt.io/validations': {}
'f:vm.kubevirt.io/workload': {}
'f:labels':
'f:vm.kubevirt.io/template.version': {}
'f:os.template.kubevirt.io/rhel8.3': {}
'f:vm.kubevirt.io/template.namespace': {}
'f:app': {}
.: {}
'f:vm.kubevirt.io/template.revision': {}
'f:workload.template.kubevirt.io/server': {}
'f:flavor.template.kubevirt.io/small': {}
'f:vm.kubevirt.io/template': {}
'f:spec':
.: {}
'f:dataVolumeTemplates': {}
'f:running': {}
'f:template':
.: {}
'f:metadata':
.: {}
'f:labels':
.: {}
'f:flavor.template.kubevirt.io/small': {}
'f:kubevirt.io/domain': {}
'f:kubevirt.io/size': {}
'f:os.template.kubevirt.io/rhel8.3': {}
'f:vm.kubevirt.io/name': {}
'f:workload.template.kubevirt.io/server': {}
'f:spec':
.: {}
'f:domain':
.: {}
'f:cpu':
.: {}
'f:cores': {}
'f:sockets': {}
'f:threads': {}
'f:devices':
.: {}
'f:disks': {}
'f:interfaces': {}
'f:networkInterfaceMultiqueue': {}
'f:rng': {}
'f:machine':
.: {}
'f:type': {}
'f:resources':
.: {}
'f:requests':
.: {}
'f:memory': {}
'f:evictionStrategy': {}
'f:hostname': {}
'f:networks': {}
'f:terminationGracePeriodSeconds': {}
'f:volumes': {}
manager: Mozilla
operation: Update
time: '2021-01-17T11:09:39Z'
- apiVersion: kubevirt.io/v1alpha3
fieldsType: FieldsV1
fieldsV1:
'f:metadata':
'f:annotations':
'f:kubevirt.io/latest-observed-api-version': {}
'f:kubevirt.io/storage-observed-api-version': {}
'f:status':
.: {}
'f:conditions': {}
'f:volumeSnapshotStatuses': {}
manager: virt-controller
operation: Update
time: '2021-01-17T11:09:39Z'
namespace: default
labels:
app: ten-dv-external-horse
flavor.template.kubevirt.io/small: 'true'
os.template.kubevirt.io/rhel8.3: 'true'
vm.kubevirt.io/template: ten-dv
vm.kubevirt.io/template.namespace: default
vm.kubevirt.io/template.revision: '1'
vm.kubevirt.io/template.version: v0.13.0
workload.template.kubevirt.io/server: 'true'
spec:
dataVolumeTemplates:
- metadata:
creationTimestamp: null
name: ten-dv-rootdisk
spec:
pvc:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 15Gi
storageClassName: standard
volumeMode: Filesystem
source:
pvc:
name: fedora-dv-n
namespace: default
running: false
template:
metadata:
creationTimestamp: null
labels:
flavor.template.kubevirt.io/small: 'true'
kubevirt.io/domain: ten-dv-external-horse
kubevirt.io/size: small
os.template.kubevirt.io/rhel8.3: 'true'
vm.kubevirt.io/name: ten-dv-external-horse
workload.template.kubevirt.io/server: 'true'
spec:
domain:
cpu:
cores: 1
sockets: 1
threads: 1
devices:
disks:
- disk:
bus: virtio
name: cloudinitdisk
- bootOrder: 1
disk:
bus: virtio
name: rootdisk
interfaces:
- masquerade: {}
model: virtio
name: default
networkInterfaceMultiqueue: true
rng: {}
machine:
type: pc-q35-rhel8.3.0
resources:
requests:
memory: 2Gi
evictionStrategy: LiveMigrate
hostname: ten-dv-external-horse
networks:
- name: default
pod: {}
terminationGracePeriodSeconds: 180
volumes:
- cloudInitNoCloud:
userData: |
#cloud-config
user: cloud-user
password: fg8n-6tzp-qig0
chpasswd:
expire: false
name: cloudinitdisk
- dataVolume:
name: ten-dv-rootdisk
name: rootdisk
status:
conditions:
- lastProbeTime: null
lastTransitionTime: '2021-01-17T11:09:39Z'
message: >-
Failed to create DataVolume: datavolumes.cdi.kubevirt.io
"ten-dv-rootdisk" already exists
reason: FailedDelete
status: 'True'
type: Failure
volumeSnapshotStatuses:
- enabled: false
name: cloudinitdisk
reason: Volume type does not suport snapshots
- enabled: false
name: rootdisk
reason: 'No Volume Snapshot Storage Class found for volume [rootdisk]'
Setting to blocker+, this bug will block a normal the flow of creating a VM by none admin user, without a simple workaround. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (Moderate: OpenShift Container Platform 4.7.0 security, bug fix, and enhancement update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2020:5633 |