The one-liner:

dd if=/dev/zero bs=1G count=10 | gzip -c > 10GB.gz

This is brilliant.

  • 4am@lemm.ee
    link
    fedilink
    English
    arrow-up
    2
    ·
    9 days ago

    How long would it take to be considered an inactive memory page? Does OOM conditions immediately trigger compression, or would the process die first?

    • DreamButt@lemmy.world
      link
      fedilink
      English
      arrow-up
      1
      ·
      9 days ago

      So I’m not an expert but my understanding is the flow is roughly:

      1. Available memory gets low
      2. Compress based on LRU rules
      3. Use swap
      4. OOM

      So it’s more meant to be preventative afaik