TransWikia.com

How to start Neo4j on Azure

Database Administrators Asked by David A Stumpf on October 28, 2021

I’m running Neo4j v4.x on an Azure VM (Linux Ubunto 16.04). Everything was running fine until my project required a resizing for more storage. This seemingly went well as I proceeded to load data, but then a glitch of unknown type caused the Neo4j server to stop. I could no longer access it from the Neo4j broweser or from python code that queries it. I’ve restarted the VM. No effect. Even redeployed the VM without effect. From Putty:

neo4j status
Neo4j is not running

I’ve tried numerous commands, but this one comes closest to trying to do something:

sudo ssh {myusername}@{vm ip} "systemctl restart neo4j V4_0.service"

It asked for my password and accepted it (rejected errors) and then gave me

Failed to restart neo4j.service: Interactive authentication required.
See system logs and ‘systemctl status neo4j.service’ for details.
Failed to restart V4_0.service: Interactive authentication required.
See system logs and ‘systemctl status V4_0.service’ for details.

I thought I’d authenicated. In debugging, i tried entering bad username or password and was immediately rejected as expected.

Another set of info generated by the command

root@neo4jVM:/etc/init.d# neo4j start

result:

Directories in use:
home: /var/lib/neo4j
config: /etc/neo4j
logs: /var/log/neo4j
plugins: /var/lib/neo4 j/plugins
import: /var/lib/neo4j/import
data: /var/lib/neo4j/data
certificates: /var/lib/neo4j/certificates
run: /var/run/neo4j Starting Neo4j.
WARNING: Max 1024 open files allowed,minimum of 40000 recommended. See the Neo4j manual. Started neo4j (pid> 71995). It is available at http://0.0.0.0:7474/ There may be a shortdelay until the server is ready. See /var/log/neo4j/neo4j.log for current status.

Despite the promising message, it never started and Http://0.0.0.0:7474 did not connect.

for clarification, I tried variations on the one command in Putty: sudo ssh [email protected] "systemctl restart neo4j" sudo ssh [email protected] "systemctl restart neo4j.service" etc.

Exploring the Neo4j log, I found this ….LifecycleManagingDatabaseService@78116659′ was successfully initialized, but failed to start.

What am I missing?

One Answer

The problem has been solved with help from Neo4j support. Hopefully they will fix the bug so you will not face this issue. For some reason one line was not in the template used to install the Neo4j VM.

The problem was there was not a listener for all the Neo4j ports in the neo4j.conf file. Make sure they are there for all three ports (7473, 7474 and 7687). The format is:

dbms.connector.bolt.listen_address=0.0.0.0:7687

You might also need a default listener:

dbms.default_listen_address=0.0.0.0

Other insights learned in debugging this:

  1. When you restart the VM, it may take several minutes for the Neo4j Browser and python code capabilities to recycle and come up.
  2. In Putty, the command "neo4j status" will return "neo4j is not running" even when it is.

Answered by David A Stumpf on October 28, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP