Upgrade gitlab helm chart 6.11.13 (15.11.13) to chart 7.0.0 (16.0.0) error

Hello.
I am trying to upgrade gitlab from 15.11.13 to the latest version 16.4.1 (on kubernetes cluster). For this, I tried first to upgrade to 16.0.0 (chart 7.0.0), by using

helm upgrade --namespace gitlab --install gitlab gitlab/gitlab -f gitlab.yaml --version 7.0.0

I also followed the manual step from here

  1. I scaled down the replicas to 0 for the webservice, sidekiq, kas, and gitlab-exporter deployments.
  2. I deleted the gitlab-redis-master StatefulSet with:
kubectl delete statefulset gitlab-redis-master --namespace gitlab

Nevertheless, after trying to upgrade to 7.0.0, the following error appears:

Error: UPGRADE FAILED: cannot patch "gitlab-postgresql" with kind StatefulSet: StatefulSet.apps "gitlab-postgresql" is invalid: spec: Forbidden: updates to statefulset spec for fields other than 'replicas', 'template', 'updateStrategy', 'persistentVolumeClaimRetentionPolicy' and 'minReadySeconds' are forbidden

This error seems similar with the one from gitlab-redis-master , but I don’t if I should follow the same step.

In my gitlab.yaml file I have the following sections:

postgresql:
  volumePermissions:
    enabled: true
  image:
    tag: 13.6.0

redis:
  volumePermissions:
    enabled: true

Can you please tell me what am I doing wrong?
Thank you for all your help

Hello agrosu1978, did you follow this steps?

Need to delete postgresql replicaset and pvc.

Thank you a lot for your reply. Meanwhile, I found the link you sent, and I used it. Now I am up to 16.5.0 already
Thank you again for your help, I guess this topic may be closed

1 Like