Bug 1926019 - The reason of disk does not support snapshot is unreadable
Summary: The reason of disk does not support snapshot is unreadable
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Container Native Virtualization (CNV)
Classification: Red Hat
Component: Storage
Version: 2.6.0
Hardware: Unspecified
OS: Unspecified
medium
low
Target Milestone: ---
: 4.8.0
Assignee: Arnon Gilboa
QA Contact: Kevin Alon Goldblatt
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-02-08 03:40 UTC by Guohua Ouyang
Modified: 2021-07-27 14:25 UTC (History)
6 users (show)

Fixed In Version: virt-controller v4.8.0-22
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-07-27 14:23:09 UTC
Target Upstream Version:
Embargoed:
gouyang: needinfo-


Attachments (Terms of Use)
reason in vm status (6.27 KB, text/plain)
2021-02-08 03:40 UTC, Guohua Ouyang
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Github kubevirt kubevirt pull 5153 0 None open rephrase "No VolumeSnapshotClass" reason 2021-03-04 10:47:34 UTC
Red Hat Product Errata RHSA-2021:2920 0 None None None 2021-07-27 14:25:37 UTC

Description Guohua Ouyang 2021-02-08 03:40:46 UTC
Created attachment 1755595 [details]
reason in vm status

Description of problem:
When a disk is created with default storageClass "Standard", the disk does not support snapshot, but the reason message "No Volume Snapshot Storage Class found for volume" is almost unreadable.

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

How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Natalie Gavrielov 2021-02-17 13:39:38 UTC
Guohua, what do you think should be the expected result here?

