Bug 1659976 - Default storage class shows false even it is true
Summary: Default storage class shows false even it is true
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Management Console
Version: 3.11.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
: 3.11.z
Assignee: Samuel Padgett
QA Contact: shahan
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-12-17 10:03 UTC by Radomir Ludva
Modified: 2022-03-13 16:32 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Previously, the 3.11 admin console did not correctly display whether a storage class was the default storage class since it was checking an out-of-date annotation value. The admin console has been updated to use the `storageclass.kubernetes.io/is-default-class=true` annotation, and service classes are now properly marked as default when that value is set.
Clone Of:
Environment:
Last Closed: 2019-02-20 14:11:02 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2019:0326 0 None None None 2019-02-20 14:11:09 UTC

Description Radomir Ludva 2018-12-17 10:03:51 UTC
Description of problem:
The customer has two storage classes:
$ cat glusterfs-storage.yaml
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
  annotations:
    storageclass.kubernetes.io/is-default-class: "true"
  creationTimestamp: null
  name: glusterfs-storage
  selfLink: /apis/storage.k8s.io/v1/storageclasses/glusterfs-storage
parameters:
  resturl: http://heketi-storage.app-storage.svc:8080
  restuser: admin
  secretName: heketi-storage-admin-secret
  secretNamespace: app-storage
provisioner: kubernetes.io/glusterfs
reclaimPolicy: Delete
volumeBindingMode: Immediate

$ cat glusterfs-storage-block.yaml
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
  creationTimestamp: null
  name: glusterfs-storage-block
  selfLink: /apis/storage.k8s.io/v1/storageclasses/glusterfs-storage-block
parameters:
  chapauthenabled: "true"
  hacount: "3"
  restsecretname: heketi-storage-admin-secret-block
  restsecretnamespace: app-storage
  resturl: http://heketi-storage.app-storage.svc:8080
  restuser: admin
provisioner: gluster.org/glusterblock
reclaimPolicy: Delete
volumeBindingMode: Immediate

Cluster Console: Default storageclass always shows false even if I change it to true.

Version-Release number of selected component (if applicable):
OCP v3.11.43

How reproducible:
Create a storage class for example:

$ cat mstorageclass.yaml
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
  name: mstorageclass
  annotations:
    storageclass.kubernetes.io/is-default-class: "true"
provisioner: kubernetes.io/manual

$ oc create -f mstorageclass.yaml

Steps to Reproduce:
1. OpenShift Console -> Cluster Console -> Storage -> Storage Classes
2. mstorageclass -> Edit Annotations -> [True] => DEFAULT CLASS is false
3. $ oc describe storageclass mstorageclass // shows is default Yes but in Cluster Console is false..
oc describe storageclass mstorageclass
Name:                  mstorageclass
IsDefaultClass:        Yes
Annotations:           storageclass.kubernetes.io/is-default-class=true
Provisioner:           kubernetes.io/manual
Parameters:            <none>
AllowVolumeExpansion:  <unset>
MountOptions:          <none>
ReclaimPolicy:         Delete
VolumeBindingMode:     Immediate
Events:                <none>

Expected results:
To be true default storage class in cluster console

Comment 1 Samuel Padgett 2018-12-17 13:39:42 UTC
This is fixed in 4.0. Backporting the fix.

https://github.com/openshift/console/pull/958

Comment 4 Samuel Padgett 2019-01-24 19:32:48 UTC
The previous 3.11 PR was replaced with

https://github.com/openshift/console/pull/858

Comment 6 shahan 2019-02-11 10:10:47 UTC
StorageClass default status is true when setting     storageclass.kubernetes.io/is-default-class: "true"
brewregistry.stage.redhat.io/openshift3/ose-console                   v3.11               21e477ce12d8        3 hours ago         254 MB
openshift v3.11.82
verified this bug

Comment 8 errata-xmlrpc 2019-02-20 14:11:02 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, 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/RHBA-2019:0326


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