Halloween DealsAmazon USHalloween week deals: useful picks before month-endAmazon US: current deals, useful picks and tech finds.Check DealsWindows FixRecommendedWindows errors stealing your time? Find the fix fastScan stability, cleanup and performance issues.Fix NowHalloween DealsAmazon USOctober picks are moving - compare before checkoutAmazon US: current deals, useful picks and tech finds.See Picks×
FREEDOM251

Freedom251 › Blog › cgroups

Why Your VPS Keeps Crashing Despite Plenty of RAM and Swap

By Freedom251 Team · · 9 min read

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

A VPS can go down while free -h shows comfortable memory because the failing process may be restricted by a cgroup or service limit, terminated by systemd-oomd, or blocked by an entirely different fault. Disk and inode exhaustion, storage latency, CPU throttling, network limits, filesystem damage, kernel panics and provider resets can all look like a “memory crash.” Identify the failure domain from the previous boot’s logs and correlated metrics before adding RAM or swap.

First determine what “crashed” means

“The VPS crashed” describes an outcome, not a cause. Separate the event into one of four categories before changing capacity:

As an Amazon Associate I earn from qualifying purchases.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  • A service died: one process stopped while the guest operating system remained reachable.
  • The guest froze: SSH and applications stopped responding, but there may have been no reboot.
  • The guest rebooted: uptime reset and the previous boot contains the failure evidence.
  • The provider reset or replaced the instance: the guest may have no final log entry, so provider event history and a serial console are essential.

Check the provider’s event timeline and the guest’s uptime together. A reboot without a kernel message can indicate a host fault, watchdog action or forced reset rather than an in-guest out-of-memory event.

Why free RAM does not protect a workload

Global memory and local limits are different

free -h reports memory visible to the guest as a whole. The process that failed may run inside a cgroup, container, systemd service or virtualized memory policy with a lower ceiling. In cgroups v2, inspect the relevant group’s memory.max, memory.current, memory.events and memory.swap.max. A service can therefore hit its limit while the rest of the VPS still has reclaimable or free pages.

#1 Best Overall
Sale
TOZO A1 Wireless Earbuds Bluetooth 5.3 Light Weight in Ear Headphones | IPX5 Waterproof,2 Mics for AI Calls,Immersive Premium Sound Bass Headset with Charging Case,32 EQ via App Black
  • [Ultra-Lightweight Ear Buds Designed for Small Ears] Each earbud weighs only 3.7g and features a compact, ergonomic in-ear design made especially for small ears. Secure, low-profile, and comfortable for workouts, all-day wear or overnight sleeping.The ultra-slim profile sits flush in your ear with no hard edges poking or rubbing, so you can even sleep on your side without discomfort.
  • [Immersive Stereo Sound with TOZO OrigX Technology] TOZO OrigX tuning delivers clear vocals, balanced mids, and natural stereo sound for music, podcasts, and videos.
  • [Long Battery Life for Daily Use] Get up to 7 hours of playtime on a single charge, with up to 32 hours total using the charging case—ideal for workdays, commuting, and extended listening sessions.
  • [Bluetooth 5.3 & Stable Connection] Bluetooth 5.3 provides fast pairing, stable wireless performance, and reduced dropouts as you move around home or office.
  • [Deep Bass with Clear Vocals] High-performance drivers produce punchy bass while keeping vocals clean and detailed for everyday listening.

Check service-level settings such as MemoryMax=, container limits and shell limits from ulimit -a. Also account for cpusets or other placement policies: a workload can be constrained to a subset of resources even when unused capacity exists elsewhere in the guest.

Userspace OOM decisions can happen first

On systems using cgroups v2, Ubuntu’s systemd-oomd monitors memory pressure (pressure-stall information) and can terminate a cgroup before the kernel reaches a global OOM condition. Its decision is deliberate policy, not proof that the entire VPS ran out of RAM. Check whether it is active with:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
systemctl status systemd-oomd

Then read its journal entries and identify the unit or cgroup it selected. The unit’s pressure and limits matter more than the host-wide “available” figure.

What a kernel OOM message actually means

When the kernel cannot satisfy an allocation under the applicable policy, it invokes the OOM killer and chooses a process to terminate. Linux kernel documentation describes the behavior plainly: “If this is set to 0, the kernel will kill some rogue process, called oom_killer.” The victim may not be the process that originally consumed the most memory; selection also considers process importance and the constrained memory domain. A message such as oom-kill or Killed process is a starting point for inspecting the victim, cgroup path and concurrent workload, not an automatic instruction to buy more RAM.

Swap is a pressure valve, not a guarantee

Swap provides a place for selected pages when RAM is under pressure. It does not enlarge a cgroup’s permitted memory indefinitely, make an impossible allocation succeed, or repair another exhausted resource. A cgroup can have a restrictive memory.swap.max; the guest can also have swap space that is technically present but unusable because the backing disk is full or I/O is failing.

Rank #2
Sale
Smart Watch for Men Women Compatible with iPhone Samsung Android Phone 1.69 inch Full Touch Screen IP68 Waterproof Bluetooh Fitness Tracker Heart Rate/Sleep Monitor (Black)
  • 【IP68 Waterproof Multifunctinal Smart Watch】Torjalph fitness activity tracker smart watch is IP68 waterproof technology ,you can wear it when swimming,handwashing,it's rain-proof which means that you perform multiple exercise modes outside without worrying about sweat or rain corroding your fitness smart watch,and this watch equipped with a 230 mAh large capacity battery magnetic charging ,and this sports activity tracker watch can be used 5-7 days If fully charged.
  • 【Larger 1.83'' Full Screen Watch & Multi-dial Selection】1.83 inch full HD color touch screen smart watch for men / women provides excellent 240*284 resolution image quality ,This Bluetooth smart watch offers a better touch experience and remarkable immersion and ,more than 200 watch faces for you to choose from App"Da Fit ", you can change the dial style according to your mood to wear keeping the world on your wrist
  • 【Accurate Activity Tracker Smart Watch 】sports watch activity tracker uses sweat and dust resistant breathable silicone strap, our Fitness Tracker Smart Watch for Android iOS Phones supports 12 sports modes,walking,running,bicycle,swimming,badminton,basketball,football,rope skipping. This bluetooth calls smart watch for men women is lightweight and stylish, bringing more convenient and relaxing sports experience while also providing more protection.
  • 【Your 24 Hour Personal Daily Health Monitor】Fitness watch for women men full touch screen IP67 waterproof bluetooth smartwatch for Android iOS Phones with heart rate blood pressure monitor multifunction Andriod smart watch with steps counter sleep monitor sports fitness watch, monitoring blood oxygen saturation allows you to understand your physical condition in real time to track fitness progress ,to know your health status in time.
  • 【More Functions Bluetooth Call Smart Watch】This fitness activity smart watch full screen for iPhone and Android phones includes a bunch of new features including:The bluetooth smart watch can hang up the phone, receive and display WhatsAPP /Text /Facebook /Twitter /Messenger reminder.Support sedentary reminder, alarm clock, stopwatch, timer,weather information,music control, remote camera control compatible with Android 5.0 and above or iOS 9.0 and above smartphones.

Capture both the configuration and live activity:

free -h
swapon --show
vmstat 1 5

In vmstat, sustained swapping alongside rising run-queue pressure can indicate real memory contention. Conversely, a swap partition with little activity does not rule out a local cgroup cap or an early systemd-oomd decision. Swap also cannot help when the failure is “No space left on device,” an inode shortage, storage timeout, network outage, filesystem corruption or provider-side throttling.

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

Read the previous boot before making changes

Reboots can erase the only useful context unless journald is persistent. Start with the previous boot:

journalctl --list-boots
journalctl -k -b -1
journalctl -b -1 -p warning..alert

-k limits output to kernel messages, -b -1 selects the prior boot and the priority filter highlights warnings through alerts. If a unit is known, add its unit filter, for example journalctl -u your-service -b -1. Search the output for these signatures:

  • oom-kill, Out of memory or Killed process
  • systemd-oomd and memory-pressure decisions
  • Kernel panic - not syncing, panic_on_oom, hung_task, BUG: or Oops:
  • I/O error, EXT4-fs error, XFS and watchdog messages
  • No space left on device and journal write failures

Google’s boot troubleshooting guidance separates panic causes such as an OOM panic, crashed init, filesystem damage, machine checks and a corrupt kernel image by the exact panic text. Preserve the complete message, including the first error and stack trace, rather than copying only the final line.

Measure every independent limit

