billy
PPrisma
•Created by billy on 4/29/2025 in #help-and-questions
Prisma Client could not locate the Query Engine for runtime "rhel-openssl-3.0.x" error on deployment
Prisma works locally and I can invoke my server actions without any problem. However, when I deploy, I get
Unhandled Rejection: Error [PrismaClientInitializationError]: Prisma Client could not locate the Query Engine for runtime "rhel-openssl-3.0.x".
We detected that you are using Next.js, learn how to fix this: https://pris.ly/d/engine-not-found-nextjs.
This is likely caused by a bundler that has not copied "libquery_engine-rhel-openssl-3.0.x.so.node" next to the resulting bundle.
Ensure that "libquery_engine-rhel-openssl-3.0.x.so.node" has been copied next to the bundle or in "generated/prisma".
We would appreciate if you could take the time to share some information with us.
Please help us by answering a few questions: https://pris.ly/engine-not-found-bundler-investigation
The following locations have been searched:
/var/task/generated/prisma
/var/task/.next/server
/vercel/path0/generated/prisma
/var/task/.prisma/client
/tmp/prisma-engines
at yl (.next/server/chunks/546.js:64:756)
at async Object.loadLibrary (.next/server/chunks/546.js:111:10410)
at async Gr.loadEngine (.next/server/chunks/546.js:112:448)
at async Gr.instantiateLibrary (.next/server/chunks/546.js:111:13913) {
clientVersion: '6.6.0',
errorCode: undefined
}
Node.js process exited with exit status: 128. The logs above can help with debugging the issue.
error. generator client {
provider = "prisma-client-js"
output = "../generated/prisma"
}
datasource db {
provider = "postgresql"
url = env("DATABASE_URL")
directUrl = env("DIRECT_URL")
}
"scripts": {
"dev": "next dev",
"build": "prisma generate && next build",
"start": "next start",
"lint": "next lint"
},
"prisma": {
"seed": "ts-node --compiler-options {"module":"commonjs"} prisma/seed.ts"
}
and i am using prisma 6.6.0 in nextjs 15.3.1. I am deploying it to vercel and it builds without any problem.4 replies