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
generic: disable kernel SWAP support #3189
Conversation
We don't employ swap using zram anymore with Gluon. Thus, we can disable SWAP in the kernel. Signed-off-by: David Bauer <mail@david-bauer.net>
Wouldn't it make more sense to employ it for certain devices instead? |
@Djfe WHere should we swap to? |
why, RAM of course. zRAM to be exact and it prevented tiny devices in the past (32mbit RAM) from OOMing early. imo it probably makes sense for many targets. Obviously this should be tested but I don't think that this would reduce/harm performance in any way. I'm happy to provide before and after for targets. if you are on board with such a change. I would not set zRAM to 50% like it was done here for a nanostation xw. 29mb might be a bit much on 64MiB devices/more than necessary. maybe relevant if we keep zRAM small it could be of use to evaluate zst compared to LZ4 cpu usage should be negligible if this stores mostly paged which are barely used. if zRAM takes up too much RAM, then this won't be the case because Linux has to swap constantly. thoughts? |
You burn CPU time doing so. You can only swap out userspace pages which are not the big concern for us.
We have no issue in the present tense, so why try to add complexity on a non-issue today?
See the last point, what do you expect to gain except for a higher "Memory Available" counter?
The buffers for wireless clients exist in kernelspace, there is just a miniscule space required within hostapd. Last time we've used it as a last dirch effort and it did not make the boards in question usable again. We do not face any issue today, so why should we hop onto the bandwagon we used in the past for a short time when there is no need to today? |
the userspace part is something I actually didn't know about. Thanks for elaborating why it's not that easy and why OpenWrt doesn't profit from this as much.
mostly: Support for more concurrent WiFi clients by more RAM being available for that purpose. |
We don't employ swap using zram anymore with Gluon. Thus, we can disable SWAP in the kernel. Signed-off-by: David Bauer <mail@david-bauer.net>
We don't employ swap using zram anymore with Gluon. Thus, we can disable SWAP in the kernel.