charts icon indicating copy to clipboard operation
charts copied to clipboard

[bitnami/mongodb] pvc gets deleted when upgrading helm chart

Open lusu007 opened this issue 5 years ago • 7 comments

Which chart: mongodb 10.10.0

Describe the bug When upgrading the helm chart the pvcs of an existing replicaset gets deleted.

To Reproduce Install mongodb replicaset then upgrade the helm chart.

Expected behavior PVCs doesn't get deleted

Version of Helm and Kubernetes:

  • Output of helm version:
version.BuildInfo{Version:"v3.5.2", GitCommit:"167aac70832d3a384f65f9745335e9fb40169dc2", GitTreeState:"dirty", GoVersion:"go1.15.7"}
  • Output of kubectl version:
Client Version: version.Info{Major:"1", Minor:"19", GitVersion:"v1.19.7", GitCommit:"1dd5338295409edcfff11505e7bb246f0d325d15", GitTreeState:"clean", BuildDate:"2021-01-13T13:23:52Z", GoVersion:"go1.15.5", Compiler:"gc"
, Platform:"windows/amd64"}
Server Version: version.Info{Major:"1", Minor:"19", GitVersion:"v1.19.5", GitCommit:"e338cf2c6d297aa603b50ad3a301f761b4173aa6", GitTreeState:"clean", BuildDate:"2020-12-09T11:10:32Z", GoVersion:"go1.15.2", Compiler:"gc"
, Platform:"linux/amd64"}

Additional context None. If more information is needed just contact me.

lusu007 avatar Mar 08 '21 17:03 lusu007

Hi @lusu007, can you share the specific values that you are using to install and upgrade the helm chart? What are the original version you are upgrading from?

andresbono avatar Mar 09 '21 09:03 andresbono

Hey @andresbono, I upgraded from version 10.6.2 to 10.10.0.

Mongodb is deployed via argocd with the following values.yaml:

namespace: &mongodbNamespace stage-mongodb
mongodb:
  global:
    namespaceOverride: *mongodbNamespace
    imagePullSecrets:
      - dockerhub
    storageClass: csi-cinder-high-speed
  architecture: replicaset
  auth:
    database: admin
    username: legend
    existingSecret: mongodb-secret
  replicaSetName: mongodb
  replicaCount: 3
  metrics:
    enabled: true
    serviceMonitor:
      enabled: true
      namespace: global-prometheus-stack

lusu007 avatar Mar 09 '21 17:03 lusu007

Hi @lusu007, I couldn't reproduce your issue... In my case, the pods are updated but the pvcs are kept. It's true that I'm not using your storage class, but that shouldn't be related...

andresbono avatar Mar 11 '21 15:03 andresbono

It may be related to Reclaim Policy of volume, not sure though. see

ilhnctn avatar Mar 18 '21 07:03 ilhnctn

I will take a look at it! Thank you 😄

lusu007 avatar Mar 18 '21 21:03 lusu007

This Issue has been automatically marked as "stale" because it has not had recent activity (for 15 days). It will be closed if no further activity occurs. Thanks for the feedback.

stale[bot] avatar Apr 14 '21 10:04 stale[bot]

Due to the lack of activity in the last 5 days since it was marked as "stale", we proceed to close this Issue. Do not hesitate to reopen it later if necessary.

github-actions[bot] avatar Apr 20 '21 01:04 github-actions[bot]