51
submitted 1 week ago by Blaze@lemmy.zip to c/linux@programming.dev
all 6 comments
sorted by: hot top controversial new old
[-] NateNate60@lemmy.world 8 points 1 week ago

For normal users with a sufficient amount of RAM, is there any real reason to even have a swap file or swap partition? Or why shouldn't they have one and set the swappiness to zero?

[-] vividspecter@lemm.ee 9 points 1 week ago

Depends on how you define "sufficient". Having some amount of swap can be helpful for efficient use of RAM, but I personally prefer to use zram for those cases.

A swap partition can also be useful if you use hibernation.

[-] BeigeAgenda@lemmy.ca 5 points 1 week ago* (last edited 1 week ago)

Hibernation needs a swap partition that's at least the same size as the memory.

Nvm: vivid.. already mentioned hibernation.

[-] autotldr@lemmings.world 2 points 1 week ago

This is the best summary I could come up with:


As part of the memory management changes expected to be merged for the upcoming Linux 6.11 cycle is allowing more fine-tuned control over the swappiness setting used to determine how aggressively pages are swapped out of physical system memory and into the on-disk swap space.

This effectively allows more finer-grained control over the swapiness behavior without overriding the global swappiness setting.

Dan Schatzberg of Meta explains in the patch adding swappiness= support to memory.reclaim: Allow proactive reclaimers to submit an additional swappiness=[val] argument to memory.reclaim.

However, proactive reclaim runs continuously and so its impact on SSD write endurance is more significant.

Therefore, it's desireable to have proactive reclaim reduce or stop swap-out before the threshold at which OOM killing occurs.

This has been in production for nearly two years and has addressed our needs to control proactive vs reactive reclaim behavior but is still not ideal for a number of reasons:


The original article contains 474 words, the summary contains 151 words. Saved 68%. I'm a bot and I'm open source!

this post was submitted on 06 Jul 2024
51 points (96.4% liked)

Linux

4436 readers
43 users here now

A community for everything relating to the linux operating system

Also check out !linux_memes@programming.dev

Original icon base courtesy of lewing@isc.tamu.edu and The GIMP

founded 1 year ago
MODERATORS