datashim icon indicating copy to clipboard operation
datashim copied to clipboard

After reinstallation, I have a problem with new datasets

Open nikitok opened this issue 2 years ago • 1 comments

Hi, after problem with my clusterm i reinstall datashim, and now, i can't create new pvc with this yaml

kind: Dataset
metadata:
  name: example-dataset
spec:
  local:
    type: "COS"
...

Kuber doesnot create pvc, and i found logs:

"create not allowed while custom resource definition is terminating"

Do you know, what is happened and how it resolve?

nikitok avatar Feb 07 '23 20:02 nikitok

@nikitok It might be that you had datasets that were still present when you reinstalled datashim. Because of this, the CRD associated with your previous installation has not been deleted. This is how you can solve this issue:

  1. Find if there any datasets and datasetinternals objects that are still lingering around: kubectl get datasets --all-namespaces kubectl get datasetsinternal --all-namespaces
  2. Ensure that any pods that are mounting these datasets have exited. The PVCs cannot be deleted while the volumes are still mounted
  3. Delete the objects you have found in step 1.
  4. At this point, the CRD should've been terminated. You can check it by: kubectl get customresourcedefinitions.apiextensions.k8s.io -n dlf If the CRDs are still around, try removing the finalisers like so: kubectl patch datasetsinternal.com.ie.ibm.hpsys -p '{"metadata":{"finalizers":[]}}' --type=merge
  5. Delete the entire datashim installation for good measure and reinstall again. Check the status of the CRDs before creating a dataset

Let us know how it goes.

srikumar003 avatar Feb 08 '23 14:02 srikumar003