I'm trying to upgrade my neo4j store, running on windows, from 2.0.1 to 2.1.3.
What i have done, starting with a working 2.0.1. environment, is the following:
- .\2.0.1\bin\neo4jinstall.bat remove
- xcopy .\2.0.1\data\findsi.graphdb .\2.1.3\data\findsi.graphdb
- .\2.1.3\bin\neo4jinstall.bat install
This will fail with the message:
Detected incorrectly shut down database, performing recovery..
My (2.1.3) messages.log file tells me this:
2014-08-11 09:45:46.352+0000 ERROR [o.n.k.EmbeddedGraphDatabase]: Startup failed: Component 'org.neo4j.kernel.impl.transaction.XaDataSourceManager@3198c7f6' was successfully initialized, but failed to start. Please see attached cause exception.: Component 'org.neo4j.kernel.impl.nioneo.xa.NeoStoreXaDataSource@4d8088da' was successfully initialized, but failed to start. Please see attached cause exception.: 'neostore.nodestore.db' does not contain a store version, please ensure that the original database was shut down in a clean state.
2014-08-11 09:45:46.352+0000 INFO [o.n.k.EmbeddedGraphDatabase]: Shutdown started
2014-08-11 09:45:46.352+0000 ERROR [o.n.s.e.EnterpriseBootstrapper]: Failed to start Neo Server on port [7474]
org.neo4j.server.ServerStartupException: Starting Neo4j Server failed: Error starting org.neo4j.kernel.EmbeddedGraphDatabase, C:\NEO4J-~1.3\data\findsi.graphdb
at org.neo4j.server.AbstractNeoServer.start(AbstractNeoServer.java:221) ~[neo4j-server-2.1.3.jar:2.1.3]
at org.neo4j.server.Bootstrapper.start(Bootstrapper.java:103) [neo4j-server-2.1.3.jar:2.1.3]
at org.neo4j.server.Bootstrapper.main(Bootstrapper.java:57) [neo4j-server-2.1.3.jar:2.1.3]
Caused by: java.lang.RuntimeException: Error starting org.neo4j.kernel.EmbeddedGraphDatabase, C:\NEO4J-~1.3\data\findsi.graphdb
at org.neo4j.kernel.InternalAbstractGraphDatabase.run(InternalAbstractGraphDatabase.java:362) ~[neo4j-kernel-2.1.3.jar:2.1.3]
at org.neo4j.kernel.EmbeddedGraphDatabase.<init>(EmbeddedGraphDatabase.java:59) ~[neo4j-kernel-2.1.3.jar:2.1.3]
at org.neo4j.kernel.impl.recovery.StoreRecoverer.recover(StoreRecoverer.java:123) ~[neo4j-kernel-2.1.3.jar:2.1.3]
at org.neo4j.server.preflight.PerformRecoveryIfNecessary.run(PerformRecoveryIfNecessary.java:65) ~[neo4j-server-2.1.3.jar:2.1.3]
at org.neo4j.server.preflight.PreFlightTasks.run(PreFlightTasks.java:71) ~[neo4j-server-2.1.3.jar:2.1.3]
at org.neo4j.server.AbstractNeoServer.runPreflightTasks(AbstractNeoServer.java:357) ~[neo4j-server-2.1.3.jar:2.1.3]
at org.neo4j.server.AbstractNeoServer.start(AbstractNeoServer.java:154) ~[neo4j-server-2.1.3.jar:2.1.3]
... 2 common frames omitted
Caused by: org.neo4j.kernel.lifecycle.LifecycleException: Component 'org.neo4j.kernel.impl.transaction.XaDataSourceManager@3198c7f6' was successfully initialized, but failed to start. Please see attached cause exception.
at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:513) ~[neo4j-kernel-2.1.3.jar:2.1.3]
at org.neo4j.kernel.lifecycle.LifeSupport.start(LifeSupport.java:115) ~[neo4j-kernel-2.1.3.jar:2.1.3]
at org.neo4j.kernel.InternalAbstractGraphDatabase.run(InternalAbstractGraphDatabase.java:339) ~[neo4j-kernel-2.1.3.jar:2.1.3]
... 8 common frames omitted
Caused by: org.neo4j.kernel.lifecycle.LifecycleException: Component 'org.neo4j.kernel.impl.nioneo.xa.NeoStoreXaDataSource@4d8088da' was successfully initialized, but failed to start. Please see attached cause exception.
at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:513) ~[neo4j-kernel-2.1.3.jar:2.1.3]
at org.neo4j.kernel.lifecycle.LifeSupport.start(LifeSupport.java:115) ~[neo4j-kernel-2.1.3.jar:2.1.3]
at org.neo4j.kernel.impl.transaction.XaDataSourceManager.start(XaDataSourceManager.java:164) ~[neo4j-kernel-2.1.3.jar:2.1.3]
at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:507) ~[neo4j-kernel-2.1.3.jar:2.1.3]
... 10 common frames omitted
Caused by: org.neo4j.kernel.impl.storemigration.StoreUpgrader$UpgradingStoreVersionNotFoundException: 'neostore.nodestore.db' does not contain a store version, please ensure that the original database was shut down in a clean state.
at org.neo4j.kernel.impl.storemigration.UpgradableDatabase.checkUpgradeable(UpgradableDatabase.java:76) ~[neo4j-kernel-2.1.3.jar:2.1.3]
at org.neo4j.kernel.impl.storemigration.StoreMigrator.needsMigration(StoreMigrator.java:103) ~[neo4j-kernel-2.1.3.jar:2.1.3]
at org.neo4j.kernel.impl.storemigration.StoreUpgrader.getParticipantsEagerToMigrate(StoreUpgrader.java:241) ~[neo4j-kernel-2.1.3.jar:2.1.3]
at org.neo4j.kernel.impl.storemigration.StoreUpgrader.migrateIfNeeded(StoreUpgrader.java:129) ~[neo4j-kernel-2.1.3.jar:2.1.3]
at org.neo4j.kernel.impl.nioneo.xa.NeoStoreXaDataSource.start(NeoStoreXaDataSource.java:350) ~[neo4j-kernel-2.1.3.jar:2.1.3]
at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:507) ~[neo4j-kernel-2.1.3.jar:2.1.3]
... 13 common frames omitted
Now, if i do .\2.0.1\bin\neo4jinstall.bat install
everything works fine again, albeit with the old version. My guess is, that it has not to do with the actual database.
As the documentation states, i did setup for an explicit upgrade by setting allow_store_upgrade=true
in my 2.1.3 environment.
I'm reluctant to manually change things in my database folder, but i do need the upgrade, as it solves some performance issues i have been struggling with.