Automatic PostgreSQL Upgrade (CNPG Operator-Managed)
Steps to perform an automatic in-place PostgreSQL major version upgrade with the CloudNativePG operator, and when to fall back to the manual upgrade process.
Steps to perform an automatic in-place PostgreSQL major version upgrade with the CloudNativePG operator, and when to fall back to the manual upgrade process.
This guide covers the manual steps required to upgrade PostgreSQL across a major version when using the CloudNativePG (CNPG) operator-based PostgreSQL installation, specifically when PostgreSQL is managed through the experimental postgresql-operator and postgresql-cluster rather than through the Release CR's built-in spec.postgresql keys. Use this manual process only if the automatic upgrade fails or your cluster doesn't meet its prerequisites.
PostgreSQL cannot be automatically upgraded during an operator-to-operator or Helm-to-operator upgrade due to incompatible data formats between different PostgreSQL server versions. In such cases, a manual upgrade is necessary. The process involves first backing up the PostgreSQL data, then upgrading to the new PostgreSQL version, and finally restoring the data in the upgraded version.
This guide covers the manual steps required to migrate from the Bitnami chart-managed PostgreSQL installation (the default up to and including operator 25.1 releases) to the CloudNativePG (CNPG) operator-managed equivalent introduced in operator 25.3 releases.