I have a neo4j db with 1M nodes and 10M relationships running on my local 
computer (16GB RAM, 4-core i7). The configuration of the server is as 
follows:

neo4j.properties:
neostore.nodestore.db.mapped_memory=25M
neostore.relationshipstore.db.mapped_memory=500M
neostore.propertystore.db.mapped_memory=900M
neostore.propertystore.db.strings.mapped_memory=1300M
neostore.propertystore.db.arrays.mapped_memory=1300M
cache_type=strong

neo4j-wrapper.conf:
wrapper.java.initmemory=1512
wrapper.java.maxmemory=11120


I am running the following query:

OPTIONAL MATCH (m:User)-[:REL1]->() - [:REL2]-> ()<-[:REL1]-(n) RETURN 
 m.id AS From ,n.id AS To, count(n) AS Number

The query makes the heap size increase until it hits 11Gib on the memory. 
Then the server just struggles (loses connection, re-connects) for a few 
hours and eventually it dies with either this error:

ERROR (-v for expanded information):

        Error unmarshaling return header; nested exception is: 

        java.net.SocketException: Operation timed out


or this error:

ERROR (-v for expanded information):

          Error occurred in server thread; nested exception is: 

           java.lang.OutOfMemoryError: Java heap space


I know that [:REL2] are roughly 8M. I don't know what else I can do to fix 
this. Perhaps the query needs to be optimized but I don't know how I can 
make it simpler because [:REL2] is important to use. Any thoughts or 
suggestions would be much appreciated.



-- 
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 [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to