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

Node.js 8.3.0 for CentOS 6 has glibc dependency errors #513

Closed
danlange opened this issue Aug 11, 2017 · 3 comments
Closed

Node.js 8.3.0 for CentOS 6 has glibc dependency errors #513

danlange opened this issue Aug 11, 2017 · 3 comments

Comments

@danlange
Copy link

I installed node on my system:

% curl --silent --location https://rpm.nodesource.com/setup_8.x | sudo bash -
% sudo yum -y install nodejs

When I attempted to use it, it reported shared library errors:

% npm --version
node: error while loading shared libraries: cannot allocate memory in static TLS block
% node --version
node: error while loading shared libraries: cannot allocate memory in static TLS block

I am running CentOS 6, on which the only glibc option is 2.12:

% ldd --version
ldd (GNU libc) 2.12
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Written by Roland McGrath and Ulrich Drepper.

I was able to work around the problem by removing version 8.3.0 and installing version 8.2.1 instead:

% yum remove nodejs
...
% yum -y install nodejs-8.2.1
% npm --version
5.3.0

I was able to download and untar: https://nodejs.org/dist/v8.3.0/node-v8.3.0-linux-x64.tar.xz
When I ran it, it appeared to work correctly:

% ./node --version
v8.3.0
% ./npm --version
5.3.0
@chrislea
Copy link
Contributor

I've reproduced the issue, it's because of a glibc bug that exists on ancient distros.

I'm too tired right now to dig into it, but will look into what's going on tomorrow. Thanks for bringing this to our attention. Stay tuned.

@chrislea
Copy link
Contributor

Okay @danlange, this was a tricky one. Fortunately one of the core Node committers was able to work abound the glibc bug with a patch to V8 that should propagate out into future versions of Node.

I've made a new one-off build of 8.3.0 just for EL6 with the fix that should work. Please just try:

yum -y update

and it should pick up the new file (it's here if for some reason it doesn't... you may need to clean your yum cache or something).

If it's working (or if it's not) please let us know here on the issue. Thanks.

@danlange
Copy link
Author

I updated and it is working now.

kisg pushed a commit to paul99/v8mips that referenced this issue Aug 17, 2017
glibc before 2.17 has a bug that makes it impossible to execute binaries
that have single-byte thread-local variables:

    % node --version
    node: error while loading shared libraries: cannot allocate memory
    in static TLS block

Work around that by making the one instance in the V8 code base an int.

See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
See: nodesource/distributions#513
See: nodejs/build#809
Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
Reviewed-on: https://chromium-review.googlesource.com/612351
Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-by: Eric Holk <eholk@chromium.org>
Cr-Commit-Position: refs/heads/master@{#47400}
MylesBorins pushed a commit to MylesBorins/node that referenced this issue Aug 18, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{nodejs#47400}

Refs: nodejs/build#809
jasnell pushed a commit to nodejs/node that referenced this issue Aug 24, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#47400}

PR-URL: #14913
Ref: nodejs/build#809
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
addaleax pushed a commit to addaleax/ayo that referenced this issue Aug 25, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#47400}

PR-URL: nodejs/node#14913
Ref: nodejs/build#809
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
targos pushed a commit to targos/node that referenced this issue Aug 28, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{nodejs#47400}

PR-URL: nodejs#14913
Ref: nodejs/build#809
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
addaleax pushed a commit to ayojs/ayo that referenced this issue Aug 28, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#47400}

PR-URL: nodejs/node#14913
Ref: nodejs/build#809
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
MylesBorins pushed a commit to nodejs/node that referenced this issue Sep 10, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#47400}

PR-URL: #14913
Ref: nodejs/build#809
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
MylesBorins pushed a commit to nodejs/node that referenced this issue Sep 12, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#47400}

PR-URL: #14913
Ref: nodejs/build#809
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
targos pushed a commit to targos/node that referenced this issue Sep 12, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{nodejs#47400}

PR-URL: nodejs#14913
Ref: nodejs/build#809
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
addaleax pushed a commit to nodejs/node that referenced this issue Sep 13, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#47400}

PR-URL: #14913
Ref: nodejs/build#809
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
addaleax pushed a commit to addaleax/node that referenced this issue Sep 13, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{nodejs#47400}

PR-URL: nodejs#14913
Ref: nodejs/build#809
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
targos pushed a commit to targos/node that referenced this issue Sep 14, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{nodejs#47400}

PR-URL: nodejs#14913
Ref: nodejs/build#809
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
targos pushed a commit to targos/node that referenced this issue Sep 21, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{nodejs#47400}

PR-URL: nodejs#14913
Ref: nodejs/build#809
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
MylesBorins pushed a commit to nodejs/node that referenced this issue Sep 28, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#47400}

Backport-PR-URL: #15393
PR-URL: #14913
Ref: nodejs/build#809
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
MylesBorins pushed a commit to nodejs/node that referenced this issue Sep 29, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#47400}

Backport-PR-URL: #15393
PR-URL: #14913
Ref: nodejs/build#809
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
MylesBorins pushed a commit to nodejs/node that referenced this issue Oct 3, 2017
Original commit message:

    Work around glibc thread-local storage bug

    glibc before 2.17 has a bug that makes it impossible to execute
    binaries that have single-byte thread-local variables:

        % node --version
        node: error while loading shared libraries: cannot allocate
        memory in static TLS block

    Work around that by making the one instance in the V8 code base
    an int.

    See: https://sourceware.org/bugzilla/show_bug.cgi?id=14898
    See: nodesource/distributions#513
    See: nodejs/build#809
    Change-Id: Iefd8009100cd93e26cf8dc5dc03f2d622b423385
    Reviewed-on: https://chromium-review.googlesource.com/612351
    Commit-Queue: Ben Noordhuis <info@bnoordhuis.nl>
    Reviewed-by: Eric Holk <eholk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#47400}

Backport-PR-URL: #15393
PR-URL: #14913
Ref: nodejs/build#809
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants