Skip to content
HomeVideosBooksBlogs
AllTop postsTopics
Podcasts
HistoryListsWatch laterLiked videosFollowing

The videos, books, blogs and podcasts Hacker News keeps recommending, all in one place.

VideosBooksBlogsPodcastsAboutPrivacySettings

Data from Hacker News, HackerTube, HackerBooks, HackerBlogs and Open Library. Credits · Not affiliated with Y Combinator.

HomeVideosBooksBlogsPodcasts
Ctrl K
    C

    Chris Down

    chrisdown.name · Personal blog · on HN since 2018

    Chris Down is a Linux kernel engineer who writes about memory management, swap, cgroups, and debugging operating system behavior.

    Visit blogRSSHN submissions
    Systems & PerformanceOpen Source & Linux
    What HN says

    Commenters cite his swap post as the reference on the topic, and also link his piece on the mysterious number 1195725856.

    Stats for nerds
    43HN people shared it
    22linked in comments
    1.3Kstory points
    Aug 2026last shared
    2019people per year2026

    Top posts on HN

    1. 1
      In defense of swap: common misconceptions (2018)
      27 people · 611 points · first shared 2018 · 165 comments on HN
    2. 2
      1195725856 and other mysterious numbers
      2 people · 512 points · first shared 2020 · 78 comments on HN
    3. 3
      Tmpfs inode corruption: introducing inode64
      2 people · 162 points · first shared 2021 · 27 comments on HN
    4. 4
      Preventing outages with pkill's new –require-handler flag
      3 people · 9 points · first shared 2025 · Discussion on HN
    5. 5
      The curious case of stalled squashfs reads (2018)
      3 people · 6 points · first shared 2018 · Discussion on HN
    6. 6
      Creating controllable D state (uninterruptible sleep) processes
      2 people · 6 points · first shared 2024 · Discussion on HN
    7. 7
      Debunking Zswap and Zram Myths
      6 people · 3 points · first shared 2026 · Discussion on HN
    8. 8
      1195725856 other mysterious numbers
      2 people · first shared 2020
    9. 9
      Linux memory management at scale
      2 people · first shared 2023

    What HN people wrote when they linked it

    • LargoLasskhyfvJul 2025

      Depends on your usage patterns. On 8GB I gave it (ZRAM) between 512MB to 768MB RAM, and later on just using whatever values for the relevant sysctls AntiX was using(or their scripts created dynamically during setup/startup) at the time. It isn't just vm.swappiness, there are others, and they changed, or got removed, and replaced by others, over the years. And all of them sort of interwoven, influencing each other via what's happening in vm-subsystem. Can have bad feedback loops if you do it wrong, and be counterproductive. So you have to experiment, and measure with different settings, for what you're running.

      Where measure can be anything from htop/atop over https://github.com/cdown/psi-notify , to https://github.com/noiseonwires/memory-pressure and so on.

      To understand what these sysctls are about, how they are related to each other, and to ZRAM, I'd recommend reading, or at least skimming https://chrisdown.name/2018/01/02/in-defence-of-swap.html , https://chrisdown.name/2019/07/18/linux-memory-management-at-scale.html , https://linuxblog.io/linux-performance-almost-always-add-swap-space , https://linuxblog.io/linux-performance-almost-always-add-swap-part2-zram , https://linuxblog.io/linux-performance-no-swap-space , https://linuxblog.io/running-out-of-ram-linux-add-zram , https://github.com/ValveSoftware/SteamOS/issues/899 , https://lonesysadmin.net/2013/12/22/better-linux-disk-caching-performance-vm-dirty_ratio , https://github.com/CachyOS/CachyOS-Settings/pull/19 ,…

    • offlinemarkOct 2020

      You're right, I probably should have said "some operating systems". I was generalizing based on my own education, which used Linux. I believe Windows does not do this either, but I'm not sure how many OS 101 classes teach Windows kernel :)

      > The advantage is that you find out if you don't have enough memory when you make the system call to request it, not by having the program killed.

      I wonder how much of an advantage this is. Memory availability is constantly in flux, and Linux at least, goes to great lengths to reclaim memory before invoking the OOM killer, which is a last resort. What if memory frees up immediately after the application gets the error return, but before the app touches it?

      I'd trust the kernel more to manage this than applications themselves, because the kernel can make much better decisions on how to juggle things (evicting caches and whatnot). Plus, we all know how well we all test our error handling paths :)

      > (It may be time for paging out to disk to go away. It's a huge performance hit. Mobile doesn't do it. And RAM is so cheap.)

      In case anyone is interested in learning more, this is an excellent article discussing the nuances of paging to disk: https://chrisdown.name/2018/01/02/in-defence-of-swap.html

      Re: mobile, does Android disable paging file mappings to disk, which happens even if swap is disabled? (Swap only affects anonymous mappings).

    • cromkaMay 2026

      >You have a buggy program.

      As in memory leak? No.

      > Zswap has been available for quite a while.

      Zsawp is not Zram, which is a distant relative of the macOS on-the-fly compression I was talking about. Zram is buggy and still advised against regular use (https://www.reddit.com/r/AsahiLinux/comments/1i3mdrw/comment/m7plkkx, https://chrisdown.name/2026/03/24/zswap-vs-zram-when-to-use-what.html). Zsawp itself is enabled by default in Asahi.

      Zram and Zsawp are mutually exclusive on Linux. On macOS, both concepts coexist – except macOS is able to compress individual memory pages (https://news.ycombinator.com/item?id=38300432) on the fly. Zram is a compressed RAM block device with a hard capacity limit.

      There is really no comparison here at this point. macOS is vastly superior in that regard.

    • znpyMar 2021

      I have some questions.

      I started reading about systemd-oomd, then followed the link to its manpage (at https://www.man7.org/linux/man-pages/man8/systemd-oomd.8.html) then followed a link from there to this page: "In defence of swap: common misconceptions" at https://chrisdown.name/2018/01/02/in-defence-of-swap.html).

      The first line of the tl;dr is: "Having swap is a reasonably important part of a well functioning system. Without it, sane memory management becomes harder to achieve."

      Now, afaik linux as a kernel is pretty much designed to have swap memory and really not meant to be ran without it. Except disabling swap is required to run kubernetes, so much so that the kubelet will plain refuse to start if it detects swap memory enabled.

      Why?

    • lholdenJun 2024

      Most people think of swap as "emergency memory in case I run out of memory" and while it's true that it can get used in this way, it usually serves a much more critical purpose in your OS's ability to reason about and use memory.

      For a good article on why this is true for Linux: https://chrisdown.name/2018/01/02/in-defence-of-swap.html

      I believe that most operating systems are going to make use of memory in a similar manner.

      With that said, I'll turn off swap on devices that have unreliable storage. (Anything using an SD card)

    • MrDrMcCoyOct 2024

      Fair points overall. I think KSM is still useful and worth the overhead for things like sprawling browser tabs and densely deployed microservices.

      I disagree that swap is only (or even primarily) for situations where you're running out of memory, though. It is useful for reducing I/O contention and improving memory utilization by replacing underutilized pages with file cache when it makes sense to do so. See this for more details: https://chrisdown.name/2018/01/02/in-defence-of-swap.html

    Related

    Brendan Greggbrendangregg.com450 people

    An Unbelievable Demo

    Brendan Gregg
    Personal · last shared 2026
    Chris Siebenmannutcc.utoronto.ca/~cks388 people

    Go is Google's language, not ours

    Chris Siebenmann
    Personal · last shared 2026
    Matthew Garrettmjg59.dreamwidth.org306 people

    I stayed in a hotel with Android lightswitches and it was as bad as you'd think

    Matthew Garrett
    Personal · last shared 2026
    ldpreloadldpreload.com34 people

    Finding a kernel regression in half an hour with git bisect run (2018)

    ldpreload
    Personal · last shared 2026
    Rachel Krollrachelbythebay.com493 people

    fork() can fail

    Rachel Kroll
    Personal · last shared 2026
    Greg Kroah-Hartmankroah.com84 people

    Meltdown and Spectre Linux kernel status

    Greg Kroah-Hartman
    Personal · last shared 2026
    Chris Wellonsnullprogram.com295 people

    Why Aren't There C Conferences?

    Chris Wellons
    Personal · last shared 2026
    Russ Coxresearch.swtch.com554 people

    Timeline of the xz open source attack

    Russ Cox
    Personal · last shared 2026