Neo4j: unable to lock storage

I use the Neo4j chart graph and view the data in a browser. Therefore, whenever I run the code, I need to change the database location field in the neo4j-server.properties file.

When I try to access the database using a browser, I get the following error:

Exception in thread "main" java.lang.IllegalStateException: Unable to lock store [<DB path>], this is usually a result of some other Neo4j kernel running using the same store. 

Can I browse a database without locking the store?

+4
source share
2 answers

There is another process using db. For example, you opened it with another program (for example, a gremlin shell in the terminal) or another instance of neo4j was launched.

If you are using a Unix-like system (Linux, MacOSX, etc.), you can use lsof to identify the processes that opened your db. For example, if the path to my db is /home/user/db/myneo4j.db , then I would search:

 $ lsof /home/user/db/myneo4j.db/neostore.propertystore.db.index 

Or you can just try:

 $ lsof | grep myneo4j.db 

This will tell you the identifier of the process that took (locked) the database.

+3
source

Are you sure that the java process does not work against the data warehouse before you start the neo4j server to view your data?

+1
source

All Articles