Error: unable to find the IP address for the container after upgrade to 0.185.0

Describe the issue/error/question

I updated to the latest version (based on this docs). n8n shows only bad gateway error. I went through many of threads here but did not find the solution.

What is the error message (if any)?

See the screenshot.

Information on your n8n setup

  • n8n version: previously on 0.183.0
  • Database you’re using (default: SQLite): default
  • Running n8n with the execution process [own(default), main]: default
  • Running n8n via [Docker, npm, n8n.cloud, desktop app]: doccker, digitalocean ubuntu droplet

Thanks!

As this is a production instance, I needed to restore the droplet backup, and it works now. Any ideas about what went wrong and/or suggestions for preventing this from happening? Thank you (uffff :slight_smile: )

Hi @honzapav, I am sorry to hear you’re having trouble.

Your screenshot suggests n8n was trying to write to /home/jim/n8n/logs which isn’t a standard directory n8n would usually write to.

Did you by any chance change your docker-compose.yml file as part of the update?

Hello, thanks for the response. I understood this could be a problem, but I thought I hadn’t touched anything :smile:

But – the address is there. About three weeks ago, I set up logging and used this example: Logging - n8n Documentation – the address is here, and it was dumb from my side to assume this is some “default” directory.

So, I understand there was a problem with logs. But it worked before the update… any ideas why this happened? Is it possible that the log setup wasn’t active until I triggered the update?

Thanks a lot! :raised_hands:

So, I understand there was a problem with logs. But it worked before the update… any ideas why this happened? Is it possible that the log setup wasn’t active until I triggered the update?

Could, this sometimes happens to myself when I just restart a docker container instead of fully re-creating it.

As for logging, I typically leave log management to docker and don’t configure it in my containers. But I’ve tested the below approach which worked for me:

  1. Set the N8N_LOG_FILE_LOCATION=/home/node/logs/n8n.log environment variable in my docker compose file.
  2. Mount my local /home/tom/containers/n8n/logs folder inside the container as /home/node/logs by adding a volume entry like /home/tom/containers/n8n/logs:/home/node/logs to my docker compose file.

So I think if you simply change the local portion above to /home/jim/n8n/logs and then re-create your container (using something like docker compose up --force-recreate --detach) you should get the log file you’re looking for :slight_smile:

Thank you – as you can see, Docker is not my strength (I’m a complete newbie). I was trying to get my logs from the docker container, but I wasn’t able to do this (honestly, did not spend too much time with research) and thought the log setup was the correct one (and it is but for a different reason :smile:).

So the right question is, how can I get the logs from the n8n docker container? It’s perfectly fine if you just direct me to a docs page etc. I don’t want to take more of your time.

Thank you.

So the commands you were looking for are probably either

  • docker compose logs or docker-compose logs (if you use docker compose, you would need to run the command in the folder holding your docker compose file. Reference
  • docker logs n8n_1 (where n8n_1 is the name of your container). Reference

You can also add the --follow option to each command to see a continuous stream of logs.

If you’re using docker desktop you can also view the logs by simply clicking on the respective container:

Ok, it seems like I’ve seen this before but wasn’t able to use it properly. I am going to try this. Thank you very much! :raised_hands:

You’re most welcome, give me a shout if you run into any trouble here!

Yes, I removed the logging part of docker-compose.yml, updated n8n to the latest version (it works!) and got the logs. And by the way learned some new stuff :wink:.

Thank you!

1 Like

Awesome, glad to hear this is working & thanks for confirming :slight_smile: