You can, after you've shut down the Neo4j Windows service, use neo4j-shell with 
the `-path <dir>` option to start a non-service Neo4j instance and then do a 
clean shutdown with the `exit` command. You should then be able to upgrade.

I don't know why there is this problem with shutting down the Windows service.

--
Chris Vest
System Engineer, Neo Technology
[ skype: mr.chrisvest, twitter: chvest ]


On 31 May 2014, at 23:09, Jim Salmons <jim.salm...@softalkapple.com> wrote:

> This issue has surfaced a number of times in various flavors, particularly 
> when an explicit upgrade (non-automatic requiring "allow_store_upgrade=true") 
> is involved and the culprit seems to be this:
> If you run Neo4j as a Windows Service (having installed via 
> Neo4jInstaller.bat and using recommended start/stop 'sc' commands, etc.) 
> there is no way to do a clean shutdown of a database.
> (As long as no upgrade is involved, apparently Neo4j running as a Windows 
> Service can start, stop, and restart databases with no problem (although the 
> message logs reveal that a non-clean shutdown has been silently been detected 
> and addressed on restart).
> 
> In the past, it has been suggested that this issue was from "jumping the gun" 
> of not letting the Neo4j-Server instance shut down completely before 
> restarting the Neo4j-Server Windows Service. But that is not the case.
> 
> To test the basic situation I did this with the same results on both 2.0 and 
> 2.1:
> Create an empty graph.db directory in my Neo4j data directory, then start the 
> Neo4j-Server Windows Service instance.
> Observe the fresh database being made. Make a copy of the messages.log 
> (called messages_onCreation.log
> Stop the Neo4j-Server Windows Service... wait, wait... wait (longer than 
> necessary)
> Compare the two messages logs... the same, no stopping messages.
> Delete the message.log and start the Neo4j-Server Windows Service.
> Observe the database directory during restart. Make a copy of the new 
> messages.log (called messages_on2ndStart.log
> With no activity other than to create it, stop it, and then start it back up 
> the messages.log shows multiple messages about detecting a non-clean 
> shutdown. (The number of non-clean detection issues in the log depend on the 
> Neo4j version being run.)
> 
> In the past, the recommendation was to use the deprecated Gremlin shell to do 
> g.shutdown() then exit. But this doesn't seem to be (readily) available.
> 
> QUESTION 1: Does anyone know of a way to cleanly shut down a Neo4j database 
> running under a Windows Service configuration?
> 
> QUESTION 2: Has anyone running Neo4j-Server as a Windows Service successfully 
> upgraded a 2.0 DB to 2.1? If so, how?
> 
> I'm hoping to get a quick helpful reply or additional insights here before 
> posting a question to S/O. Once I fully understand this issue, if it still 
> appears that the fundamental problem is the Windows Service not cleanly 
> shutting down, I'll enter an issue to this effect on the Neo4j GitHub Issue 
> queue.
> 
> Thanks,
> --Jim--
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Neo4j" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to neo4j+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Neo4j" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to neo4j+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to