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)
at org.neo4j.kernel.impl.storemigration.StoreUpgrader.attemptUpgrade(StoreUpgrader.java:71)
at org.neo4j.kernel.impl.nioneo.store.StoreFactory.tryToUpgradeStores(StoreFactory.java:144)
at org.neo4j.kernel.impl.nioneo.store.StoreFactory.newNeoStore(StoreFactory.java:119)
at org.neo4j.kernel.impl.nioneo.xa.NeoStoreXaDataSource.start(NeoStoreXaDataSource.java:323)
at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:503)
这是一个静态数据集......它是来自Neo4j的Cineasts示例。我想我回答了很多人说“他们为什么还有旧版本的示例数据集?”
我正在尝试通过Java代码连接到数据库,如此
if (graphDatabaseFactory == null) {
graphDatabaseFactory = new GraphDatabaseFactory();
}
graphDb = graphDatabaseFactory
.newEmbeddedDatabaseBuilder(databaseLocation)
.setConfig(GraphDatabaseSettings.allow_store_upgrade, "true")
.newGraphDatabase();
我收到以下错误...
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"
这里发生了什么?
答案 0 :(得分:1)
引用docs:
每个Neo4j版本都支持从有限数量的先前版本升级。
E.g。当您的数据集在1.8时,您需要先使用1.9,然后使用2.0,最后使用2.1才能完全升级。我怀疑你的数据集已经很老了,你需要逐步升级。在http://blog.armbruster-it.de/2012/06/upgrading-an-old-neo4j-database-using-groovy/看到我的一篇旧博文。