October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsPC HealthRecommendedCrashes, freezes, slowdowns? Check your PC nowSpot repairable issues before they interrupt work.Check PCOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
World desk5 min

How to Diagnose and Fix High RAM Use on a Linux Server

High Linux RAM use is not always a problem. Track available memory and pressure, identify the process or cgroup responsible, then apply a measured fix.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

High RAM use is not automatically a fault: Linux uses spare memory for caches. Check MemAvailable, swap activity, pressure and service impact over time before changing anything. Then identify whether the demand comes from an application, a cgroup limit, shared memory, or the kernel, and choose a fix that addresses that cause.

How do I fix high memory usage on a Linux server?

Use this sequence to avoid treating useful cache as a leak or disrupting an unrelated service:

As an Amazon Associate I earn from qualifying purchases.

  1. Confirm sustained pressure. Run free -h more than once or review monitoring history. Compare available memory, swap use, and service responsiveness rather than relying on the headline “used” figure.
  2. Break down the memory. Inspect /proc/meminfo for MemAvailable, Cached, Shmem, AnonPages, Slab, SReclaimable, SUnreclaim, Dirty, Writeback, and swap fields.
  3. Locate the consumer. Use top, htop, or ps to find processes that merit investigation, then check the service or container’s accounting and limits.
  4. Match the remedy to the evidence. Investigate growing application memory, peak workload, cgroup limits, shared memory, tmpfs, or kernel allocations as appropriate. Avoid killing processes or clearing caches as a first response.
  5. Validate the change. Continue watching available memory, swap and reclaim pressure, service latency, and OOM events.

The kernel defines MemAvailable as an estimate of memory available for starting applications without swapping. It includes reclaimable memory while accounting for cache the system needs and slab that may not be reclaimable (Linux kernel /proc documentation). No single percentage or threshold is safe for every workload; interpret the trend alongside reclaimability, swap configuration, and service latency requirements.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Why is Linux using so much RAM?

Linux memory totals combine categories with different uses and reclaim behavior. File cache can make a “used” number look high while memory remains available for applications. Shared memory and tmpfs, anonymous memory used by processes, and kernel slab are different categories and should not be treated as interchangeable.

#1 Best Overall
128GB 8X16GB DDR5 6400MHz PC5-51200 1Rx8 1.1V CL52 288-PIN ECC Registered RDIMM NEMIX RAM Server Memory KIT Compatible with Supermicro H14SSL-NT Motherboard
  • EXACT-MATCH UPGRADE — 128GB (8X16GB) kit DDR5-6400 (PC5-51200), 1Rx8 Registered ECC, 1.1V, CL52, 288-pin. The precise rank, voltage, and timing your server's memory controller expects, so it's recognized at full capacity and runs at its rated speed.
  • VERIFIED FITMENT — Compatible with the Supermicro H14SSL-NT motherboard. The 288-pin Registered (RDIMM) form factor this board requires — not a UDIMM or SODIMM. Spec-matched to your board's memory-population rules.
  • ENTERPRISE STABILITY — Registered (buffered) architecture offloads the memory controller so every slot runs fully populated at full capacity, while ECC catches and corrects single-bit errors on the fly — stopping silent data corruption and unplanned reboots before they reach production.
  • CHECK YOUR CONFIG — Server and motherboard memory support varies by model. Consult your system or motherboard manual for supported capacities, approved DIMM population order, and installation steps before purchase.
  • LIFETIME SUPPORT — Backed by a lifetime replacement warranty and free US-based technical support.

In /proc/meminfo, Cached and Shmem help show cache and shared-memory use; AnonPages reflects anonymous pages; and Slab is split into reclaimable (SReclaimable) and unreclaimable (SUnreclaim) parts. Dirty and Writeback describe pages awaiting or undergoing writeback. The kernel’s /proc reference explains these fields.

A single snapshot may miss short-lived peaks. Compare readings over time and look for swap activity, reclaim or pressure signals, and OOM messages in system logs. A growing process is only one possible explanation: if process totals do not account for host use, investigate slab, page tables, shared memory, or tmpfs rather than terminating an unrelated large process.

