Skip to content

Comments

[21.11] docker: 2.10.9 -> 20.10.14 (for glibc 2.34 compatiblity!)#170900

Merged
amaxine merged 4 commits intoNixOS:release-21.11from
blitz:docker-glibc-issue
Apr 29, 2022
Merged

[21.11] docker: 2.10.9 -> 20.10.14 (for glibc 2.34 compatiblity!)#170900
amaxine merged 4 commits intoNixOS:release-21.11from
blitz:docker-glibc-issue

Conversation

@blitz
Copy link
Contributor

@blitz blitz commented Apr 29, 2022

Description of changes

We've hit an issue on our build servers that run Docker on NixOS 21.11. The problem is that the docker 2.10.9 is incompatible with glibc 2.34. The symptom is that applications using glibc 2.34 will die with EPERM from a clone3 system call.

Ironically, this prevents new Nix binaries from working. We noticed the issue when even nix-shell --version would just die with Permission denied.

Information on the issue can be found here:

I've backported from master:

This brings docker to 2.10.14. According to their release notes, this also fixes two security issues:

Will mark as ready for review when the tests completed.

Things done
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 22.05 Release Notes (or backporting 21.11 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
    • (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes
  • Fits CONTRIBUTING.md.

@blitz blitz force-pushed the docker-glibc-issue branch from 13903cf to 4f66697 Compare April 29, 2022 11:57
@ofborg ofborg bot added 10.rebuild-darwin: 11-100 This PR causes between 11 and 100 packages to rebuild on Darwin. 10.rebuild-linux: 11-100 This PR causes between 11 and 100 packages to rebuild on Linux. labels Apr 29, 2022
@blitz blitz added the 6.topic: docker tools Open-source software for deploying and running of containerized applications label Apr 29, 2022
@blitz
Copy link
Contributor Author

blitz commented Apr 29, 2022

nix-build -A nixosTests.docker is happy. I'm currently running nixpkgs-review.

@blitz blitz marked this pull request as ready for review April 29, 2022 13:07
@blitz blitz requested a review from jonringer as a code owner April 29, 2022 13:07
@blitz
Copy link
Contributor Author

blitz commented Apr 29, 2022

nixpkgs-review is also happy:

❯ nixpkgs-review pr 170900
$ git -c fetch.prune=false fetch --no-tags --force https://github.com/NixOS/nixpkgs release-21.11:refs/nixpkgs-review/0 pull/170900/head:refs/nixpkgs-review/1
$ git worktree add /home/julian/.cache/nixpkgs-review/pr-170900-2/nixpkgs 837913deb2a4f21cfa8f2cb2f72ba5fae39b7e40
Preparing worktree (detached HEAD 837913deb2a4)
Updating files: 100% (29051/29051), done.
HEAD is now at 837913deb2a4 Merge pull request #170759 from NixOS/backport-169937-to-release-21.11
$ git merge --no-commit --no-ff 4f66697ff43753b55f68311c0839b6d27c133e62
Automatic merge went well; stopped before committing as requested
$ nix --experimental-features nix-command build --no-link --keep-going --option build-use-sandbox relaxed -f /home/julian/.cache/nixpkgs-review/pr-170900-2/build.nix

Link to currently reviewing PR:
https://github.com/NixOS/nixpkgs/pull/170900

12 packages built:
charliecloud docker docker-client docker-gc fn-cli grype nvidia-docker out-of-tree pipework python38Packages.jupyter-repo2docker python39Packages.jupyter-repo2docker tarsum

$ nix-shell /home/julian/.cache/nixpkgs-review/pr-170900-2/shell.nix

@blitz blitz requested a review from tfc April 29, 2022 13:10
@amaxine amaxine merged commit 087fb90 into NixOS:release-21.11 Apr 29, 2022
@blitz blitz deleted the docker-glibc-issue branch April 29, 2022 17:51
flokli added a commit to wireapp/wire-server that referenced this pull request Jun 8, 2022
glibc 2.34 uses the clone3 syscall, which is not part of the seccomp
filters that moby ships on older versions.

While as a workaround you might be able to run containers with
`--privileged`, it's the better call to just run a more recent Docker
runtime.

References:
 - docker/buildx#772
 - moby/buildkit#2379
 - moby/moby#42836
 - NixOS/nixpkgs#170900
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.topic: docker tools Open-source software for deploying and running of containerized applications 10.rebuild-darwin: 11-100 This PR causes between 11 and 100 packages to rebuild on Darwin. 10.rebuild-linux: 11-100 This PR causes between 11 and 100 packages to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants