Knowledge Base

Articles tagged as performance

An explanation of the E_COUNT_EXCEEDED WARNing message in Neo4j’s debug.log.

The document aims to explain the E_COUNT_EXCEEDED WARNing messages that Neo4j can write to its debug.log. It also provides some monitoring and troubleshooting options. When running a Neo4j Causal Cluster,…

Read more

Throttling Bolt Requests

When large amounts of data are sent between a Neo4j database and a client (typically large query results, from server to client), there are a few hidden throttling mechanisms that…

Read more

Cross Product Cypher queries will not perform well

Just like SQL, if you do not properly connect the parts of your query, it will result in a cross (cartesian) product, which is seldom what you want. Take the…

Read more

How to diagnose locking issues

Since Neo4j 3.4 it’s possible to better understand locking issues caused by concurrent query. This KB article will not detail the basics of locking in Neo4j. We assume a situation…

Read more

Diagnose storage performance issues

Slow storage can affect Neo4j performance, therefore we recommend using Solid State Drives in the product documentation. Benchmark your underlying system On Ubuntu or RedHat, you can use fio tool…

Read more

Retired: How can I skip Consistency Check during Backup?

Backups in Neo4j automatically run a consistency check against the backed-up store. The backup itself does not take overly long, but the consistency check can take much more time to…

Read more

How do I improve the performance of counting number of relationships on a node

Using Cypher one could count number of relationships in the following manner Which will report the number of incoming/outgoing relationships for the Actor named Sylvester Stallone. Using bin/neo4j-shell and running…

Read more

How do I run Consistency Check Manually?

If you skip the Consistency Check part of neo4j-backup, or you want to check that all is well with a data store, you can run the tool against an offline…

Read more

How to configure off-heap transaction state

Commencing with Neo4j 3.5, it is possible to store some of transactions' data in off-heap memory. This can help to reduce GC pressure and/or prevent OOM crashes in a limited…

Read more

Retired: How to manually clear the Node and Relationship Cache

When troubleshooting transient issues or testing out queries on warm vs. cold cache, you may want to try clearing out the cache without necessarily restarting the Neo4j database. To achieve…

Read more

Linux Out of Memory killer

The Out Of Memory Killer or OOM Killer is a process that the linux kernel employs when the system is critically low on memory. This situation occurs because the linux…

Read more

Lock Manager Differences Explained

Work in Progress Community: uses Java intrinsic locks, i.e. ’synchronized’. this might not perform that well on multiprocessor machines uses Thread.sleep() and Thread.interrupt() to wait for locks. this involves context…

Read more

Performing pattern negation to multiple nodes

Some use cases require matching to nodes which aren’t connected to any of some other set of nodes. We’ll discuss both incorrect and correct approaches to this kind of query.…

Read more

Running copy store tool on windows

The copy store utilities is a set of tools to compact, copy, fix and analyse Neo4j stores. You might already know this but if not, you can read more about…

Read more

Tuning Cypher queries by understanding cardinality

Cardinality issues are the most frequent culprit in slow or incorrect Cypher queries. Because of this, understanding cardinality, and using this understanding to manage cardinality issues, is a critical component…

Read more

Understanding memory consumption

So you have configured Neo4j to use 4GB of heap and 6GB of page cache and sat back relaxed, thinking the Java process would not go above 10GB in your…

Read more

Understanding Neo4j Query Plan Caching

This article is based on the behavior of Neo4j 2.3.2. Query plan caching is governed by three parameters, as defined in the conf/neo4j.properties file, which are detailed here. The three…

Read more

Understanding the Query Plan Cache

When a Cypher statement is first submitted Neo4j will attempt to determine if the query is in the plan cache before planning it. By default Neo4j will keep 1000 query…

Read more

Understanding transaction and lock timeouts

One way to handle runaway queries is to impose a time limit that will terminate a query when exceeded. There are some subtleties here that need to be understood to…

Read more

Using Subqueries to Control the Scope of Aggregations

Aggregations, such as collect() and count(), show up as EagerAggregation operators (with dark blue headers) in query plans. These are similar to the Eager operator in that it presents a…

Read more

Warm the cache to improve performance from cold start

Note: For 3.5.x forward the details below are no longer applicable as Neo4j will keep record of what is in the pagecache at all times and upon restart of Neo4j…

Read more