How to Enable ZRAM on Linux Systems for Better Memory Optimization
By
type0
If you only eat one bagel today, this is the bagel.
Summary
The article discusses enabling ZRAM (compressed RAM) on Linux systems to optimize memory usage and potentially save money on hardware upgrades. The author shares personal experience with Firefox crashes due to memory issues on a 16GB RAM system and explains how ZRAM can help by compressing memory pages in RAM rather than swapping to disk. The article serves as a reminder/tutorial for Linux users to configure ZRAM for better performance without purchasing additional RAM.
Key quotes
· 4 pulledWith the price of RAM getting out of control, it might be a good idea to remind Linux users to enable ZRAM so they can get better performance without upgrading memory, or save money on their next single board computer by selecting a board with the right amount of memory.
In recent days, I found Firefox crashing often due to running out of memory on my system with 16GB of RAM, and the Linux 7.0 release reminded me about ZRAM, since there were some related changes.
ZRAM is a Linux kernel feature that provides a compressed block device in RAM, which can be used as swap space. Instead of swapping memory pages to disk, they are compressed and stored in RAM, which is much faster than disk I/O.
The main benefit is that you can effectively increase the amount of available memory without adding more physical RAM, which is especially useful on systems with limited memory or when RAM prices are high.
You might also wanna read
systemd-manager-tui: A Terminal-Based Tool for Managing systemd Services
A TUI (Terminal User Interface) application called systemd-manager-tui, available on GitHub, allows users to manage systemd services via D-B
GTFOBins: A Curated List of Unix Binaries for Bypassing Local Security Restrictions
GTFOBins is a curated list of Unix-like binaries that can be exploited to bypass local security restrictions in misconfigured systems. The l
gtfobins.org·1mo ago
Cells for NetBSD: Kernel-Enforced Isolation System with Practical Operations
Cells for NetBSD is a kernel-enforced isolation system for the NetBSD operating system that provides jail-like containerization with practic
Understanding Linux Compressed Swap: zswap vs zram Technical Comparison and Recommendations
This article provides expert guidance on Linux memory management technologies zswap and zram, explaining their fundamental differences and o
Direct Disk Installation: Creating a Linux Distro That Installs via curl > /dev/sda
The article describes a technical experiment where the author created a Linux distribution that can be installed by directly piping a disk i
Logfile Navigator (lnav): Advanced Log File Viewer with Performance Advantages
The Logfile Navigator (lnav) is an advanced log file viewer designed for small-scale use that can outperform standard terminal tools when pr