How do I find which process or service is using memory?

Start with processes, then inspect the service tree

Use a process view to find candidates, but do not assume the largest process explains all memory. Services may run as multiple processes, and a container or unit can include descendants not obvious from a single process listing.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

On cgroup v2 systems, find the relevant service or container cgroup and inspect its memory.current, memory.stat, memory.events, and swap counters where available. memory.current includes the cgroup’s descendants; compare the service tree, not just its main process. Repeated events at a boundary can indicate reclaim or limit pressure. See the kernel cgroup v2 documentation.

Rank #2
A-Tech 64GB DDR5 6400MHz PC5-51200 ECC RDIMM 2Rx4 (EC8 10x4) Dual Rank 1.1V ECC Registered DIMM 288-Pin Server RAM Memory Upgrade Module (A-Tech Enterprise Series)
  • A-Tech RAM Memory compatible for select DDR5 Server systems; (WILL NOT WORK with Desktop Computers/PCs or Laptop Computers)
  • Single 64GB RAM Module; DDR5 DIMM 288 Pin; Speeds up to 6400MHz PC5-51200 (PC5-6400B)
  • ECC Registered RDIMM; 2Rx4 (EC8, 10x4) - Dual Rank x4; JEDEC DDR5 standard 1.1V
  • Improves system performance, workload capacity, and reduces bottlenecks by increasing memory (RAM) resources
  • Note: EC8 (10x4) ECC Registered modules cannot be mixed with EC4 (9x4) ECC Registered modules or with different ECC types such as ECC Unbuffered, ECC Load Reduced or Non-ECC Unbuffered; (Memory compatibility can vary among different system models and their installed components; please verify compatibility and follow memory channel guidelines to ensure maximum performance)

Check the host if process accounting does not add up

Use the /proc/meminfo categories to determine whether the unexplained demand is kernel slab, page tables, shared memory, or another category. The responsible subsystem or workload is a better place to investigate than an arbitrary process selected by its resident memory.

Could a cgroup limit be causing the problem?

Yes. A service can be constrained even when the host still has memory available. In cgroup v2, memory.high is a throttle and reclaim boundary: crossing it can cause heavy reclaim and slow the workload, but the boundary itself does not invoke the OOM killer. memory.max is the hard limit; if reclaim cannot bring use down, the cgroup OOM killer may act. Review the parent hierarchy and event counters before changing either setting (kernel cgroup v2 documentation).

Do not raise a limit based only on a single peak. First establish whether it reflects expected demand and whether the host has capacity to absorb the increase. A higher per-service limit can move the pressure to the host or another service.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Which fix matches the cause?

What the evidence suggests Next action Trade-off to consider
One application’s memory grows continually Investigate its heap or cache settings, possible leak, and workload pattern. Restart only as a mitigation when operationally safe, and preserve metrics and logs first. A restart can temporarily restore service but can erase useful evidence and does not resolve the underlying growth.
A short workload spike reaches a service limit Compare the limit with measured peak demand and actual host capacity before adjusting it. Raising the limit may transfer pressure to the host.
Several services together create sustained pressure Reduce concurrent load or add capacity based on measured demand and server hardware compatibility. Capacity changes depend on the specific server model, supported memory, and utilization trend.
Shared memory, tmpfs, or kernel slab accounts for unexplained use Investigate the workload or subsystem owning that category. Killing a large but unrelated process may disrupt service without freeing the memory source at issue.

After each change, observe available memory, swap and reclaim pressure, latency, and OOM events. Reclaim and swapping can keep a service running while increasing stalls; terminating a cgroup or process is more immediate and disruptive.

