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

Error: Unable to establish a connection to query-engine-node-api library on Cpanel #17374

Open
coderboysobuj opened this issue Jan 17, 2023 · 11 comments
Labels
bug/1-unconfirmed Bug should have enough information for reproduction, but confirmation has not happened yet. kind/bug A reported bug. team/client Issue for team Client. topic: deployment/cpanel topic: engine

Comments

@coderboysobuj
Copy link

coderboysobuj commented Jan 17, 2023

Bug description

when I run Prisma generate on my local computer It's work but when I'm trying to run Prisma generate on Shared host Cpanel It's give a error

Error: Unable to establish a connection to query-engine-node-api library. It seems that the current architecture x64 is not supported, or that libc is missing from the system.
Details: Unable to require(/home/crafiebs/nodevenv/node_api/14/lib/node_modules/prisma/libquery_engine-debian-openssl-1.0.x.so.node)
/lib64/libc.so.6: version `GLIBC_2.14' not found (required by /home/crafiebs/nodevenv/node_api/14/lib/node_modules/prisma/libquery_engine-debian-openssl-1.0.x.so.node)

I'm not able to fixed it. What should I do?

How to reproduce

Expected behavior

No response

Prisma information

// Add your schema.prisma
// Add your code using Prisma Client

Environment & setup

  • OS:
  • Database:
  • Node.js version:

Prisma Version


@coderboysobuj coderboysobuj added the kind/bug A reported bug. label Jan 17, 2023
@Jolg42 Jolg42 added bug/1-unconfirmed Bug should have enough information for reproduction, but confirmation has not happened yet. team/client Issue for team Client. topic: engine topic: deployment/cpanel labels Jan 17, 2023
@Jolg42
Copy link
Member

Jolg42 commented Jan 17, 2023

@coderboysobuj Could you edit the description of this issue and add information in Environment & setup and Prisma Version?

@janpio janpio changed the title Error: Unable to establish a connection to query-engine-node-api library Error: Unable to establish a connection to query-engine-node-api library on Cpanel Jan 18, 2023
@janpio
Copy link
Member

janpio commented Jan 18, 2023

Also, which shared host are you using for Cpanel?

@zgramming
Copy link

zgramming commented Jan 20, 2023

@janpio i got same error when hosting prisma on CPanel, this is information i can tell :

Prisma -v

[public_html/api-bimtama (16)] [n1578093@srv150 api-bimtama]$ prisma -v
prisma:warn Prisma failed to detect the Linux distro in use, and may not work as                                                                                                                                                              expected. Defaulting to "debian".
Environment variables loaded from .env
prisma:warn Prisma failed to detect the Linux distro in use, and may not work as                                                                                                                                                              expected. Defaulting to "debian".
Error: Unable to require(`/home/n1578093/nodevenv/public_html/api-bimtama/16/lib                                                                                                                                                             /lib/node_modules/prisma/node_modules/@prisma/engines/libquery_engine-debian-ope                                                                                                                                                             nssl-1.1.x.so.node`)
 /lib64/libc.so.6: version `GLIBC_2.18' not found (required by /home/n1578093/no                                                                                                                                                             devenv/public_html/api-bimtama/16/lib/lib/node_modules/prisma/node_modules/@pris                                                                                                                                                             ma/engines/libquery_engine-debian-openssl-1.1.x.so.node)
    at load (/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/node_mod                                                                                                                                                             ules/prisma/build/index.js:91073:11)
    at getEngineVersion (/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/                                                                                                                                                             lib/node_modules/prisma/build/index.js:91870:16)
