简体   繁体   English

neo4j升级1.9.x-> 2.x失败

[英]neo4j upgrade 1.9.x -> 2.x failing

I'm trying to run an upgrade from neo4j 1.9.8 to 2.3.0 我正在尝试从neo4j 1.9.8升级到2.3.0

I'm using neo4j in embedded java mode, with additional webadmin configured via org.neo4j.server.configuration.ServerConfigurator . 我在嵌入式Java模式下使用neo4j,并通过org.neo4j.server.configuration.ServerConfigurator配置了其他webadmin。

I have 我有

allow_store_upgrade=true

And the following appears in messages.log 并且以下内容出现在messages.log

2015-10-22 09:45:19.263+0000 INFO  [o.n.k.i.s.StoreMigrator] Starting upgrade of database store files
2015-10-22 09:45:19.609+0000 INFO  [o.n.u.i.b.ParallelBatchImporter] Import starting
2015-10-22 09:45:19.662+0000 WARN  [o.n.k.i.s.MetaDataStore] Missing counts store, rebuilding it.
2015-10-22 09:45:19.870+0000 INFO  [o.n.k.a.i.i.LuceneLabelScanStore] No lucene scan store index found, this might just be first use. Preparing to rebuild.
2015-10-22 09:45:20.011+0000 INFO  [o.n.k.a.i.i.LuceneLabelScanStore] Rebuilding lucene scan store, this may take a while
2015-10-22 09:45:20.013+0000 INFO  [o.n.k.a.i.i.LuceneLabelScanStore] Lucene scan store rebuilt (roughly -1 nodes)
2015-10-22 09:47:40.676+0000 INFO  [o.n.k.i.s.StoreMigrator] Store upgrade 10% complete
2015-10-22 09:49:30.698+0000 INFO  [o.n.k.i.s.StoreMigrator] Store upgrade 20% complete
2015-10-22 09:57:09.822+0000 INFO  [o.n.k.i.s.StoreMigrator] Store upgrade 30% complete
2015-10-22 10:00:36.621+0000 INFO  [o.n.k.i.s.StoreMigrator] Store upgrade 40% complete
2015-10-22 10:08:16.226+0000 INFO  [o.n.k.i.s.StoreMigrator] Store upgrade 50% complete
2015-10-22 10:16:30.454+0000 INFO  [o.n.k.i.s.StoreMigrator] Store upgrade 60% complete
2015-10-22 10:20:19.178+0000 INFO  [o.n.k.i.s.StoreMigrator] Store upgrade 70% complete
2015-10-22 10:35:07.315+0000 INFO  [o.n.k.i.s.StoreMigrator] Store upgrade 80% complete
2015-10-22 10:58:56.521+0000 INFO  [o.n.k.i.s.StoreMigrator] Store upgrade 90% complete
2015-10-22 11:11:26.017+0000 INFO  [o.n.k.i.s.StoreMigrator] Store upgrade 100% complete
2015-10-22 11:15:32.419+0000 INFO  [o.n.u.i.b.ParallelBatchImporter] Import completed, took 1h 30m 12s 805ms. Imported:
  427688598 nodes
  884330252 relationships
  0 properties

So it says it's done, but the claim of 0 properties is suspicious. 因此它说已经完成了,但是0 properties是可疑的。

When I then remove allow_store_upgrade property and re-boot, I get: 然后,当我删除allow_store_upgrade属性并重新启动时,我得到:

Caused by: org.neo4j.kernel.impl.storemigration.UpgradeNotAllowedByConfigurationException: Failed to start Neo4j with an older data store version. To enable automatic upgrade, please set configuration parameter "allow_store_upgrade=true"
        at org.neo4j.kernel.impl.storemigration.ConfigMapUpgradeConfiguration.checkConfigurationAllowsAutomaticUpgrade(ConfigMapUpgradeConfiguration.java:39) ~[neo4j-kernel-2.3.0-RC1.jar:2.3.0-RC1,8014933]
        at org.neo4j.kernel.impl.storemigration.StoreUpgrader.migrateIfNeeded(StoreUpgrader.java:135) ~[neo4j-kernel-2.3.0-RC1.jar:2.3.0-RC1,8014933]
        at org.neo4j.kernel.NeoStoreDataSource.upgradeStore(NeoStoreDataSource.java:623) ~[neo4j-kernel-2.3.0-RC1.jar:2.3.0-RC1,8014933]
        at org.neo4j.kernel.NeoStoreDataSource.start(NeoStoreDataSource.java:514) ~[neo4j-kernel-2.3.0-RC1.jar:2.3.0-RC1,8014933]
        at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:528) ~[neo4j-kernel-2.3.0-RC1.jar:2.3.0-RC1,8014933]
        ... 89 common frames omitted

Make sure that you have a clean shutdown on your 1.9.x database. 确保您已完全关闭1.9.x数据库。 To be on the safe side run consistency checker on that one, see http://www.markhneedham.com/blog/2014/01/22/neo4j-backup-store-copy-and-consistency-check/ for details. 为了安全起见,请对该站点运行一致性检查器,有关详细信息,请参见http://www.markhneedham.com/blog/2014/01/22/neo4j-backup-store-copy-and-consistency-check/

My expectation is that 1.9 -> 2.3 upgrade should run in one step. 我的期望是1.9-> 2.3升级应该一步完成。 If that doesn't work for you, try to run the upgrade in multiple steps: 1.9 -> 2.0 -> 2.1 -> 2.2 -> 2.3. 如果那对您不起作用,请尝试以多个步骤运行升级:1.9-> 2.0-> 2.1-> 2.2-> 2.3。 If that multiple step approach succeeds, I consider the failure of the "large" upgrade a bug worth filing an issue at https://github.com/neo4j/neo4j/issues . 如果该多步骤方法成功,那么我认为“大型”升级失败了,值得在https://github.com/neo4j/neo4j/issues提交问题。

Upgrade directly from 1.9 --> 2.3 is supported. 支持从1.9-> 2.3直接升级。 The note about 0 properties is misleading but benign since the migration process doesn't touch the properties, but leave them as-is. 关于0属性的注释具有误导性,但它是良性的,因为迁移过程不会触及属性,而是保持原样。

Although it's very weird that it complains about the upgrade not allowed after the initial migration completes (the next startup). 尽管很奇怪,它抱怨在初始迁移完成(下次启动)后不允许升级。 If the database wouldn't have been cleanly shut down before the migration, there should have been an exception saying migration wouldn't be possible. 如果在迁移之前不会彻底关闭数据库,那么应该有一个例外,说明无法进行迁移。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM