Upgrade to 5.x or 5.26 LTS

This page is an overview of what needs to be checked and completed to ensure your upgrade goes smoothly and as planned.

Important

It is recommended to read the Introduction before continuing.

Review changes

Review the Release Notes to see what has been introduced or changed in the new version.

Standalone

The steps to upgrade a standalone server (one that’s not part of a cluster) are:

  1. Stop the old Neo4j server.

  2. Install the new version of Neo4j.

  3. Start the new Neo4j server.
    You can monitor the logs to see how the upgrade is progressing. The neo4j.log file contains information on the upgrade.

Where applicable, it is recommended to use a package manager to install Neo4j. This simplifies the process and ensures that the configuration and state are preserved.

Follow the links to some walkthroughs of upgrading a Neo4j standalone server:

Clusters

Depending on the type of cluster you have, there are different strategies for upgrading a Neo4j cluster.

Basic cluster

There are two strategies for upgrading a basic cluster:

  • New server rolling upgrade — A new server is added before an existing server is taken offline. This approach keeps the cluster available and fault-tolerant throughout the upgrade. This approach is suitable for deployments that use replaceable cloud or container resources.

  • In-place rolling upgrade — Each server is taken offline and upgraded one at a time. The server is reconnected to the cluster before the next is taken offline. This approach keeps the cluster available throughout the upgrade. However, it does reduce fault tolerance while each server is offline.

Should the data stores fall out of sync during the process, you may need to re-seed the cluster. For more information, see Operations Manual → Seed a cluster.

If you want to upgrade from a version in the range [5.0-5.6] to a version in the range [5.10-5.15], first upgrade to version 5.9 before upgrading to the desired version. For example, to upgrade a cluster from 5.4 to 5.13, it is necessary to first upgrade to version 5.9 before upgrading to version 5.13. Upgrading to version 5.16 does not require any intermediate steps. For example, a 5.4 cluster can be upgraded directly to the latest version.

Analytics cluster

To upgrade a analytics cluster, that is, a cluster with a single primary for system and one or more system secondaries (using the setting server.cluster.system_database_mode), it is important to upgrade the secondaries before you upgrade the primary. If not, the primary automatically updates the system database, and the secondaries are no longer compatible. Similarly to in-place rolling upgrades, the steps for an individual server are identical to upgrading a standalone server.