Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bad Gateway Error and Main n8n Crash if binary Data is missing in Execution View #5063

Closed
prononext opened this issue Dec 30, 2022 · 4 comments · Fixed by #5242
Closed

Bad Gateway Error and Main n8n Crash if binary Data is missing in Execution View #5063

prononext opened this issue Dec 30, 2022 · 4 comments · Fixed by #5242

Comments

@prononext
Copy link

I had a workflow failing because of execution data was missing.
It was a workflow that downloaded images, resized them and uploaded to s3 again.

I do not know why the data was not avilable while execution, but I noticed that when I went to the execution view in UI and choose the node with the problem. I tried to view the missing binary data and at that moment it got a "Gateway Error" and the whole UI Crashed with the n8n main container in my queue setup. I tried this 4 times with the same result.

There was a log in the n8n main service.

Error: ENOENT: no such file or directory, open '/home/node/.n8n/binaryData/851a4932bf2-e66e-41f6-819a-489030c232f9.metadata'

System Details:

POSTGRESQL_VERSION_TAG=12.13
REDIS_VERSION_TAG=alpine
N8N_VERSION_TAG=0.209.2
EXECUTIONS_DATA_MAX_AGE=14
EXECUTIONS_DATA_PRUNE=true
N8N_DEFAULT_BINARY_DATA_MODE=filesystem
@Joffcom
Copy link
Member

Joffcom commented Jan 4, 2023

Hey @prononext,

I think the binary data only exists on disk for a limited amount of time, Maybe 24 hours with the default settings so if you are rerunning a workflow that failed that could be why. The Gateway error could be something else as well it is hard to say without seeing the full error.

@janober
Copy link
Member

janober commented Jan 24, 2023

That is very strange. Binary data of saved executions should stay around indefinitely. Only for manual executions, where saving execution data is disabled will it be auto-deleted after a certain time.

But obviously should also never crash!

@netroy
Copy link
Member

netroy commented Jan 24, 2023

This was fixed in #4964.
But unfortunately, all executions (with nodes that don't use streaming) between 0.206.1 and 0.208.1 are missing the metadata file, and are prone to this crash.
I'll create a PR to handle this without crashing the service.

@janober
Copy link
Member

janober commented Jan 27, 2023

Fix got released with n8n@0.213.0

@janober janober removed the Upcoming Release Will be part of the upcoming release label Jan 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants