Can I use NFS as my filesystem or datastore storage?

The short answer is no. Although this may seem harmless, the reason for this is not performance related, but rather for control over locking files. NFS and other filesystems that don’t offer locking should not be used to install Neo4j… Read more →

Explore:  


Running Docker as Non-Root User

When running Neo4j Docker, it will run as neo4j user inside the container. But to run docker as a different user one can specify the –user argument. Documentation has a section for running as non-root user: https://neo4j.com/docs/operations-manual/3.4/installation/docker/#docker-user but would like… Read more →

Explore:  


A demonstration of IntraCluster SSL Encryption

This document provides a step-by-step demonstration of the process to deploy a Self-Signed SSL Certificate, to member instances of a Causal Cluster, aimed at achieving intra-cluster encryption. The steps can be outlined as: Generate and install cryptographic objects Create an… Read more →

Explore:  


Explanation of error “Unrecognized transaction id. Transaction may have timed out and been rolled back”

When submitting a request via the Neo4j Transactional Cypher HTTP endpoint, one may encounter the following error Unrecognized transaction id. Transaction may have timed out and been rolled back This error may occur as a result of the transactions expiration… Read more →

Explore:  


How to monitor if a follower is in sync with Leader (Causal Cluster)

To monitor if a Follower is in sync with its Leader, or know how much it is lagging behind, it is possible to check the Last Commited Transaction Id from Leader and Follower. Last Commited Transaction Id can be assessed… Read more →

Explore:  


Run multiple Causal Clusters locally using Docker

It’s rather easy to run multiple causal clusters on the same server or machine. You need to ensure: Each cluster needs to run on its own Docker network Overlapping port mappings must be prevented causal_clustering.initial_discovery_members needs to contain the list… Read more →

Explore:  


Displaying Query CPU Utilization and Allocated Bytes in Query log

In Neo4j 3.3 and prior versions, when query logging is enabled with the following configuration parameters: # Log executed queries that takes longer than the configured threshold. Enable by uncommenting this line. dbms.logs.query.enabled=true # If the execution of query takes… Read more →

Explore:  


Creating and working with linked lists in Cypher

At some point when working with a graph, you may want to create a linked list out of some nodes. If each of the nodes to be linked has its own variable, this is easy, you just do a CREATE… Read more →

Explore:  


Helpful Commands When Supporting Neo4j

Top 50 Slowest queries from Query log: $ grep -i “INFO” query.log | sort -r -n -k 4 | head -50 > long_queries.log Find Longest GC Pauses in debug or messages log: $ grep -n -i blocked debug.log | sort… Read more →

Explore:  


How to specify a separate debug.log for the backup process?

When running neo4j-admin backup on a running Neo4j instance the backup logs are also written into the existing Neo4j instance debug.log and can get confusing as to which line items in the debug.log is part of backup process and those… Read more →

Explore:  


Upstream strategy behaviour change

Starting with version 3.4, we changed in the behaviour of how instances sync with the Leader. This change can potentially affect the behaviour of your cluster when using strategy plugins, depending on your configuration. Pre-3.4 – on the context of… Read more →

Explore:  


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 kernel has over allocated memory to its processes. When a… Read more →

Explore:  


Diagnosing network latency in a Causal Cluster using MTR

MTR is a simple ICMP based test combining ping and traceroute. The following demonstrates usage of the MTR trace tool to diagnose network latency and packet loss in a Causal Cluster. The tool is commonly used on Windows via the… Read more →

Explore:  


How to set up SSL communcation when running Neo4j within a Docker Container

Neo4j 3.2 added a Unified SSL Framework to setup secure connections for Bolt, HTTPS and Intra-Cluster Encryption. Details on this framework can be found at: https://neo4j.com/docs/operations-manual/current/security/ssl-framework/ Setting up secure Bolt and HTTPS communications when running Neo4j within a Docker Container… Read more →

Explore:  


Using the ACTUAL data type with neo4j-import

When importing data using neo4j-admin import, make sure to review the required CSV file structure and considerations before moving on. https://neo4j.com/docs/operations-manual/current/tools/import/ ACTUAL vs. String (default) or Integer: Each node in the CSV must have an :ID, which can be in… Read more →

Explore:  


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 to benchmark your underlying storage. The command below will create… Read more →

Explore:  


Four ways to check the consistency of a Neo4j graph

When it comes checking the inconsistencies in your graph, there are four methods to do. This article describes them below: 1. The easiest approach is it to utilize the check-consistency=true option with the backup command. With this approach your graph… Read more →

Explore:  


Database was successfully initialized, but failed to start

Sometimes when the database does not start it could be something as simple as unnecessary characters in the neo4j.conf file. For example if you add space and/or tab characters to below setting: dbms.ssl.policy.client_policy.private_key=/var/lib/neo4j/certificates/client_policy/neo4j.key The database will fail to start and… Read more →

Explore:  


A note on OPTIONAL MATCHes

An OPTIONAL MATCH matches patterns against your graph database, just like a MATCH does. The difference is that if no matches are found, OPTIONAL MATCH will use a null for missing parts of the pattern. OPTIONAL MATCH could be considered… Read more →

Explore:  


How to check for time range overlap in Cypher

Neo4j 3.4 introduced temporal types into Cypher, so now we have dates, dateTimes, and their local versions, too, as well as durations. While we don’t have a type for time ranges, we can use two temporal instants as the start… Read more →

Explore:  


Achieving longestPath Using Cypher

While Cypher is optimized for finding the shortest path between two nodes, with such functionality as shortestPath(), it does not have the same sort of function for longest path. In some cases, you may want this, and not the shortest… Read more →

Explore:  


Resolve TLS certificate errors

TLS encryption is required everywhere. This is a compilation of few errors you can expect while configuring your server. openssl command is required to diagnose or manipulate the certificates. Check the permission on the folder neo4j might run as a… Read more →

Explore:  


Control number of file handles created per Lucene Index

In the more recent Neo4j versions (3.4 onwards), the number of file handles opened by Neo4j may seem to increase compared with that in older versions. Native indexes require a per-index constant number of file handles, and this number scales… Read more →

Explore:  


Understanding causal cluster quorum and cluster recovery

Several major causal cluster operations require a majority of cluster members to be online, a majority quorum. When a causal cluster loses majority quorum, it loses write capability as well as the ability to add or remove members of the… Read more →

Explore:  


Using explicit indexes for text search

Note Please note that in Neo4j 3.5 FullText search is available in Neo4j as part of Cypher stored procedures. More documentation is found here: https://neo4j.com/docs/cypher-manual/3.5/schema/index/#schema-index-fulltext-search. As of Neo4j 3.4.x, the schema index is optimal for indexing exact property values, but… Read more →

Explore: