Issue with a credential after upgrade

Describe the problem/error/question

Hello,

We have a self-hosted instance of n8n that was installed with Docker. We have upgrade the instance from version 0.263.3 to version 1.1.1 . The upgrade process was quite slow - several days - but the instance can now take requests.

Unfortunately, the workflows can not be activated because of a credential issue.

Screenshot 2023-08-22 at 18.27.29

But in the screen Credentials, there is no apparent issues.

I tried to inspect the SQLite database but I could not found a stale credential - I am not very familiar with the database structure.

The instance was migrated with the following commands :

$ docker pull n8nio/n8n:latest 
$ docker-compose down
$ docker-compose --env-file .env up

Here is the content of the .env file - some information are not revealed :

# Folder where data should be saved
DATA_FOLDER=/path/to/n8n/data

# The top level domain to serve from
DOMAIN_NAME=...

#public domain name
PUBLIC_DOMAIN_NAME=...

# The subdomain to serve from
SUBDOMAIN=...

# DOMAIN_NAME and SUBDOMAIN combined decide where n8n will be reachable from
# above example would result in: https://n8n.example.com

# The user name to use for autentication - IMPORTANT ALWAYS CHANGE!
N8N_BASIC_AUTH_USER=admin

# The password to use for autentication - IMPORTANT ALWAYS CHANGE!
N8N_BASIC_AUTH_PASSWORD=...

# Optional timezone to set which gets used by Cron-Node by default
# If not set New York time will be used
GENERIC_TIMEZONE=...

# The email address to use for the SSL certificate creation
SSL_EMAIL=...

# logs
N8N_LOG_LEVEL=verbose
N8N_LOG_OUTPUT=file
N8N_LOG_FILE_LOCATION=/var/log/n8n.log
N8N_LOG_FILE_MAXSIZE=50
N8N_LOG_FILE_MAXCOUNT=100

Here are information about our setup :

  • n8n version: 0.263.3 to 1.1.1
  • Database (default: SQLite): SQLite
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app): docker
  • Operating system: Ubuntu 20.04.2 LTS

Hey @Nathaniel_Seymour,

Welcome to the community :tada:

That is unusual, Are you able to open any of the credentials in the UI?

Hello Jon :wink:,

Thank you very much. I can open all the credentials in the UI but one. The credential that I can not open - AirTable API - does not seem to be related to the credential that prevent the activation of a workflow.

Hi @Nathaniel_Seymour

I have had this happen as well.
For me when using postgres I had to reindex the database to fix it.
Was random credentials and also workflows on multiple of my instances.

1 Like

Hello

Thank you very much. I will look for reindexing the database. Should I recreate the indexes with the database functions ?

HI @Nathaniel_Seymour, I didn’t know about this very problem yet but I’d say yes from reading through the thread and seeing @BramKn’s solution. In SQLite you can simply use the REINDEX statement for this.

I am still not sure what would have caused this problem. Did you guys run into any trouble during the upgrade (or just slow)? The slowness itself probably comes down to having a large number of executions in the database and you might want to configure data pruning going forward to speed things up.

1 Like

Hi @MutedJam

Upgrade went smoothly and the issue happened with a fairly recent installed instance as well.
However I did mess around in the database, so maybe I messed something up there. But that does seems strange as I have seen it happen in multiple places also where I didn’t recently do anything in the database.

1 Like