Change StorageClass of an already running cluster

Hello, i am trying to use suggested method here Change StorageClass of an already running cluster

I changed nodeset name and storage class. And i see next

elasticsearch-data-common-cluster-es-data-0           Bound    pvc-7116dd9a-7783-4599-868f-bd657f0ae20c   1500Gi     RWO            ebs-gp3        93d
elasticsearch-data-common-cluster-es-data-1           Bound    pvc-d66d00bf-b84d-41a0-90d9-1b31cb375b2f   1500Gi     RWO            ebs-gp3        93d
elasticsearch-data-common-cluster-es-data-2           Bound    pvc-f5c638c2-a1f7-40df-9c5d-7194b3ce888b   1500Gi     RWO            ebs-gp3        93d
elasticsearch-data-common-cluster-es-datav2-0         Bound    pvc-3fb69a9f-b119-4699-b6b5-91c30cb43925   1500Gi     RWO            ebs-gp3        21h
elasticsearch-data-common-cluster-es-datav2-1         Bound    pvc-67fb2d3f-035d-4cf7-83b9-a06a6e283468   1500Gi     RWO            ebs-gp3        21h
elasticsearch-data-common-cluster-es-datav2-2         Bound    pvc-3c86c963-47eb-4adb-82f8-e3a0f46da575   1500Gi     RWO            ebs-gp3        21h
elasticsearch-data-common-cluster-es-ingest-0         Bound    pvc-e59aa5e9-15d2-4f7b-a30a-acc4bf36a999   10Gi       RWO            ebs-gp3        21h

But new storage class should be ebs-standard.

In eck logs i see next

elastic-operator-0 manager {"log.level":"error","@timestamp":"2023-02-10T10:32:10.421Z","log.logger":"manager.eck-operator","message":"Reconciler error","service.version":"2.5.0+642f9ecd","service.type":"eck","ecs.version":"1.4.0","controller":"elasticsearch-controller","object":{"name":"common-cluster","namespace":"observability"},"namespace":"observability","name":"common-cluster","reconcileID":"ceb998ac-395f-448f-9885-394520089592","error":"reconcile StatefulSet: StatefulSet.apps \"common-cluster-es-masterv2\" is invalid: spec: Forbidden: updates to statefulset spec for fields other than 'replicas', 'template', 'updateStrategy' and 'minReadySeconds' are forbidden","errorCauses":[{"error":"reconcile StatefulSet: StatefulSet.apps \"common-cluster-es-masterv2\" is invalid: spec: Forbidden: updates to statefulset spec for fields other than 'replicas', 'template', 'updateStrategy' and 'minReadySeconds' are forbidden"}],"error.stack_trace":"sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).reconcileHandler\n\t/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.13.0/pkg/internal/controller/controller.go:326\nsigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).processNextWorkItem\n\t/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.13.0/pkg/internal/controller/controller.go:273\nsigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start.func2.2\n\t/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.13.0/pkg/internal/controller/controller.go:234"}

Looks like it created with old storage class and after trying to update it. Any suggestions how can i change storage class?

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.