2
votes

I have a neo4j server including 10 million nodes.

I'm trying to create 1 billion relationships, by adding each node 100 relationships.

I wrote a java embedded program and it updates the relationships.

So far, the execution time looks not bad: approximately 15 million relationships per hour. (using 3GB heap size); But, the disk usage is increasing far more than expected : appr. 6 GB per hour .(15 m relationships..)

For my understanding, relationship takes 33B. So, when adding 15 million relationships (with no properties at all except for the name), it should take about 0.5 GB . instead it takes 10 times more!

Why relationships take so much disk usage?

2
Are you using the bulk inserter or the normal transactional method for your creation? When you say it's taking up all that space, is it just the relationshipstore or is it the entire neo4j directory?Nicholas
below post might help::: stackoverflow.com/questions/15074593/…dev

2 Answers

3
votes

You probably need to clean up your logical log (to be sure, check which files are growing fast). You can configure this via a configuration parameter: keep_logical_logs=false

0
votes

See Code:

int number = (int) parseLongWithUnit( numberWithUnit );

More than "2G size" can not set by bytes,but you can set XXX files/XXX hours/XXX days/XXX txs

keep_logical_logs for backup/HA sync etc.