# Cannot Load data into Neo4j using AWS S3 pre signed URL

**URL:** <https://community.neo4j.com/t/cannot-load-data-into-neo4j-using-aws-s3-pre-signed-url/11834>\
**Category:** Import / Export\
**Created:** [November 12, 2019, 6:36pm UTC](https://community.neo4j.com/t/cannot-load-data-into-neo4j-using-aws-s3-pre-signed-url/11834 "2019-11-12T18:36:57Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![amanjain1527](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/amanjain1527/32/5469_2.png) [@amanjain1527](https://community.neo4j.com/u/amanjain1527)\
**Post date:** [November 12, 2019, 6:36pm UTC](https://community.neo4j.com/t/cannot-load-data-into-neo4j-using-aws-s3-pre-signed-url/11834/1 "2019-11-12T18:36:57Z")

</div>

Hi , I am trying to load data from AWS s3 bucket using a Pre signed URL and getting the below error

Command -  
LOAD CSV WITH HEADERS FROM '\<presigned\_url\>' AS ROW RETURN ROW LIMIT 10;

Error -  
Neo.ClientError.Statement.ExternalResourceFailed: Couldn't load the external resource at: https://.s3.amazonaws.com/temp.csv?AWSAccessKeyId=\*\*\*\*\*\*\*\*\*\*\*&Signature=\*\*\*\*_ **security-token=** _

My Neo4j is running on Kubernetes. Should my file have to be publicly accessible ?? What other options I can check ? I have also set **dbms.security.allow\_csv\_import\_from\_file\_urls=true**

---

<div class="post-metadata">

**Author:** ![dana\_canzano](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/dana_canzano/32/27392_2.png) [@dana\_canzano](https://community.neo4j.com/u/dana_canzano)\
**Post date:** [November 13, 2019, 1:04am UTC](https://community.neo4j.com/t/cannot-load-data-into-neo4j-using-aws-s3-pre-signed-url/11834/2 "2019-11-13T01:04:31Z")

</div>

a KB was created for this sometime ago and as described at

> **[Load CSV data in Neo4j from CSV files on Amazon S3 Bucket - Knowledge Base](https://neo4j.com/developer/kb/load-csv-data-from-csv-files-on-aws-s3-bucket/)**
>
> Neo4j provides LOAD CSV cypher command to load data from CSV files into Neo4j or access CSV files via HTTPS, HTTP and FTP. But how do you load data from…

can you review and see if it fills in the missing details

---

<div class="post-metadata">

**Author:** ![amanjain1527](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/amanjain1527/32/5469_2.png) [@amanjain1527](https://community.neo4j.com/u/amanjain1527)\
**Post date:** [November 13, 2019, 1:02pm UTC](https://community.neo4j.com/t/cannot-load-data-into-neo4j-using-aws-s3-pre-signed-url/11834/3 "2019-11-13T13:02:40Z")

</div>

I saw two probable solutions there -

1. set **dbms.security.allow\_csv\_import\_from\_file\_urls=true**
2. neo4j.conf, comment out or delete **dbms.directories.import=import**

how to comment out or delete **dbms.directories.import=import** during Neo4j installation through Kubernetes.

---

<div class="post-metadata">

**Author:** ![david\_allen](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/david_allen/32/13090_2.png) [@david\_allen](https://community.neo4j.com/u/david_allen)\
**Post date:** [November 13, 2019, 4:15pm UTC](https://community.neo4j.com/t/cannot-load-data-into-neo4j-using-aws-s3-pre-signed-url/11834/4 "2019-11-13T16:15:45Z")

</div>

In Kubernetes, neo4j runs within docker containers. Use these docs and use the "environment variable syntax" for passing the config you need to your container, and the docker/kubernetes install works just like the regular Neo4j install method.

> **[Configuration - Operations Manual](https://neo4j.com/docs/operations-manual/current/docker/configuration/)**
>
> This chapter describes how to configure Neo4j to run in a Docker container. It also describes how to use a custom Neo4j Docker image to run Neo4j in a Docker container.

---

<div class="post-metadata">

**Author:** ![amanjain1527](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/amanjain1527/32/5469_2.png) [@amanjain1527](https://community.neo4j.com/u/amanjain1527)\
**Post date:** [November 13, 2019, 6:46pm UTC](https://community.neo4j.com/t/cannot-load-data-into-neo4j-using-aws-s3-pre-signed-url/11834/5 "2019-11-13T18:46:02Z")

</div>

David,  
We are using helm command to install neo4j. I am not sure how to set properties neo4j.conf while installing through heml. I am new to Kubernetes. Could you please help? Also do we need check our bucket policies/ IAM roles ? Can this be a reason for this error ?

---

<div class="post-metadata">

**Author:** ![amanjain1527](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/amanjain1527/32/5469_2.png) [@amanjain1527](https://community.neo4j.com/u/amanjain1527)\
**Post date:** [November 13, 2019, 6:48pm UTC](https://community.neo4j.com/t/cannot-load-data-into-neo4j-using-aws-s3-pre-signed-url/11834/6 "2019-11-13T18:48:25Z")

</div>

David  
Below are the kubernetes commands used in our .gitlab-ci.yaml file

- export KOPS\_STATE\_STORE=s3://\<bucket\_name\>
  - export NAME=\<cluster\_name\>
  - export KUBECONFIG=$HOME/.kube/config
  - kops export kubecfg --name=$NAME
  - kubectl apply -f ./k8s/ingress-bolt.yaml
  - kubectl apply -f ./k8s/ingress.yaml
  - helm upgrade --install neo4j stable/neo4j -f k8s/values.yaml --namespace dev-tem
  - kubectl get services
  - kubectl get pods --all-namespaces

Let me know if you need any other information.  
Thanks

---

<div class="post-metadata">

**Author:** ![david\_allen](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/david_allen/32/13090_2.png) [@david\_allen](https://community.neo4j.com/u/david_allen)\
**Post date:** [November 13, 2019, 6:58pm UTC](https://community.neo4j.com/t/cannot-load-data-into-neo4j-using-aws-s3-pre-signed-url/11834/7 "2019-11-13T18:58:39Z")

</div>

What you've got here is not the right approach. What you rather need to do is get a copy of the helm chart templates and adjust the environment variables passed to the pod to add your own custom configuration. Any variables you do with `export` here will have no effect.

When you type `helm upgrade --install stable/neo4j` this repo is where that code resides. You should grab the code this repo, and adjust the environment variables right here:

> <https://github.com/helm/charts/blob/master/stable/neo4j/templates/core-statefulset.yaml#L26>
