Hacker News

Top stories

Live mirror
30 storiesupdated just nowView source snapshot
  1. Linux support is coming to Snapdragon X2 Series(qualcomm.com)
    64comments
  2. Claude discovers a novel enzyme system with CRISPR-like repeats(anthropic.com)
    530comments
  3. Meta VR Glasses(meta.com)
    164comments
  4. VSCode's SSH Agent Is Bananas (2025)(fly.io)
    86comments
  5. ArXiv receives multiyear commitments to support it as an independent nonprofit(arxiv.org)
    8comments
  6. Mercury 2.5 LLM hits 770 tokens per second(artificialanalysis.ai)
    22comments
  7. The "Windows XP Box" (2003)(mini-itx.com)
    7comments
  8. Fixing the Portobello Police Station Clock(pointinthecloud.com)
    88comments
  9. FLAWED's Flaws and What This Means for Industry Research(suhacker.ai)
    discuss
  10. We just shipped support for the ugliest part of HTTP: Vary(cloudflare.com)
    9comments
  11. LensVLM: Compressing long context as images, expanding only relevant pages(huggingface.co)
    6comments
  12. The mystery animal on an ancient god's head(signoregalilei.com)
    16comments
  13. Italian parliament votes for return to nuclear energy(apnews.com)
    383comments
  14. Show HN: An open-source manufacturing ERP/MES/QMS(carbon.ms)
    1comments
  15. A brief history of Windows scroll bar shortcuts(devblogs.microsoft.com/oldnewthing)
    50comments
  16. Making Tailscale Faster(tailscale.com)
    32comments
  17. Augustofaces: Pareidolia Fine Art(augusto.at)
    1comments
  18. Gemini 3.8 text-to-speech(blog.google)
    124comments
  19. Radicle: Disclosure of Vulnerability in the Network Protocol(radicle.dev)
    48comments
  20. Tokens too cheap to meter(jyn.dev)
    179comments
  21. The Curious Power of Punctuation(newyorker.com)
    3comments
  22. Swap, ZRAM, Zswap and Hibernate on NixOS(matthewbrunelle.com)
    7comments
  23. A refined phylochronology of the second plague pandemic in Western Eurasia(pnas.org)
    discuss
  24. I don't want the details(michaelheap.com)
    197comments
  25. Z80 REPL (2018)(abagames.github.io)
    18comments
  26. Claude Code reads AGENTS.md only when telemetry is on [fixed](szypowi.cz)
    257comments
  27. Once Claude can measure something, it can make it faster(claude.dev)
    105comments
  28. Show HN: I built a post-mortem debugger for native Windows x64/x86 crashes(forensicdbg.com)
    5comments
  29. QuestDB (YC S20) Is Hiring a Sales Engineer(questdb.com)
    discuss
  30. 28% of job postings on company career sites have been open over 90 days(unlisted.careers)
    298comments

Swap, ZRAM, Zswap and Hibernate on NixOS

37 pointsby 7h agoblog.matthewbrunelle.com
7 comments
5h agoHN ↗

Thanks for this. So weird though - I literally spent the better part of the weekend reading and learning all about the differences between zram and zswap and ultimately deciding to switch out my previous zram config for zswap on my NixOS system! So seeing this pop up on my hackernews feed felt a bit spooky…

27m agoHN ↗

same, I literally just set up my Framework 13 Pro today and was looking for the current recommended zswap settings... looks like a bunch of us are in this thread

4h agoHN ↗

Right, you are good to do swap files on btrfs since linux 5.0 or so as long as you follow some rules. Disko thankfully covers all those details for you, but I shouldn't have skipped over that in the piece. I'll make an update when I get a chance.

3h agoHN ↗

Swap files work, but I wouldn't quite say "you are good to do swap files on btrfs" because the official documentation (the page I linked earlier) says

filesystem - must be only single device

This means swapfiles will have an amplified impact, much larger than the size of the swapfile itself.

Users should be aware of the impact when using swapfiles alongside other data. This is especially discouraged for root filesystem.

If a swap file is the only thing that will work with your setup, then it's fine to use one, but if you're at all able to use a swap partition, then that's a far better choice. (Swap files are fine on ext4 and xfs; it's only COW filesystems like btrfs and zfs where they should be avoided.)

2h agoHN ↗

I've had good luck using zswap+zstd on Ubuntu 26.04. I have a Framework 13 (AMD) with 16GB, and have a 16GB swap file configured (ext4 root partition).

I had planned to upgrade the machine to 32GB of RAM but I don't really feel it's necessary at this point. Which is obviously great given the current RAM costs!

1h agoHN ↗

I also just recently enabled zswap on my NixOS setup, it's been working fine. I have 32GB of RAM and 64GB of swap, so I really don't need it, but it hasn't hurt.

I was expecting some problems with my switch to NixOS back in June, but it's been just superb. Even things like building deb packages for my Ubuntu 26.04 machines at work have not been a problem at all.

I had dabbled with NixOS for a year or two before making the switch and had some familiarity with the nixlang and various concepts (SOPS, age, flakes). But, what really smoothed out the switch was using Claude Code to develop the NixOS configs. Everything is easy to do that way, and any issues are easy to back out.