| 26 Nov 2022 |
magic_rb |
is there any way to deal with hydra eating upwards of 8GB of memory when evaluating my flake? I would like it to build all my systems but 8GB of memory is way too much for that, I think the issue Nix not really GCing that well if I try to `nix eval` all the systems at once, one by one when they're perfectly fine though… | 19:10:42 |
@linus:schreibt.jetzt | magic_rb: add some swap. Most of that memory isn't actually being used most of the time so it can be swapped out. | 19:15:40 |
magic_rb |
won't help in my case as cgroup still count it towards the overall usage and it'll get killed anyway, if i increase the limit for the whole container i would then run the risk of OOMing my system due to a really memory intensive build that does actually need the ram actively | 19:16:55 |
magic_rb |
But it is true that i do not actually have any swap currently, i should probably get some but it won't help in this case | 19:18:26 |
| @ahsmha:matrix.org changed their display name from rh to ahmed. | 19:19:32 |
magic_rb |
I could get an SLC ssd for both L2 cache and another one for swap but wow are they expensive | 19:23:27 |
@linus:schreibt.jetzt | In reply to @magic_rb:matrix.redalder.org
won't help in my case as cgroup still count it towards the overall usage and it'll get killed anyway, if i increase the limit for the whole container i would then run the risk of OOMing my system due to a really memory intensive build that does actually need the ram actively Limit the RAM for nix-daemon where the builds happen, but not for hydra-evaluator? | 19:24:18 |
@linus:schreibt.jetzt | In reply to @magic_rb:matrix.redalder.org
But it is true that i do not actually have any swap currently, i should probably get some but it won't help in this case zramSwap is free :D | 19:24:40 |
magic_rb |
I would have to move the nix-deamon out of the container into a separate container in that case | 19:24:45 |
@linus:schreibt.jetzt | Ooh you run it all in a container? | 19:25:05 |
magic_rb |
which may be a reasonable thing to do, but itll increase complexity a lot | 19:25:12 |
magic_rb |
yeah i do | 19:25:14 |
@linus:schreibt.jetzt | What about limiting nix-daemon within the container? | 19:25:30 |
magic_rb |
nomad would still have issues with the ram amounts, i would have to keep memory down to 4GB then increase memory max above 8 to 12 which is a really bad idea because nomad schedules based on memory not memory max | 19:26:30 |
magic_rb |
i may just have to split it up, nix-daemon, hydra-http and hydra-evaluator | 19:26:52 |
@linus:schreibt.jetzt | Oh yeah if you're running in nomad that sounds sensibel | 19:27:08 |
@linus:schreibt.jetzt | * Oh yeah if you're running in nomad that sounds sensible | 19:27:14 |
magic_rb |
i dont have space for swap anywhere currently unfortunately, when i clean up the 1TB skyhawks i can put it there but i need to move data of them onto the 4tb wd reds | 19:28:19 |
magic_rb |
i would still like to somehow make hydra not eval everything at once, but i would have to know a lot more c++ to do that | 19:29:08 |
@linus:schreibt.jetzt | If you're on nixos, I'd suggest trying zramSwap.enable = true in any case | 19:29:27 |
@linus:schreibt.jetzt | In reply to @magic_rb:matrix.redalder.org
i would still like to somehow make hydra not eval everything at once, but i would have to know a lot more c++ to do that Or make separate jobsets :p | 19:29:39 |
magic_rb |
for flakes? how would that work | 19:29:51 |
magic_rb |
In reply to
Linux Hackerman
If you're on nixos, I'd suggest trying zramSwap.enable = true in any case
yep, ill do that in any case, seems like a reasonable idea | 19:30:05 |
@linus:schreibt.jetzt | Oh | 19:30:06 |
@linus:schreibt.jetzt | With different subpaths I guess | 19:30:12 |
magic_rb |
well when i push a change hydra will start evaluating everything at once anyway, it has no notion of "hey maybe evaluations can choke the system too" | 19:30:56 |
@linus:schreibt.jetzt | Afaik the evaluator will only evaluate one jobset at a time | 19:31:33 |
magic_rb |
ah ok so that may be a path forward | 19:31:45 |
| @omlet:matrix.org left the room. | 19:33:52 |
@linus:schreibt.jetzt | In reply to @magic_rb:matrix.redalder.org
ah ok so that may be a path forward update: I was wrong, by default it does up to 4 evals at a time. But you can configure that using the max_concurrent_evals option. | 19:59:48 |