firebase-tools icon indicating copy to clipboard operation
firebase-tools copied to clipboard

Firebase Deploy Functions Failed (Linux): libc.so.6, GLIBC_2.28, required by node (maybe a more helpful error message?)

Open psygo opened this issue 3 years ago • 3 comments

This was originally posted on StackOverflow.

I'm trying to deploy a function which is working locally with the emulators, but, when trying to deploy, give me this:

i  functions: creating Node.js 16 function <function-name>(us-central1)...
Build failed: node: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.28'
not found (required by node); Error ID: 653c7ba4

Functions deploy had errors with the following functions:
        <function-name>(us-central1)
i  functions: cleaning up build files...

Error: There was an error deploying functions

What I've tried so far:

  1. Downgrade my Node version from 18 to 16.

    Yes, I do have this in my package.json:

    "engines": {
      "node": "16"
    },
    
  2. Rebuild everything from scratch with Node 16.

I think libc.so.6 is related to Java, but I don't know how that helps. Here is my java --version:

java 19 2022-09-20
Java(TM) SE Runtime Environment (build 19+36-2238)
Java HotSpot(TM) 64-Bit Server VM (build 19+36-2238, mixed mode, sharing)

I'm using Archcraft, a distro based on Arch Linux.

I've just realized that I can share my whole repo, since it's an open source project. Here it is.

A related issue.

psygo avatar Sep 30 '22 13:09 psygo

I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight.

google-oss-bot avatar Sep 30 '22 13:09 google-oss-bot

Apparently, my mistake was that my node version in package.json was actually 18.x.x, and now that I went back to a 16.x.x, everything seems to work fine — I was confused because my global node is 16.x.x. That error message really doesn't help though...

Also, I don't know why but deploying defaults to US even though I'm registered as southamerica-east1, but that's another issue entirely...

psygo avatar Sep 30 '22 19:09 psygo

Hi, looks like this is an issue about deploying Firebase Functions using the CLI so I think the repo you are looking for is firebase-tools which is the code for the CLI. I can transfer this issue.

hsubox76 avatar Oct 07 '22 20:10 hsubox76

I have the same issue even after adjusting package.json node version to 16.

benboughton1 avatar Dec 23 '22 13:12 benboughton1

I have the same issue even after adjusting package.json node version to 16.

I also have this issue. @psygo Can you clarify what you mean when you said you changed your node version to 16.x.x? Hadn't you already tried changing engines.node to 16?

kyduff avatar Mar 29 '23 10:03 kyduff

I would also add that your nodejs version in your firebase.json overrides the nodejs version set in your package.json as described here: https://firebase.google.com/docs/functions/manage-functions?gen=2nd#set_nodejs_version

Seems like your issue is now resolved, @psygo?

russellwheatley avatar Nov 10 '23 16:11 russellwheatley

Hey @psygo. We need more information to resolve this issue but there hasn't been an update in 7 weekdays. I'm marking the issue as stale and if there are no new updates in the next 3 days I will close it automatically.

If you have more information that will help us get to the bottom of this, just add a comment!

google-oss-bot avatar Nov 21 '23 02:11 google-oss-bot

Since there haven't been any recent updates here, I am going to close this issue.

@psygo if you're still experiencing this problem and want to continue the discussion just leave a comment here and we are happy to re-open this.

google-oss-bot avatar Nov 24 '23 02:11 google-oss-bot