bitnami / charts

Bitnami Helm Charts
https://bitnami.com
Other
8.85k stars 9.13k forks source link

[bitnami/mongodb] exitCode: 2 with unrecognized option storage.journal.enabled #29293

Open JustDoItSascha opened 1 week ago

JustDoItSascha commented 1 week ago

Name and Version

bitnami/mongodb 15.6.22

What architecture are you using?

None

What steps will reproduce the bug?

I just tried to start a mongodb with default config and architecture standalone. But the pod immediately stops with exitCode 2 and after enabling the debug mode I see the "unrecognized option storage.journal.enabled" error.

Are you using any custom parameters or values?

  image:
    debug: true
  architecture: standalone
  auth:
    rootUser: ...
    rootPassword: ...
  persistence:
    size: 1Gi

What do you see instead?

mongodb 08:18:15.34 INFO  ==> 
mongodb 08:18:15.34 INFO  ==> Welcome to the Bitnami mongodb container
mongodb 08:18:15.34 INFO  ==> Subscribe to project updates by watching https://github.com/bitnami/containers
mongodb 08:18:15.34 INFO  ==> Submit issues and feature requests at https://github.com/bitnami/containers/issues
mongodb 08:18:15.35 INFO  ==> 
mongodb 08:18:15.35 DEBUG ==> Copying files from /opt/bitnami/mongodb/conf.default to /opt/bitnami/mongodb/conf
mongodb 08:18:15.35 INFO  ==> ** Starting MongoDB setup **
mongodb 08:18:15.37 INFO  ==> Validating settings in MONGODB_* env vars...
mongodb 08:18:15.41 INFO  ==> Initializing MongoDB...
mongodb 08:18:15.42 DEBUG ==> /mongodb.conf mounted. Skipping setting port and IPv6 settings
mongodb 08:18:15.42 DEBUG ==> /mongodb.conf mounted. Skipping setting log settings
mongodb 08:18:15.42 DEBUG ==> /mongodb.conf mounted. Skipping setting log settings
mongodb 08:18:15.42 DEBUG ==> /mongodb.conf mounted. Skipping setting storage settings
mongodb 08:18:15.43 INFO  ==> Deploying MongoDB from scratch...
mongodb 08:18:15.43 DEBUG ==> Starting MongoDB in background...
Unrecognized option: storage.journal.enabled
try '/opt/bitnami/mongodb/bin/mongod --help' for more information
JustDoItSascha commented 1 week ago

The chart with version 13.18.5 is the latest which is working

jotamartos commented 1 week ago

Hi @JustDoItSascha,

I'm sorry but I can't reproduce the issue. I just launched the solution with the parameters you set

diff --git a/bitnami/mongodb/values.yaml b/bitnami/mongodb/values.yaml
index de0d31fa33..51b1b0dcaf 100644
--- a/bitnami/mongodb/values.yaml
+++ b/bitnami/mongodb/values.yaml
@@ -171,7 +171,7 @@ auth:
   ## @param auth.rootPassword MongoDB(®) root password
   ## ref: https://github.com/bitnami/containers/tree/main/bitnami/mongodb#setting-the-root-user-and-password-on-first-run
   ##
-  rootPassword: ""
+  rootPassword: "bitnami1234"
   ## MongoDB(®) custom users and databases
   ## ref: https://github.com/bitnami/containers/tree/main/bitnami/mongodb#creating-a-user-and-database-on-first-run
   ## @param auth.usernames List of custom users to be created during the initialization
@@ -1193,7 +1193,7 @@ persistence:
     - ReadWriteOnce
   ## @param persistence.size PVC Storage Request for MongoDB(®) data volume
   ##
-  size: 8Gi
+  size: 1Gi
   ## @param persistence.annotations PVC annotations
   ##
   annotations: {}

and the deployment worked as expected

$ k get pods
NAME                       READY   STATUS    RESTARTS   AGE
mongodb-5fd99dc46d-dggrq   1/1     Running   0          81s

The chart with version 13.18.5 is the latest which is working

That version of the chart is from 1 year ago and I do not know if you are including more changes in your custom values.yaml file. Please ensure you are using the latest version of the chart and that the cluster has enough resources to deploy the solution.