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
Knex: Timeout acquiring a connection. Server wasn't able to start properly. #8952
Comments
Hello, please follow the issue template. A proper issue submission let's us better understand the origin of your bug and therefore help you. I will reopen your issue when we receive the issue following the template guidelines and properly fill out the template. You can see the template guidelines for bug reports here. Please update the issue with the template and we can reopen this report. Thank you. |
This issue has been mentioned on Strapi Community Forum. There might be relevant details there: |
For anyone else that comes across this error while attempting to deploy to heroku, here is how I fixed it. I added the line It looks like the official strapi documentation now includes this, but I was attempting to deploy a legacy application that did not have this config. https://strapi.io/documentation/developer-docs/latest/concepts/configurations.html#example return {
connections: {
default: {
settings: {
client: 'postgres',
host: env('DATABASE_HOST', '127.0.0.1'),
port: env.int('DATABASE_PORT', 5432),
database: env('DATABASE_NAME', 'strapi'),
username: env('DATABASE_USERNAME', 'strapi'),
password: env('DATABASE_PASSWORD', 'strapi'),
schema: 'public',
ssl: { rejectUnauthorized: false }, // this line is required
},
}
}
} |
It always kind of existed but was never documented (since it comes from Knex and not Strapi itself) but yes I added this to the documentation a while ago 😉 |
Bug report
Describe the bug
0|strapi | [2020-12-19T22:56:19.076Z] debug ⛔️ Server wasn't able to start properly.
0|strapi | [2020-12-19T22:56:19.080Z] error KnexTimeoutError: Knex: Timeout acquiring a connection. The pool is probably full. Are you missing a .transacting(trx) call?
0|strapi | at Client_PG.acquireConnection (/home/ubuntu/strapi/node_modules/knex/lib/client.js:348:26)
Steps to reproduce the behavior
Expected behavior
A clear and concise description of what you expected to happen.
Screenshots
If applicable, add screenshots to help explain your problem.
Code snippets
If applicable, add code samples to help explain your problem.
System
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: