NEO4J: Couldn't load the external resource at: file:/var/lib/neo4j/import/

我只是一个虾纸丫 提交于 2019-12-24 17:19:08

问题


I am running Neo4J on Docker within Vagrant.

I am attempting to LOAD CSV WITH HEADERS from a file within the /import/ directory (I had to move my file there) via a cURL request. My request looks something like this:

"LOAD CSV WITH HEADERS FROM \"file:///insert-neo4j.csv\" AS row ...

This provides me with the following error:

{"results":[],"errors [{"code":"Neo.ClientError.Statement.ExternalResourceFailed","message":"Couldn't load the external resource at: file:/var/lib/neo4j/import/insert-neo4j.csv"}]}

It is often suggested to me that I append the following to my '/conf/neo4j.conf' file, however this file DOES NOT EXIST, and creating it manually does not seem to work...

dbms.directories.import=import
dbms.security.allow_csv_import_from_file_urls=true

So I created the file /conf/neo4j.conf with the above variables, and I also tried adding these as environment variables to my docker-compose file. I seem to continuously have no luck uploading via CSV this way.

My questions are:

  • Is there anything blatantky wrong with this implementation?
  • Why does my /conf/neo4j.conf file NOT exist and how can I get it created?

Thank you

(p.s. my insert-neo4j.csv has -rwxr-xr-x)


回答1:


The error message indicates it found the file but there is an error in the CSV ... most likely the formatting. Check this and if you can't see it, please post a few rows, including the header, of it so we might help.



来源:https://stackoverflow.com/questions/48937704/neo4j-couldnt-load-the-external-resource-at-file-var-lib-neo4j-import

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!