debug-pg

Chart

Postgres

Hugepages

Debug

  • --set image.debug=true enables debug logging for bitnami charts
  • --set diagnosticMode.enabled=true start container with sleep and no healthchecks, perfect for exec’ing into the pod
  • kubectl describe pod test-postgresql-0 -n pg shows more details

Files

Mounting config files doesn’t work

works fine for postgresql.conf.sample, but postgresql.conf is an empty directory

apiVersion: v1
kind: ConfigMap
metadata:
  name: pg-sample-config-init
data:
  postgresql.conf.sample: |-
   huge_pages = off
   
apiVersion: v1
kind: ConfigMap
metadata:
  name: pg-sample-conf
data:
  postgresql.conf: |-
   huge_pages = off
   

values.yaml:

primary:
  extraVolumeMounts:
          - name: pg-sample-config-init
            mountPath: /opt/bitnami/postgresql/share/postgresql.conf.sample
            subPath: postgresql.conf.sample
          - name: pg-sample-config
            mountPath: /opt/bitnami/postgresql/share/postgresql.conf
            subPath: postgresql.conf
  extraVolumes:
          - configMap:
              name: pg-sample-config-init
            name:  pg-sample-config-init
          - configMap:
              name: pg-sample-config
            name:  pg-sample-config