-
Notifications
You must be signed in to change notification settings - Fork 17.5k
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
/lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.32' not found #58550
Comments
What's the output of |
Looking at the evcc issue, it's your nightly ubuntu builds. As we no longer ship precompiled archives for the standard library,
Closing as working as intended. |
I'm surprised to find this:
since the goreleaser config nowhere mentions to enable cgo.
I have unfortunately no idea what that means. I've re-read the go command section and am still puzzled what pre-compiled archives (for what?) have to do with the compiled binary.
And no idea what that means. |
I have |
|
Thank you both. I've re-run the golang-releaser build with 1.19 and it ends up with Happy to not get an answer, solved by forcing the build to |
see #57328 |
hi, there |
AFAIU, for CGO_ENABLED=1, you'll need to use a glibc version during compile that matches (or is lower) than the one on your target runtime system. |
Host OS is ubuntu 22.04(I build the so here)
|
Explicitly disable CGO when building binaries. As of Go 1.20, we get dynamic executables when using standard libary packages that have both cgo and pure Go implementations. Fixes errors in which release binaries may fail because the correct version of libc can't be linked at runtime. See golang/go#58550
New Go version causes different linking behaviour in produced executable. On older Linux machines the following error occured: ``` dpcmder: /lib64/libc.so.6: version 'GLIBC_2.32' not found (required by dpcmder) dpcmder: /lib64/libc.so.6: version 'GLIBC_2.34' not found (required by dpcmder) ``` See: - golang/go#58550
When Golang is 1.20 and hosted OS in CI is Ubuntu-22.04, then we need to set CGO_ENABLED to zero, golang/go#58550, for the controller-gen binary
When Golang is 1.20 and hosted OS in CI is Ubuntu-22.04, then we need to set CGO_ENABLED to zero, golang/go#58550, for the controller-gen binary
* Disable cgo As part of the Go 1.20 release it seems like the default for `CGO_ENABLED` is no longer carried over from the tools. This leads to linking issues on systems that use different versions of glibc from what the base image uses. See golang/go#58550 for more details. This change should fix #16 * Slim down the final image. Use `scratch` as a base image since we're generating a static binary anyway. Also be more explicity about the platform and target OS during the build. * Refactor endpoint handling and reconcilliation. DRAFT With the release of Nomad 1.6 it's possible to get the network address of the allocation from Nomad. The change to enable this is only in the client library and does not require updating the Nomad server. The IP was sent back by older Nomad versions, it just wasn't available in the client. This enables refactoring the endpoint reconcilliation to make use of the IP address to identify the endpoint within Cilium. There is no longer a dependency on Consul for policies. Additional, endpoints are now labelled with the task group and task information as services can be created at those levels. * Tidy * Update the readme and add some basic tests. Remove unused flags from the readme and command line and refactor the code to allow for testing. * Slightly better logging of labels * Always update labels on reconcile. * Fixes and align with upstream Dockerfile * Missed one * Reduce Dockerfile diff further * Restore periodic reconcilliation of endpoints * Remove stray return
Fix by disabling CGO_ENABLED See: golang/go#58550
We were getting the following error on el7: $ ./versitygw -h ./versitygw: /lib64/libc.so.6: version `GLIBC_2.32' not found (required by ./versitygw) ./versitygw: /lib64/libc.so.6: version `GLIBC_2.34' not found (required by ./versitygw) The temporary fix is to disable cgo in the builds per this issue: golang/go#58550 We will need to visit per distro builds once we need to re-enable cgo.
Try to use bullseye official docker image like golang:1.21-bullseye |
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
yes
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
After upgrading our build environment and
go.mod
requirement to Go 1.20, users started to see this error message on Ubuntu: evcc-io/evcc#6263. The application does not use CGO.What did you expect to see?
No error. Same build was working fine with Go ^1.18.
What did you see instead?
GLIBC version required. This output of
go version -m
should be similar to what the build produces for arm:The text was updated successfully, but these errors were encountered: