Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OKD v4.17.0-okd-scos.0 : Console > VolumeSnapshots > "Restore as new PVC": nothing happens... #2083

Closed
titou10titou10 opened this issue Jan 2, 2025 · 7 comments
Assignees

Comments

@titou10titou10
Copy link

With OKD v4.17.0-okd-scos.0 , after having created a Volume Snaphsot, at the console selecting "Restore a new PVC" menu entry on a VolumeSnapshot does not trigger anything
There is also no errors or whatever at the Firefox/Chrome console
vs (Petite)

@BeardOverflow
Copy link

I do work for me, but using rook ceph rbd/fs storage class. Could it be a limitation of nfs-truenas storage class?

@GingerGeek GingerGeek self-assigned this Jan 7, 2025
@titou10titou10
Copy link
Author

titou10titou10 commented Jan 8, 2025

IMHO it's a console problem
Possibly related to #2073

"restoring" the Snapshot into a PVC works, so StorageClass and VolumeSnapshotClass are OK:

apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: restore-pvc
spec:
  storageClassName: nfs-truenas
  dataSource:
    name: tekton-gradle-user-home-snapshot2
    kind: VolumeSnapshot
    apiGroup: snapshot.storage.k8s.io
  accessModes:
    - ReadWriteOnce
  resources:
    requests:
      storage: 10Gi

@GingerGeek
Copy link
Member

I think this is the relevant bit of the console code:
https://github.com/openshift/console/blob/master/frontend/public/components/utils/kebab.tsx#L429

Does a modal show?

@titou10titou10
Copy link
Author

Does a modal show?

No, nothing. And there is no error/messages whatsoever at the JavaScript Chrome/Firefox debug console
The other menus ("Edit labels", "Edit annotations", "Edit VolumeSnapshot", "Delete VolumeSnapshot") work well
Based on the code you pointed, my VS are "readytouse" as the menu is not disabled and there is no tooltip error message...
I search the code but didn't see what calls the RestorePVCmethod. Not familiar myself with Kebab...

@titou10titou10
Copy link
Author

titou10titou10 commented Jan 14, 2025

During my search, based on your comment, I found this code in actions/creators/pvc-factory.ts
The ids of theClonePVCandRestorePVC"functions" (?) are the same: clone-pvc
I have no idea what the consequence may be and in what circumstance this code is used...

https://github.com/openshift/console/blob/e72cc4c35f60ee3456985c00b4c2c42f28057af5/frontend/packages/console-app/src/actions/creators/pvc-factory.ts#L33C3-L56C6

  ClonePVC: (kind, obj) => ({
    id: 'clone-pvc',
    label: i18next.t('console-app~Clone PVC'),
    disabled: obj?.status?.phase !== 'Bound',
    tooltip: obj?.status?.phase !== 'Bound' ? i18next.t('console-app~PVC is not Bound') : '',
    cta: () =>
      clonePVCModal({
        kind,
        resource: obj,
      }),
    accessReview: asAccessReview(kind, obj, 'create'),
  }),
  RestorePVC: (kind, obj: VolumeSnapshotKind) => ({
    id: 'clone-pvc',
    label: i18next.t('console-app~Restore as new PVC'),
    disabled: !obj?.status?.readyToUse,
    tooltip: !obj?.status?.readyToUse ? i18next.t('console-app~Volume Snapshot is not Ready') : '',
    cta: () =>
      restorePVCModal({
        kind,
        resource: obj,
      }),
    accessReview: asAccessReview(kind, obj, 'create'),
  }),

But this seem more related to PVC, not VS...

@titou10titou10
Copy link
Author

The problem seems to be fixed in 4.18.0-okd-scos.ec.1

Image

@titou10titou10
Copy link
Author

Works also with v4.17.0-okd-scos.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants