升级neo4j 2.2到2.3到3.3错误"不能将v0.A.5升级到v0.A.8"

时间:2018-03-16 15:58:06

标签: neo4j

我很难将我的neo4j数据库从2.2.0社区迁移到3.3.3企业。启动neo4j 3.3.3的错误是"无法使用版本' v0.A.5'升级商店。到当前商店版本' v0.A.8' (Neo4j 3.3.3)。"

我所遵循的过程是将数据库从2.2.0升级到2.3.8,然后将2.3.8数据库升级到3.3.3。

从2.2.0升级到2.3.8我遵循以下文档: https://neo4j.com/docs/2.3.8/deployment-upgrading.html

基本上,这包括:

  • 关闭2.2.0
  • 将graph.db目录复制到安装了2.3.8的服务器
  • 将该graph.db目录放在数据目录中,调整权限
  • 启动neo4j

此过程已完成且无错误

从2.3.8升级到3.3.3我遵循以下文档: https://neo4j.com/docs/operations-manual/current/upgrade/deployment-upgrading/

我将3.3.3服务器上的这个过程应用到从2.3.8

传输的graph.db目录
sudo service neo4j stop
rm -rf /var/lib/neo4j/data/databases/graph.db
neo4j-admin import --mode=database --database=graph.db --
from=/path/to/2.3/version/of/graph.db
sudo chown -R neo4j:neo4j /var/lib/neo4j/data/databases/graph.db
sudo service neo4j start

在neo4j 3.3.3的开头,syslog显示了大量的错误输出,其中显着的部分是:

Mar 15 22:35:38 ip-XXX-XXX-XXX-XXX neo4j[61967]: 2018-03-15 22:35:38.644+0000 ERROR Failed to start Neo4j: Starting Neo4j failed: Component 'org.neo4j.server.database.LifecycleManagingDatabase@a202ccb' was successfully initialized, but failed to start. Please see the attached cause exception "Not possible to upgrade a store with version 'v0.A.5' to current store version `v0.A.8` (Neo4j 3.3.3).". Starting Neo4j failed: Component 'org.neo4j.server.database.LifecycleManagingDatabase@a202ccb' was successfully initialized, but failed to start. Please see the attached cause exception "Not possible to upgrade a store with version 'v0.A.5' to current store version `v0.A.8` (Neo4j 3.3.3).".
Mar 15 22:35:38 ip-XXX-XXX-XXX-XXX neo4j[61967]: org.neo4j.server.ServerStartupException: Starting Neo4j failed: Component 'org.neo4j.server.database.LifecycleManagingDatabase@a202ccb' was successfully initialized, but failed to start. Please see the attached cause exception "Not possible to upgrade a store with version 'v0.A.5' to current store version `v0.A.8` (Neo4j 3.3.3).".
检查3.3.3服务器上2.3.8的graph.db显示:

neo4j-admin store-info --store=/path/to/2.3/version/of/graph.db
Store format version:         v0.A.5
unexpected error: Unknown store version 'v0.A.5'

我的服务器信息是:

  • 2.2.0社区:ubuntu 14.04安装,我相信,来自tarball(我没有构建这个服务器)
  • 2.3.8社区:通过apt-get作为服务运行安装的ubuntu 16.04
  • 3.3.3 enterprise:通过apt-get作为服务运行安装的ubuntu 16.04

我的问题是:

将现有2.2.0 db成功升级到3.3.3的正确流程是什么?

2 个答案:

答案 0 :(得分:1)

也许这里的文档不完全准确,我们需要采取额外的步骤。

由于您升级到2.3.8似乎运行良好,我将此作为以下过程的基准。

很久以前我写了一个hackish升级脚本,请参阅https://gist.github.com/sarmbruster/3011606。在第46行中将版本更改为3.0.12并检查是否升级2.3.8 - > 3.0.12工作。如果是,请继续3.3.4。

你的graph.db文件夹有多大?

答案 1 :(得分:0)

自3.1版以来,neo4j操作手册记录了如何将数据库从2.x版升级到3.1 +。

例如,here is the section of the docs for upgrading from 2.x to 3.3.4