Migration error on fresh deployment of 1.45.2 in kubernetes

Describe the problem/error/question

I’m trying to spin up an n8n instance in kubernetes as a fresh install. I have a database created and the connection works (it created 22 tables) but then the docker container bombs out with a migration error.

I should also mention that I tried a publicly accessible postgres instance in AWS RDS and it connected but didn’t even create the tables.

What is the error message (if any)?

n8n-main-678685d966-4k852:n8n-main Error: There was an error running database migrations
n8n-main-678685d966-4k852:n8n-main QueryFailedError: Cannot change column 'workflowId': used in a foreign key constraint 'fk_<DB PREFIX>_execution_entity_workflow_id'

Information on your n8n setup

  • n8n version: 1.45.2
  • Database (default: SQLite): mysql 8.0.29
  • n8n EXECUTIONS_PROCESS setting: default
  • Running n8n via: Docker/Kubernetes
  • Operating system: linux

It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

I’ve updated with the required details

MySQL support was deprecated a year ago, and we highly recommend using n8n with postgres instead.

2 Likes

thank you for the help. I’m struggling to get my Postgres DB up and running but I will keep trying and report back if the issue is resolved by changing it out.

Luckily since it’s a test environment and a new deployment it isn’t too hard to re-deploy the steps with new settings.

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