Error: Command failed with exit code 1: /home/n1578093/nodevenv/public_html/api-                                                                                                                                                             bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/engines/migration-en                                                                                                                                                             gine-debian-openssl-1.1.x --version
/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/node_modules/prisma/n                                                                                                                                                             ode_modules/@prisma/engines/migration-engine-debian-openssl-1.1.x: /lib64/libc.s                                                                                                                                                             o.6: version `GLIBC_2.18' not found (required by /home/n1578093/nodevenv/public_                                                                                                                                                             html/api-bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/engines/mig                                                                                                                                                             ration-engine-debian-openssl-1.1.x)
    at makeError (/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/nod                                                                                                                                                             e_modules/prisma/build/index.js:3641:18)
    at handlePromise (/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib                                                                                                                                                             /node_modules/prisma/build/index.js:4409:33)
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async getEngineVersion (/home/n1578093/nodevenv/public_html/api-bimtama/1                                                                                                                                                             6/lib/lib/node_modules/prisma/build/index.js:91873:20) {
  shortMessage: 'Command failed with exit code 1: /home/n1578093/nodevenv/public                                                                                                                                                             _html/api-bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/engines/mi                                                                                                                                                             gration-engine-debian-openssl-1.1.x --version',
  command: '/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/node_modu                                                                                                                                                             les/prisma/node_modules/@prisma/engines/migration-engine-debian-openssl-1.1.x --                                                                                                                                                             version',
  escapedCommand: '"/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/n                                                                                                                                                             ode_modules/prisma/node_modules/@prisma/engines/migration-engine-debian-openssl-                                                                                                                                                             1.1.x" --version',
  exitCode: 1,
  signal: undefined,
  signalDescription: undefined,
  stdout: '',
  stderr: "/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/node_modul                                                                                                                                                             es/prisma/node_modules/@prisma/engines/migration-engine-debian-openssl-1.1.x: /l                                                                                                                                                             ib64/libc.so.6: version `GLIBC_2.18' not found (required by /home/n1578093/nodev                                                                                                                                                             env/public_html/api-bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/                                                                                                                                                             engines/migration-engine-debian-openssl-1.1.x)",
  failed: true,
  timedOut: false,
  isCanceled: false,
  killed: false
}
Error: Command failed with exit code 1: /home/n1578093/nodevenv/public_html/api-                                                                                                                                                             bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/engines/introspectio                                                                                                                                                             n-engine-debian-openssl-1.1.x --version
/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/node_modules/prisma/n                                                                                                                                                             ode_modules/@prisma/engines/introspection-engine-debian-openssl-1.1.x: /lib64/li                                                                                                                                                             bc.so.6: version `GLIBC_2.18' not found (required by /home/n1578093/nodevenv/pub                                                                                                                                                             lic_html/api-bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/engines                                                                                                                                                             /introspection-engine-debian-openssl-1.1.x)
    at makeError (/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/nod                                                                                                                                                             e_modules/prisma/build/index.js:3641:18)
    at handlePromise (/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib                                                                                                                                                             /node_modules/prisma/build/index.js:4409:33)
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async getEngineVersion (/home/n1578093/nodevenv/public_html/api-bimtama/1                                                                                                                                                             6/lib/lib/node_modules/prisma/build/index.js:91873:20) {
  shortMessage: 'Command failed with exit code 1: /home/n1578093/nodevenv/public                                                                                                                                                             _html/api-bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/engines/in                                                                                                                                                             trospection-engine-debian-openssl-1.1.x --version',
  command: '/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/node_modu                                                                                                                                                             les/prisma/node_modules/@prisma/engines/introspection-engine-debian-openssl-1.1.                                                                                                                                                             x --version',
  escapedCommand: '"/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/n                                                                                                                                                             ode_modules/prisma/node_modules/@prisma/engines/introspection-engine-debian-open                                                                                                                                                             ssl-1.1.x" --version',
  exitCode: 1,
  signal: undefined,
  signalDescription: undefined,
  stdout: '',
  stderr: "/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/node_modul                                                                                                                                                             es/prisma/node_modules/@prisma/engines/introspection-engine-debian-openssl-1.1.x                                                                                                                                                             : /lib64/libc.so.6: version `GLIBC_2.18' not found (required by /home/n1578093/n                                                                                                                                                             odevenv/public_html/api-bimtama/16/lib/lib/node_modules/prisma/node_modules/@pri                                                                                                                                                             sma/engines/introspection-engine-debian-openssl-1.1.x)",
  failed: true,
  timedOut: false,
  isCanceled: false,
  killed: false
}
Error: Command failed with exit code 1: /home/n1578093/nodevenv/public_html/api-                                                                                                                                                             bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/engines/prisma-fmt-d                                                                                                                                                             ebian-openssl-1.1.x --version
/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/node_modules/prisma/n                                                                                                                                                             ode_modules/@prisma/engines/prisma-fmt-debian-openssl-1.1.x: /lib64/libc.so.6: v                                                                                                                                                             ersion `GLIBC_2.18' not found (required by /home/n1578093/nodevenv/public_html/a                                                                                                                                                             pi-bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/engines/prisma-fm                                                                                                                                                             t-debian-openssl-1.1.x)
    at makeError (/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/nod                                                                                                                                                             e_modules/prisma/build/index.js:3641:18)
    at handlePromise (/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib                                                                                                                                                             /node_modules/prisma/build/index.js:4409:33)
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async getEngineVersion (/home/n1578093/nodevenv/public_html/api-bimtama/1                                                                                                                                                             6/lib/lib/node_modules/prisma/build/index.js:91873:20) {
  shortMessage: 'Command failed with exit code 1: /home/n1578093/nodevenv/public                                                                                                                                                             _html/api-bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/engines/pr                                                                                                                                                             isma-fmt-debian-openssl-1.1.x --version',
  command: '/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/node_modu                                                                                                                                                             les/prisma/node_modules/@prisma/engines/prisma-fmt-debian-openssl-1.1.x --versio                                                                                                                                                             n',
  escapedCommand: '"/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/n                                                                                                                                                             ode_modules/prisma/node_modules/@prisma/engines/prisma-fmt-debian-openssl-1.1.x"                                                                                                                                                              --version',
  exitCode: 1,
  signal: undefined,
  signalDescription: undefined,
  stdout: '',
  stderr: "/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/lib/node_modul                                                                                                                                                             es/prisma/node_modules/@prisma/engines/prisma-fmt-debian-openssl-1.1.x: /lib64/l                                                                                                                                                             ibc.so.6: version `GLIBC_2.18' not found (required by /home/n1578093/nodevenv/pu                                                                                                                                                             blic_html/api-bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/engine                                                                                                                                                             s/prisma-fmt-debian-openssl-1.1.x)",
  failed: true,
  timedOut: false,
  isCanceled: false,
  killed: false
}
prisma                  : 4.9.0
@prisma/client          : 4.9.0
Current platform        : debian-openssl-1.1.x
Query Engine (Node-API) : E_CANNOT_RESOLVE_VERSION (at ../../nodevenv/public_htm                                                                                                                                                             l/api-bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/engines/libque                                                                                                                                                             ry_engine-debian-openssl-1.1.x.so.node)
Migration Engine        : E_CANNOT_RESOLVE_VERSION (at ../../nodevenv/public_htm                                                                                                                                                             l/api-bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/engines/migrat                                                                                                                                                             ion-engine-debian-openssl-1.1.x)
Introspection Engine    : E_CANNOT_RESOLVE_VERSION (at ../../nodevenv/public_htm                                                                                                                                                             l/api-bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/engines/intros                                                                                                                                                             pection-engine-debian-openssl-1.1.x)
Format Binary           : E_CANNOT_RESOLVE_VERSION (at ../../nodevenv/public_htm                                                                                                                                                             l/api-bimtama/16/lib/lib/node_modules/prisma/node_modules/@prisma/engines/prisma                                                                                                                                                             -fmt-debian-openssl-1.1.x)
Format Wasm             : @prisma/prisma-fmt-wasm 4.9.0-42.ceb5c99003b99c9ee2c1d                                                                                                                                                             2e618e359c14aef2ea5
Default Engines Hash    : ceb5c99003b99c9ee2c1d2e618e359c14aef2ea5
Studio                  : 0.479.0
[public_html/api-bimtama (16)] [n1578093@srv150 api-bimtama]$

