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

libstore+nix-build: add load-limit setting and use its value for NIX_LOAD_LIMIT en var #8105

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

aviallon
Copy link

Fixes #7091

Motivation & Context

As explained in issue #7091, NixOS/nixpkgs#192447 removed -l flag from all buildsystem invocations in nixpkgs, in order to improve Hydra efficiency.

However, this had several drawbacks, as this removed the ability to limit CPU load, causing OOM issues or extreme system loads in some bad scenarios (ninja buildsystem building something with -flto=auto enabled).

This patch aims to reintroduce the possibility to limit system load (together with PR NixOS/nixpkgs#192799), while still allowing Hydra to have full build efficiency.

Checklist for maintainers

Maintainers: tick if completed or explain if not relevant

  • agreed on idea
  • agreed on implementation strategy
  • tests, as appropriate
    • functional tests - tests/**.sh
    • unit tests - src/*/tests
    • integration tests - tests/nixos/*
  • documentation in the manual
  • code and comments are self-explanatory
  • commit message explains why the change was made
  • new feature or incompatible change: updated release notes

Priorities

Add 👍 to pull requests you find important.

…LOAD_LIMIT env var

Aimed at solving issue NixOS#7091

Signed-off-by: Antoine Viallon <[email protected]>
emilazy added a commit to emilazy/nix that referenced this pull request Jul 20, 2024
emilazy added a commit to emilazy/nix that referenced this pull request Jul 20, 2024
emilazy added a commit to emilazy/nix that referenced this pull request Jul 20, 2024
@emilazy
Copy link
Member

emilazy commented Jul 20, 2024

Linking #11143 here for any subscribers to this.

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

Successfully merging this pull request may close these issues.

Allow configuration of load limit for nix builds
2 participants