neo4j-contrib / neo4j-graph-algorithms

Efficient Graph Algorithms for Neo4j
https://github.com/neo4j/graph-data-science/
GNU General Public License v3.0
767 stars 196 forks source link

Docker configuration fails. Graph Algos & APOC #910

Closed anthonygtellez closed 4 years ago

anthonygtellez commented 4 years ago

I've tried the following docker configurations:

$ docker run -i -t \ -p 7474:7474 -p 7687:7687 \ -v $HOME/neo4j/data:/data -v $HOME/neo4j/plugins:/plugins -v $HOME/neo4j/conf:/conf \ --name neo4j-apoc \ -e NEO4J_apoc_export_file_enabled=true \ -e NEO4J_apoc_import_file_enabled=true \ -e NEO4J_apoc_import_file_use__neo4j__config=true \ -e NEO4J_dbms_security_procedures_unrestricted=apoc.\\\*,algo.\\\* \ -e NEO4J_dbms_security_procedures_whitelist=apoc.\\\*,algo.\\\* \ -e NEO4J_ACCEPT_LICENSE_AGREEMENT=yes \ neo4j:3.5.6-enterprise

Version without environmental variables:

docker run -i -t \ --name testneo4j \ -p7474:7474 -p7687:7687 \ -d \ -v $HOME/neo4j/data:/data \ -v $HOME/neo4j/logs:/logs \ -v $HOME/neo4j/conf:/conf \ -v $HOME/neo4j/import:/var/lib/neo4j/import \ -v $HOME/neo4j/plugins:/plugins \ -e NEO4J_AUTH=neo4j/test \ -e NEO4J_ACCEPT_LICENSE_AGREEMENT=yes \ neo4j:3.5.6-enterprise

$ cat neo4j/conf/neo4j.conf

dbms.security.procedures.unrestricted=apoc.*,algo.*
dbms.security.procedures.whitelist=apoc.*,algo.*

Found in the logs: ERROR [o.n.k.i.p.Procedures] Plugin jar file: /plugins/neo4j-graph-algorithms-3.5.6.1-standalone.jar corrupted.

md5sum neo4j-graph-algorithms-3.5.6.1-standalone.jar
0f518ba646e4153b8365ffc197534c8f  neo4j-graph-algorithms-3.5.6.1-standalone.jar

2019-08-06 01:32:58.925+0000 ERROR [o.n.k.i.p.Procedures] Plugin jar file: /plugins/apoc-3.5.0.4-all.jar corrupted.

md5sum apoc-3.5.0.4-all.jar
06806390da1202bbcbd165d7d79fe2dc  apoc-3.5.0.4-all.jar

I am using the versions referenced in the documentation found here: https://github.com/neo4j-contrib/neo4j-graph-algorithms/blob/master/versions.json

This should be easily reproducible hope someone can guide me on what exactly I'm missing to correctly start up APOC & Graph Algos.

jexp commented 4 years ago

can you try to list the contents of the jar? I.e. jar tf apoc-3.5.0.4-all.jar how did you download it?

anthonygtellez commented 4 years ago

I used wgetto pull the files directly to the server. Both jars reside in /home/ubuntu/neo4j/plugins. The contents lists for both files. when running $ jar tf

anthonygtellez commented 4 years ago

Solved, permissions issue. wget defaults the permissions to 400. This was different than the permissions seen in my desktop version. Changed to be executable and now there isn't an issue.