Re: Swap partition priority
- Reply: Andrea Venturoli : "Re: Swap partition priority"
- In reply to: Andrea Venturoli : "Re: Swap partition priority"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 18 Aug 2026 16:03:13 UTC
If there’s no problem with adding an optional parameter to the struct that swapon(2) passes to the kernel, then all it should need would be to have a priority loop in front of the current round-robin allocation code, IMO. We’d have to be really really careful about testing it under all sorts of conditions because blocking is disallowed in some parts of this code path and it’s really easy with block I/O to accidentally cause a block. -Joshua > On Aug 18, 2026, at 10:58 AM, Andrea Venturoli <ml@netfence.it> wrote: > > On 8/18/26 17:21, Joshua Armstrong wrote: >> Short answer, yes - interleaving is hardcoded and the swapon(2) syscall > > Thanks to everyone who answered. > > Right now I'm trying to address the problem at its root, i.e. convincing poudriere not to fill all my swap. > > Failing that, using gconcat seems like a good solution (although a bit complicated by the concurrent use of geli and gmirror), so I might go this way. > > I'm wondering, though, would it be hard to modify the standard behavior (adding a sysctl, I guess)? > I'm not sure I'm up to the task, but I could give it a try as an exercise. > > bye & Thanks > av.