Cant start Docker container

Hi, I’m new to n8n here. Just follow the guide to start n8n on Docker with the command

docker run -it --rm --name n8n -p 5678:5678 -v ~/.n8n:/home/node/.n8n docker.n8n.io/n8nio/n8n
Then got the error and the container stopped

n8n ready on 0.0.0.0, port 5678
Initializing n8n process
Error: ENOENT: no such file or directory, mkdir '/home/node/.cache'

Any help? Thanks a lot!

Hi @anhtuanngtr :wave: Welcome to the community! :cake:

Would you be able to post your Docker compose file here so we can look a little further into this? Please make sure to redact any sensitive information like passwords or keys when you do :+1:

Hey thanks for your response, just the very beginning step to try n8n in this Docker | n8n Docs
Just the first docker run in Starting n8n section

1 Like

Hmmm, I’ve tested with the latest Docker release and I’m not getting this error :thinking:

The volume is mapped to the containers /home/node/.n8n folder. The cache folder is outside of that at /home/node/.cache so it will be created inside the container (not the volume) by n8n.Could you delete your container and make sure to pull latest before trying again with docker pull docker.n8n.io/n8nio/n8n?

Could you also let us know what OS you’re on, and can you give this a shot without volume mapping (just in case that’s the issue)?

1 Like

Sure, another try without volume mount. Unfortunately not worked as expected

docker run -it --rm --name n8n -p 5678:5678 docker.n8n.io/n8nio/n8n

Unable to find image 'docker.n8n.io/n8nio/n8n:latest' locally
latest: Pulling from n8nio/n8n
8c6d1654570f: Already exists 
5be700ca177e: Pull complete 
f553329ee288: Pull complete 
e591100acf5b: Pull complete 
4f4fb700ef54: Pull complete 
22f21d49a3f1: Pull complete 
7a0b4084df7d: Pull complete 
aba100347274: Pull complete 
8f36abfcc935: Pull complete 
6db0205b3c65: Pull complete 
d71c378812a6: Pull complete 
Digest: sha256:a404c14f5b56065018af1ac457769670e5359789b2884f6a7cfee59449976184
Status: Downloaded newer image for docker.n8n.io/n8nio/n8n:latest
License manager not initialized
Error: ENOENT: no such file or directory, mkdir '/home/node/.n8n'
Error: Exiting due to an error.
Error: ENOENT: no such file or directory, mkdir '/home/node/.n8n'

Running on Mac M1 Ventura 13.3

I solved it by simply restarting my computer. Sound weird but able to start the container now

2 Likes

Glad to hear that you’re up and running, @anhtuanngtr !

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.