neo4j/community — Issue #292: CentOS 6.2 failed install with Neo4j Server 1.6.1 Community
Author: piratadelfuturo
Created: 2012-02-29 15:57:27+00:00
State: open

When you try to install neo4j in CentOs or any RHEL based distro you get this:

[root@dyn106 bin]# ./neo4j install
Graph-like power should be handled carefully. What user should run Neo4j? [neo4j]
User "neo4j" does not yet exist. Shall I create the account for you? [Yn]Y
Created user "neo4j".
./neo4j: line 349: update-rc.d: command not found
[root@dyn106 bin]# ./neo4j start
WARNING: Detected a limit of 1024 for maximum open files, while a minimum value of 40000 is recommended.
WARNING: Problems with the operation of the server may occur. Please refer to the Neo4j manual regarding lifting this limitation.
Starting Neo4j Server...Exception in thread "main" java.lang.NoClassDefFoundError: org/neo4j/server/storemigration/PreStartupStoreUpgrader
Caused by: java.lang.ClassNotFoundException: org.neo4j.server.storemigration.PreStartupStoreUpgrader
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
Could not find the main class: org.neo4j.server.storemigration.PreStartupStoreUpgrader. Program will exit.

Then if you remove the neo4j folder and create a new installation, you can start the server again but if the machine gets shot down suddenly and then you try to restart the server you can't and then you get this error:

[root@dyn098 bin]# ./neo4j start
Starting Neo4j Server...Bad level value for property: org.neo4j.server.level
[root@dyn098 bin]#

in the log:
Feb 27, 2012 10:21:20 AM org.neo4j.server.logging.Logger log
SEVERE:
Throwable occurred: java.lang.IllegalArgumentException
at sun.nio.ch.FileChannelImpl.position(FileChannelImpl.java:278)
at org.neo4j.kernel.impl.storemigration.CurrentDatabase.storeFilesAtCurrentVersion(CurrentDatabase.java:75)
at org.neo4j.server.storemigration.PreStartupStoreUpgrader.run(PreStartupStoreUpgrader.java:79)
at org.neo4j.server.storemigration.PreStartupStoreUpgrader.main(PreStartupStoreUpgrader.java:52)