Rank #3
Samsung 64GB DDR5 4800MHz PC5-38400 ECC RDIMM 2Rx4 (EC8 10x4) Dual Rank 1.1V Registered DIMM 288-Pin Server RAM Memory M321R8GA0BB0-CQK
  • Samsung DDR5 Memory RAM | Part Number: M321R8GA0BB0-CQK
  • Single 64 GB Module; DDR5 DIMM 288-Pin; Speeds up to 4800 MHz, PC5-38400 (PC5-4800B)
  • ECC Registered RDIMM; 2Rx4 (EC8, 10x4); JEDEC DDR5 standard 1.1V
  • Compatible for select DDR5 Servers and Workstations; *Not Compatible with Desktop or Laptop Computers*
  • Note: EC8 (10x4) ECC Registered modules can not be mixed with EC4 (9x4) ECC Registered modules or with different ECC types such as ECC Unbuffered, ECC Load Reduced or Non-ECC Unbuffered; (Refer to your system's manual for memory seating and channel guidelines)
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Is Linux cache memory safe to clear?

Do not routinely run echo 3 > /proc/sys/vm/drop_caches to fix high memory use. The interface discards clean page cache, dentries, and inodes; it does not free dirty objects. The Linux man-pages describe it as useful for testing and reproducible filesystem benchmarks, and warn that losing caching benefits can degrade overall performance (proc_sys_vm(5), Linux man-pages).

Likewise, do not set vfs_cache_pressure=0 as a generic remedy. The kernel documentation says this stops reclaiming dentries and inodes under memory pressure and can contribute to OOM conditions (Linux kernel VM sysctl documentation).

Should I add swap or use systemd-oomd?

Swap

Swap can absorb some anonymous memory, but it does not fix ongoing application growth or guarantee acceptable latency. Choose its policy and capacity for the workload and operational requirements; there is no universal size recommendation.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

systemd-oomd

systemd-oomd is a userspace OOM manager that uses cgroups v2 and pressure stall information (PSI). Depending on configured conditions, it can select an eligible cgroup and send SIGKILL to its processes. Its manual requires the unified cgroup hierarchy and memory accounting for monitored units; check both prerequisites and which units are configured before relying on it (systemd-oomd.service).

What information should I collect if the issue continues?

When escalating, include the distribution and kernel version, cgroup mode, affected service or container, and relevant free and /proc/meminfo output. Add time-series readings, cgroup counters and limits, and OOM log entries so the problem can be tied to a time and workload. The cgroup v1 pressure interface is deprecated; prefer current pressure and accounting mechanisms supported by the system rather than relying on that legacy interface (kernel cgroup v1 memory documentation).

Quick Recap

Bestseller No. 2
A-Tech 64GB DDR5 6400MHz PC5-51200 ECC RDIMM 2Rx4 (EC8 10x4) Dual Rank 1.1V ECC Registered DIMM 288-Pin Server RAM Memory Upgrade Module (A-Tech Enterprise Series)
A-Tech 64GB DDR5 6400MHz PC5-51200 ECC RDIMM 2Rx4 (EC8 10x4) Dual Rank 1.1V ECC Registered DIMM 288-Pin Server RAM Memory Upgrade Module (A-Tech Enterprise Series)
Single 64GB RAM Module; DDR5 DIMM 288 Pin; Speeds up to 6400MHz PC5-51200 (PC5-6400B); ECC Registered RDIMM; 2Rx4 (EC8, 10x4) - Dual Rank x4; JEDEC DDR5 standard 1.1V
$3,109.55
Bestseller No. 3
Samsung 64GB DDR5 4800MHz PC5-38400 ECC RDIMM 2Rx4 (EC8 10x4) Dual Rank 1.1V Registered DIMM 288-Pin Server RAM Memory M321R8GA0BB0-CQK
Samsung 64GB DDR5 4800MHz PC5-38400 ECC RDIMM 2Rx4 (EC8 10x4) Dual Rank 1.1V Registered DIMM 288-Pin Server RAM Memory M321R8GA0BB0-CQK
Samsung DDR5 Memory RAM | Part Number: M321R8GA0BB0-CQK; Single 64 GB Module; DDR5 DIMM 288-Pin; Speeds up to 4800 MHz, PC5-38400 (PC5-4800B)
$2,574.00

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Crashes, No Sound, or Screen Glitches?Free driver scan
PC Slower Than It Used to Be?Free scan - under a minute

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.