Comment 2 Guohua Ouyang 2021-02-22 05:26:53 UTC
(In reply to Natalie Gavrielov from comment #1)
> Guohua, what do you think should be the expected result here?

Maybe "The Storage Class of the volume does not support snapshot"?

Comment 3 Ying Cui 2021-02-24 13:32:03 UTC
(In reply to Guohua Ouyang from comment #2)
> (In reply to Natalie Gavrielov from comment #1)
> > Guohua, what do you think should be the expected result here?
> 
> Maybe "The Storage Class of the volume does not support snapshot"?

"Unable to create snapshot because the Storage Class does not support snapshot"

Comment 4 Adam Litke 2021-02-24 18:52:34 UTC
How about "No VolumeSnapshotClass: Volume snapshots are not configured for this Storage Class"

Comment 6 Kevin Alon Goldblatt 2021-03-25 12:02:12 UTC
Verified with code:
---------------------------------------
oc version
Client Version: 4.8.0-202103242016.p0-314b90b
Server Version: 4.8.0-0.nightly-2021-03-24-235642
Kubernetes Version: v1.20.0+93f62ca

oc get csv -n openshift-cnv
NAME                                      DISPLAY                    VERSION   REPLACES                                  PHASE
kubevirt-hyperconverged-operator.v4.8.0   OpenShift Virtualization   4.8.0     kubevirt-hyperconverged-operator.v2.5.3   Succeeded

Verified with scenario:
---------------------------------------
1. Create a vm with the yaml in the attachment >>>> The correct error message is now displayed: "reason: 'No VolumeSnapshotClass: Volume snapshots are not configured for this"


Moving to VERIFIED!

Additional information:
---------------------------------------
oc get vm url -n test -oyaml
apiVersion: kubevirt.io/v1
kind: VirtualMachine
metadata:
  annotations:
    kubevirt.io/latest-observed-api-version: v1
    kubevirt.io/storage-observed-api-version: v1alpha3
    kubevirt.ui/firstBoot: "false"
    kubevirt.ui/pxeInterface: nic-0
    name.os.template.kubevirt.io/rhel6.10: Red Hat Enterprise Linux 6.0 or higher
    vm.kubevirt.io/flavor: small
    vm.kubevirt.io/os: rhel6
    vm.kubevirt.io/validations: |
      [
        {
          "name": "minimal-required-memory",
          "path": "jsonpath::.spec.domain.resources.requests.memory",
          "rule": "integer",
          "message": "This VM requires more memory.",
          "min": 536870912
        }
      ]
    vm.kubevirt.io/workload: server
  creationTimestamp: "2021-03-25T11:53:37Z"
  generation: 1
  labels:
    app: url
    flavor.template.kubevirt.io/small: "true"
    os.template.kubevirt.io/rhel6.10: "true"
    vm.kubevirt.io/template: rhel6-server-small
    vm.kubevirt.io/template.namespace: openshift
    vm.kubevirt.io/template.revision: "1"
    vm.kubevirt.io/template.version: v0.13.1
    workload.template.kubevirt.io/server: "true"
  managedFields:
  - apiVersion: kubevirt.io/v1alpha3
    fieldsType: FieldsV1
    fieldsV1:
      f:metadata:
        f:annotations:
          .: {}
          f:kubevirt.io/storage-observed-api-version: {}
          f:kubevirt.ui/firstBoot: {}
          f:kubevirt.ui/pxeInterface: {}
          f:name.os.template.kubevirt.io/rhel6.10: {}
          f:vm.kubevirt.io/flavor: {}
          f:vm.kubevirt.io/os: {}
          f:vm.kubevirt.io/validations: {}
          f:vm.kubevirt.io/workload: {}
        f:labels:
          .: {}
          f:app: {}
          f:flavor.template.kubevirt.io/small: {}
          f:os.template.kubevirt.io/rhel6.10: {}
          f:vm.kubevirt.io/template: {}
          f:vm.kubevirt.io/template.namespace: {}
          f:vm.kubevirt.io/template.revision: {}
          f:vm.kubevirt.io/template.version: {}
          f:workload.template.kubevirt.io/server: {}
      f:spec:
        .: {}
        f:dataVolumeTemplates: {}
        f:running: {}
        f:template:
          .: {}
          f:metadata:
            .: {}
            f:creationTimestamp: {}
            f:labels:
              .: {}
              f:flavor.template.kubevirt.io/small: {}
              f:kubevirt.io/domain: {}
              f:kubevirt.io/size: {}
              f:os.template.kubevirt.io/rhel6.10: {}
              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:rng: {}
                f:useVirtioTransitional: {}
              f:machine:
                .: {}
                f:type: {}
              f:resources:
                .: {}
                f:requests:
                  .: {}
                  f:memory: {}
            f:evictionStrategy: {}
            f:hostname: {}
            f:networks: {}
            f:terminationGracePeriodSeconds: {}
            f:volumes: {}
    manager: kubectl-create
    operation: Update
    time: "2021-03-25T11:53:37Z"
  - apiVersion: kubevirt.io/v1alpha3
    fieldsType: FieldsV1
    fieldsV1:
      f:metadata:
        f:annotations:
          f:kubevirt.io/latest-observed-api-version: {}
      f:status:
        .: {}
        f:created: {}
        f:volumeSnapshotStatuses: {}
    manager: virt-controller
    operation: Update
    time: "2021-03-25T11:53:37Z"
  name: url
  namespace: test
  resourceVersion: "159328"
  uid: 748ef356-5270-4c37-90e9-03d74f14bb85
spec:
  dataVolumeTemplates:
  - metadata:
      creationTimestamp: null
      name: url-rootdisk-install-77f23
    spec:
      pvc:
        accessModes:
        - ReadWriteOnce
        resources:
          requests:
            storage: 20Gi
        storageClassName: standard
        volumeMode: Filesystem
      source:
        blank: {}
  running: true
  template:
    metadata:
      creationTimestamp: null
      labels:
        flavor.template.kubevirt.io/small: "true"
        kubevirt.io/domain: url
        kubevirt.io/size: small
        os.template.kubevirt.io/rhel6.10: "true"
        vm.kubevirt.io/name: url
        workload.template.kubevirt.io/server: "true"
    spec:
      domain:
        cpu:
          cores: 1
          sockets: 1
          threads: 1
        devices:
          disks:
          - disk:
              bus: sata
            name: cloudinitdisk
          - bootOrder: 2
            disk:
              bus: virtio
            name: rootdisk-install
          interfaces:
          - masquerade: {}
            model: e1000e
            name: default
          - bootOrder: 1
            bridge: {}
            model: virtio
            name: nic-0
          rng: {}
          useVirtioTransitional: true
        machine:
          type: pc-q35-rhel8.3.0
        resources:
          requests:
            memory: 2Gi
      evictionStrategy: LiveMigrate
      hostname: url
      networks:
      - name: default
        pod: {}
      - multus:
          networkName: br1
        name: nic-0
      terminationGracePeriodSeconds: 180
      volumes:
      - cloudInitNoCloud:
          userData: |
            #cloud-config
            user: cloud-user
            password: i6e0-rndy-styd
            chpasswd:
              expire: false
        name: cloudinitdisk
      - dataVolume:
          name: url-rootdisk-install-77f23
        name: rootdisk-install
status:
  created: true
  volumeSnapshotStatuses:
  - enabled: false
    name: cloudinitdisk
    reason: Volume type has no StorageClass defined
  - enabled: false
    name: rootdisk-install
    reason: 'No VolumeSnapshotClass: Volume snapshots are not configured for this
      StorageClass [standard] [rootdisk-install]'

Comment 9 errata-xmlrpc 2021-07-27 14:23:09 UTC
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 Virtualization 4.8.0 Images), 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-2021:2920


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