Upgrade a standalone server (Docker)
This example shows how to upgrade or patch a standalone server running on Docker.
It is recommended to read the following pages before continuing: For critical systems, it is recommended to:
|
Prerequisites
The following steps assume that Neo4j 5.26 Enterprise Edition is running in a Docker container named neo4j-dbms
, with the /data directory in the container mapped to the /path/to/data on the host machine as in the following example:
docker run -d \
--name=neo4j-dbms \
--publish=7474:7474 --publish=7687:7687 \
--volume=/path/to/data:/data \
--env=NEO4J_ACCEPT_LICENSE_AGREEMENT=yes \ (1)
neo4j:5.26.1-enterprise
1 | Only for Enterprise Edition. |
If you want to monitor the logs, you should also map the container’s /logs directory to a /path/to/logs directory on the host machine. |
Upgrade steps
-
Stop the container
neo4j-dbms
by running:docker stop neo4j-dbms
-
Remove the
neo4j-dbms
container:docker rm neo4j-dbms
-
Start a new container, named
neo4j-2025
with the /data directory in the container mapped to the same /path/to/data on the host machine:docker run -d \ --name=neo4j-2025 \ --publish=7474:7474 --publish=7687:7687 \ --volume=/path/to/data:/data \ --env=NEO4J_ACCEPT_LICENSE_AGREEMENT=yes \ neo4j:enterprise
The upgrade process takes place during startup.
Monitor the logs
The neo4j.log file contains information on how many steps the upgrade will involve and how far it has progressed.