Prisma Generate

[public_html/api-bimtama (16)] [n1578093@srv150 api-bimtama]$ npm run prisma:generate

> prisma:generate
> npx prisma generate

prisma:warn Prisma failed to detect the Linux distro in use, and may not work as expected. Defaulting to "debian".
Environment variables loaded from .env
Prisma schema loaded from prisma/schema.prisma
prisma:warn Prisma failed to detect the Linux distro in use, and may not work as expected. Defaulting to "debian".
Error: Unable to establish a connection to query-engine-node-api library. It seems that the current architecture x64 is not supported, or that libc is missing from the system.
Details: Unable to require(`/home/n1578093/nodevenv/public_html/api-bimtama/16/lib/node_modules/prisma/libquery_engine-debian-openssl-1.1.x.so.node`)
 /lib64/libc.so.6: version `GLIBC_2.18' not found (required by /home/n1578093/nodevenv/public_html/api-bimtama/16/lib/node_modules/prisma/libquery_engine-debian-openssl-1.1.x.so.node)
[Context: getDmmf]

Prisma CLI Version : 4.9.0
[public_html/api-bimtama (16)] [n1578093@srv150 api-bimtama]$

Environment & Setup

  • NPM : 8.15.0
  • Node : v16.17.1
  • Database : MariaDB

@janpio
Copy link
Member

janpio commented Jan 20, 2023

/lib64/libc.so.6: version `GLIBC_2.18' not found

This is a pretty clear error message, the environment where you try to run Prisma is missing some of the required system dependencies.

@zgramming
Copy link

@janpio with limited access to cpanel shared hosting, is there a solution for this other than moving the OS?

Traced from discussions that might be similar, there seems to be no solution other than moving the OS

@milon27
Copy link

milon27 commented Jan 30, 2023

with node version 18.13.0
prisma version: 4.6.1
docker : 20

same issue occurs, but no issue in node version 18.12.0

@Jolg42
Copy link
Member

Jolg42 commented Jan 30, 2023

@milon27 could you confirm and paste your full error message here?

@milon27
Copy link

milon27 commented Jan 30, 2023

@Jolg42

got the same error: Error: Unable to establish a connection to query-engine-node-api library when running npx primsa generate

@Jolg42
Copy link
Member

Jolg42 commented Jan 30, 2023

@milon27 Thanks! Nothing about GLIBC? Like

/lib64/libc.so.6: version `GLIBC_2.14' not found (required by /home/crafiebs/nodevenv/node_api/14/lib/node_modules/prisma/libquery_engine-debian-openssl-1.0.x.so.node)

@bandinopla
Copy link

so in this case, if you can't get to install the GLIBC library on the linux distribution you have there's no fix? I'm having this same issue but based on the comments here it would seem this issue is a wall and prisma can't be used in this scenario... is this correct?

@janpio
Copy link
Member

janpio commented Feb 4, 2023

Fundamentally, yes. If your system does not fulfill the system requirements, you can not run Prisma. (We are in the process of updating our documentation of these). This is not common though, as either 99% of systems already come with these or it is trivial to install them. Cpanel is special in that regard that it seems to be very stripped down, often old, and hard to adapt.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug/1-unconfirmed Bug should have enough information for reproduction, but confirmation has not happened yet. kind/bug A reported bug. team/client Issue for team Client. topic: deployment/cpanel topic: engine
Projects
None yet
Development

No branches or pull requests

6 participants