Take a snapshot while the VPS is healthy and repeat it after an incident. This prevents a post-reboot reading from hiding a transient limit:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #3
New Bee Guitar Cable 10ft Electric Instrument Bass AMP Cord | 6.35mm Jack, Durable Design, Stage and Home Studio Use, Low Noise Shielded Electric Cord for Bass, Keyboard, Amp, Mixer
  • [Low Noise High Fidelity] New bee guitar cord with 22AWG oxygen-free-copper center conductors provides enhanced signal transfer, the PVC insulation material and the high-density stranded copper double shield provide noise rejection for quiet operation
  • [Ideal for Choice] New bee 1/4 straight and right angle metal connectors, ensures a secure connection in any instrument, pedal, or amp jack. L shape great fro on stage guitar stands
  • [Wide Compatible] Suitable for mixer, power amplifier, microphone, effector, decoder, equalizer, electoronic organ, electric guitar, electric bass and other electronic equipments. Widely used in the installation of smart home, karaoke speaker, professional stage audio, etc
  • [Easy Disassemble] Making incidental repairs quick and easy! Very nice, flexible cable
  • [Dont Hesite to Order] 24 hours customer services and professional technology team are standing by
free -h
swapon --show
vmstat 1 5
df -h
df -i
ulimit -a
systemctl status systemd-oomd

For the affected service or container, record memory.current, memory.max, memory.events and memory.swap.max from its cgroup. In memory.events, counters such as oom and oom_kill show whether that group reached a limit, even if global memory looked normal. Record the cgroup path with the incident timestamp so a later service restart does not leave you guessing which limit applied.

Use relationships between metrics to find non-memory faults

Individual percentages are easy to misread. Microsoft’s troubleshooting guidance recommends observing relationships between system behavior and metrics rather than interpreting one utilization number in isolation.

Observed relationship Likely direction Next checks
High load average with low CPU utilization I/O wait or blocked tasks Storage latency, queue depth, filesystem errors and blocked processes
Application latency rises while CPU remains unsaturated Disk or network bottleneck Provider I/O and network metrics, connection errors and retransmits
CPU usage repeatedly rises and falls at a ceiling CPU throttling or a burst-limit policy Provider CPU-credit or throttling counters and host event history
High swap activity with reclaim pressure Actual memory contention Largest consumers, cgroup limits and concurrent jobs
Writes fail while RAM remains available Disk blocks, inodes or filesystem failure df -h, df -i, kernel storage errors and disk health

Collect local measurements during the symptom:

iostat -xz 1
pidstat -d 1
mpstat -P ALL 1

High device utilization with large await times points toward storage latency rather than a shortage of memory. A full filesystem can prevent services from writing PID files, sockets or journals and can damage the filesystem after an unclean shutdown. An inode shortage has the same “no space” symptom even when byte capacity remains.

Recognize common failure signatures

Evidence What it establishes Immediate investigation
oom-kill or Killed process A kernel OOM action occurred in a particular memory domain Victim, cgroup path, memory.events, swap limit and simultaneous jobs
systemd-oomd messages Userspace pressure policy terminated a cgroup PSI data, unit policy and cgroup limits
Kernel panic - not syncing The kernel deliberately halted Exact reason, complete previous-boot log and serial-console output
No space left on device or full df -i Writes were blocked by blocks or inodes Free space safely, remove runaway logs and expand only after verifying the filesystem
I/O error, EXT4 or XFS errors Storage or filesystem integrity is suspect Provider disk metrics, backups, read-only recovery and filesystem checks during maintenance
Guest unreachable with no final guest log Could be a provider reset, host fault or panic before logging Provider event history and serial console

Make logs survive the reboot

By default, a volatile journal may disappear when the VPS restarts. Create persistent storage under /var/log/journal, restart or reload journald, and set bounded retention in journald.conf. Use these controls to prevent logs from consuming the same disk they are meant to diagnose:

  • SystemMaxUse limits total persistent journal size.
  • RuntimeMaxUse limits the volatile journal.
  • SystemKeepFree reserves free space on the persistent filesystem.
  • RuntimeKeepFree reserves free space for runtime logs.

Choose limits that leave room for the operating system and application data, then verify after a reboot with journalctl --list-boots. Persistent logs are evidence, but they are not a substitute for off-instance monitoring: a host failure can prevent the guest from writing anything.

