Error accessing Neo4J Browser online. I get ServiceUnavailable: WebSocket connection failure - neo4j

I have a Neo4J EC2 instance on AWS. I am able to access it programmatically, but when I try to access the Neo4J browser I get the error listed above. The URL I am using currently is:
http://35.174.211.60:7474/browser/
From there, I get the following page:
This page then tries to call the following URL:
bolt://35.174.211.60:7687
I use the username (neo4j) and password that already allows my code to access the Neo4J programmatically. From here I get the following error:
ServiceUnavailable: WebSocket connection failure. Due to security constraints in your web browser, the reason for the failure is not available to this Neo4j Driver.
I have verified that ports 7474, 7473, and 7687 are open to all in my EC2 Neo4J instance. What should I try next?

Try the fix suggested by this Knowledge Base article:
This error can be resolved by editing the file
$NEO4J_HOME/conf/neo4j.conf and uncommenting:
#To have Bolt accept non-local connections, uncomment this line:
dbms.connector.bolt.address=0.0.0.0:7687

Related

Getting Neo4J running on OpenShift

I am trying to get the Bitnami Neo4j image running on OpenShift (testing on my local Minishift), but I am unable to connect. I am following the steps outlined in this issue (now closed), however, now I cannot access the external IP for the load balancer.
Here are the steps I have taken:
Deploy Image (bitnami/neo4j)
Create service for the load balancer,
using the YAML supplied in the issue mentioned
Get the external IP
address for the LB (oc get services) The command in step 3 lists 2
of the same IP addresses, and when I attempt to go to this IP in my
browser it times out.
I can create a route that points to port 7374 on the IP of the LB, but
then I get the same error as reported in the aforementioned issue.
(ServiceUnavailable: WebSocket connection failure. Due to security
constraints in your web browser, the reason for the failure is not
available to this Neo4j Driver. Please use your browsers development
console to determine the root cause of the failure. Common)
Configure neo4j to accept non-local connections. E.g.:
dbms.connector.bolt.address=0.0.0.0:7687
Source: https://neo4j.com/developer/kb/explanation-of-error-websocket-connection-failure/

Unable to connect to Neo4J/ONgDB Browser when port forwarding

I am running the ONgDB container as per their Docker run command.
I have tested this locally on my laptop and it worked before, I was able to navigate to the graph browser and log in.
Now I am running this Graph in a server.
I did port forwarding to my laptop successfully, and am able to see ONgDB Browser in my laptop. However I am unable to log in, I get the error:
ServiceUnavailable: WebSocket connection failure. Due to security constraints in your web browser, the reason for the failure is not available to this Neo4j Driver. Please use your browsers development console to determine the root cause of the failure. Common reasons inc...
I found Neo4J article on how to resolve it.
I entered the ONgDB container filesystem and opened the .conf file, but there was no line to uncomment.
I tried to add the suggested line dbms.connector.bolt.address=0.0.0.0:7687 but it does not work as well.
How can I enable ONgDB Docker container for remote access?
I figured out the problem, in Neo4J/ONgDB browser, it fills the database host with localhost by default.
You just have to fill it in with the server's IP there and it works.
Also, you can connect using a desktop Neo4J/ONgDB browser to a remote graph, its just like a database (RDBMS) where you can connect to it from a client running locally.

How do I connect to a neo4j embedded instance via bolt using the neo4j browser?

I've followed the instructions in section 4.14 of the documentation but I can't figure out how to connect the neo4j browser to my embedded instance. Once the server is running, I open the browser via neo4j desktop and run :server connect. This prompts me for a host, username, and password. I'm not sure what to put for these values. I've tried many combinations of localhost, localhost:7687, and bolt://localhost:7687 for the host, and I've tried username/password combinations such as neo4j/neo4j, neo4j as a username with a blank password, and a blank username and password. I've never set a username and password for the database. No matter what I try, I always get the following error:
ServiceUnavailable: WebSocket connection failure. Due to security constraints in your web browser, the reason for the failure is not available to this Neo4j Driver. Please use your browsers development console to determine the root cause of the failure. Common reasons include the database being unavailable, using the wrong connection URL or temporary network problems. If you have enabled encryption, ensure your browser is configured to trust the certificate Neo4j is configured to use. WebSocket `readyState` is: 3
What are the proper values for host, username, and password?
Turns out either localhost:7687 or bolt://localhost:7687 is fine, and username/password can both be empty. Interestingly enough, the way I was building my uber-jar with maven seemed to make the bolt dependency unavailable. I switched to buck and the bolt connector seemed to start.

Cant login with Neo4j browser

I have installed neo4j on an EC2 instance and given port and access permissions to connect to it with chrome browser on my local machine.
The database is fluently accessible when I run db access codes on EC2, through py2neo. But when I open database using EC2-IP:7474 on my local chrome, I get to access the neo4j browser, but it does not let me login through. It always throws the error ServiceUnavailable: Failed to establish connection in 5000ms
The credentials are correct. They are the same with which I access the database from EC2. Screenshot attached. What can be possible reason for this and workaround to solve this issue?
I have gone through configuration file to uncomment lines such as
dbms.connector.bolt.listen_address=0.0.0.0:7687
dbms.connector.http.enabled=true
dbms.connector.http.listen_address=0.0.0.0:7474
dbms.connector.https.enabled=true
dbms.connector.https.listen_address=0.0.0.0:7473
But the problem persists.
This happened to be because I had opened port 7474 on the ec2 instance, but not the bolt port 7687.
You need to open this port 7687

Neo4j remote access from windows using putty

I installed Neo4j 3.2.6 on Ubuntu 16.04 and I tried to access it remotely using putty (from my windows-based computers). Without uncommenting anything in neo4j.conf, I can access Neo4j using the source port I defined in putty. Then, after connecting with the initial password "Neo4j" in the section saying "Connect to Neo4j Database access requires an authenticated connection.", I gets the famous error "ServiceUnavailable: WebSocket connection failure. Due to security constraints in your web browser, the reason for the failure is not available to this Neo4j Driver. Please use your browsers development console to determine ...".
So, after googling, I uncommented:
dbms.connectors.default_listen_address=0.0.0.0
dbms.connector.bolt.listen_address=:7687
BUT NOTHING WORKS.
The interesting thing is that I tried to install Neo4j on my laptop (locally) and it worked and when I used its "bolt://..." database access password on my remote access "bolt://..." database access it works.So, I'm not sure what is going on here, can someone help?

Resources