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

[Feature request] Allow limiting hardware resources #16158

Open
arenekosreal opened this issue May 19, 2024 · 0 comments
Open

[Feature request] Allow limiting hardware resources #16158

arenekosreal opened this issue May 19, 2024 · 0 comments
Labels
Backend Things regarding the OBS backend

Comments

@arenekosreal
Copy link

Is your feature request related to a problem? Please describe.

Building firefox is always a challenge to computers which are not fast enough. I am building a customized firefox for Arch Linux with OBS at here. But it will eats all the memory at linking stage finally and throw an OOM error. Checking its build log shows that the building system tries to use 50GB memory and there is only 44GB at maximum available here.

It seems that I can limit processor cores by using lower memory size, but it is not enough. For example, I have tried to use 8GB memory and there are still 4 cpu cores, while I want to use 2 cores or less only.

Firefox's build system provides an option called MOZ_PARALLEL_BUILD to limit build number in parallel but it does not seem to limit linker processes number, which results that too many cpu cores are used when linking and the memory space is not enough to finish linking.

Describe the solution you'd like
Adding more memory is always the simplest solution, but OBS's workers seem to only have 40GB physical memory and 4GB swap at most. So the second solution is here: using less cpu cores. But I tried setting jobs and MOZ_PARALLEL_BUILD, both are not effective enough. They did limit build number but there is no limit to linker number.

So my last thought is allowing us limiting cpu cores, but processors in _constraints seems to be a minimum value, not a maximum value.

Describe alternatives you've considered
Maybe allowing us adding more swap can be another solution? But I completely do not know how to increase swap partition size, it seems the size of swap partition is always 4GB.

Additional context
N/A

@hennevogel hennevogel added the Backend Things regarding the OBS backend label May 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Backend Things regarding the OBS backend
Projects
None yet
Development

No branches or pull requests

2 participants