Rank #4
BSIMB 15.6" Digital Family Calendar & Chore Chart, No Subscription Fees
  • Digital Family Calendar: BSIMB digital calendar wall touch screen puts an end to your chaotic life. Designed for busy families, the digital calendar keeps you organised and in step with your family. Assign different colours and tasks to each family member to make family scheduling easier and more intuitive.
  • Easy Setup and Auto-Sync: Plug in, connect to WLAN and auto-syn your electric calendar in minutes. Digital wall calendar compatible with Google calendar, iCloud calendar, Outlook calendar, Cozi calendar and Yahoo calendar. Add events directly on the device or through the ecalendar app. Electronic calendar stays current whether you're at work or traveling—no manual updates needed.
  • All-In-One Home Assistant: Smart calendar builds habits and encourage independence with personalised chores. Display daily meal plan to reduce the daily ‘What's for dinner?’ stress. To-do lists keep track of everything you want. Turning chores into valuable achievements with stars and rewards, making life easier and more enjoyable.
  • Manage Anytime Anywhere: BSIMB electronic calendar for family stay connected with the powerful ecalendar app. Access and manage your digital wall calendar anytime, anywhere with free features like stars & rewards, photo screensaver, chore charts, meals plans, to-do lists etc. Electronic planner paid features like Magic Import tailor advanced tools for users with special needs.
  • Stay in Touch with Loved Ones: Share photos or videos from your phone to electronic wall calendar with app, instantly update your life moment, and keep in touch with your family, especially those who are far away; you can also surprise your smart calendar digital wall by sending him a wish card; it's also great for keeping tech-illiterate elders in touch with the youngsters.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Apply the remedy to the failure domain

Workload or service limit

Reduce concurrency, fix a leak, cap worker counts or raise the affected unit’s memory limit only after confirming its cgroup counters. Keep the limit intentional; removing it can allow one service to consume the whole guest and trigger a broader outage.

Guest-wide memory shortage

If multiple unrelated services show pressure, the guest has no restrictive local cap, swap is usable and logs show kernel OOM activity, then reducing workload or adding RAM is rational. Size the change from measured peak working sets, not from a single post-reboot snapshot.

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

Disk or inode exhaustion

Stop the writer if necessary, remove or rotate known runaway files, and confirm both df -h and df -i recover. Expand the virtual disk and filesystem only with a current backup and the provider’s documented procedure. If kernel errors indicate corruption, prioritize a safe recovery or restore over repeated forced boots.

Storage latency or provider throttling

Correlate iostat await and utilization with the provider’s IOPS, throughput and burst metrics. Move write-heavy jobs, reduce queue depth or request a storage class and limit that match the workload. A RAM upgrade cannot lower a saturated disk’s latency.

Kernel, filesystem or package regression

Preserve the panic text and previous-boot logs, boot a known-good kernel if the provider offers that option, and schedule filesystem checks from a maintenance environment. Do not repeatedly reboot a system reporting I/O errors; each unclean shutdown can worsen damage.

Provider or host event

Compare guest uptime with provider events and request the host-side reason when the guest has no closing log. Configure a serial console, external uptime check and alerting so a lost SSH connection does not become the only evidence.

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

Why dropping caches is not a crash fix

echo 3 > /proc/sys/vm/drop_caches discards reclaimable page and inode caches. Kernel documentation describes it as a testing and debugging control and warns that it can add I/O and CPU cost. It does not raise a cgroup limit, repair a filesystem, remove an inode shortage or stop provider throttling. Use it only for a controlled experiment, never as routine incident remediation.

When resizing the VPS is justified

Resize only when the evidence shows a guest-wide memory ceiling: repeated kernel OOM events affecting independent services, sustained reclaim or swap pressure, no restrictive cgroup or service limit, and no stronger disk, CPU, network or provider signature. If the failure is local to one cgroup, correct that policy. If latency or I/O errors dominate, changing RAM leaves the failing resource untouched.

Evaluate any capacity change on five axes:

  1. Failure domain: workload, cgroup, kernel, filesystem, disk, network or provider.
  2. Evidence quality: persistent logs and correlated time-series metrics versus a single symptom.
  3. Recovery risk: potential data loss and expected restoration time.
  4. Reversibility: whether the change can be rolled back without a rebuild.
  5. Observability: whether the provider exposes CPU, I/O, burst and event metrics needed to verify the result.

A practical incident checklist

  1. Record the incident time, uptime and provider event history.
  2. Classify the event as a killed service, freeze, guest reboot or provider reset.
  3. Read journalctl -k -b -1 and the previous boot’s warnings and alerts.
  4. Search for OOM, systemd-oomd, panic, filesystem, I/O and space signatures.
  5. Capture memory, swap, cgroup, disk, inode, CPU and I/O metrics.
  6. Check service limits, cgroup counters and provider throttling or burst data.
  7. Preserve logs persistently and keep retention bounded.
  8. Fix the identified domain, then reproduce or monitor under the same workload.
  9. Resize only if measurements prove a guest-wide capacity shortage.

The key distinction is between apparent headroom and usable headroom for the failing component. A VPS remains stable when its workload limits, storage, CPU, network path, filesystem and provider controls are all observed and matched to demand—not merely when the host-wide RAM counter looks comfortable.

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.

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

cgroupsdisk I/OLinux TroubleshootingMemory Managementserver crashesSwapsystemdVPS

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.

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.