Short answer: free -m reports memory for the entire Linux host, while ps aux reports virtual and resident memory for individual processes. They count different things, use different accounting rules, and read live system data at slightly different times, so their totals are not expected to match.
Need a server to try this on? Antihost offers Linux VPS plans with NVMe storage, full root access and a 14-day free trial.
Use free to answer “How much RAM and swap can the machine provide?” Use ps to answer “Which processes have resident pages?” For a fairer per-process total when memory is shared, inspect proportional set size (PSS), not a simple sum of RSS values.
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.
What free -m actually measures
The free utility summarizes physical RAM and swap for the whole operating system. It reads counters from /proc/meminfo; the -m option changes the displayed unit to megabytes. On current procps versions, the underlying counters are reported in KiB and converted for presentation, so the figures are rounded display values rather than a new measurement.
A typical output has columns for total, used, free, shared, buffers, cache, buff/cache and available memory. The modern procps definition of used is:
#1 Best Overall
used = total - available
That is deliberately different from treating every page that is not currently on the free list as permanently consumed by applications. available estimates how much memory new applications can obtain without forcing the system to swap. It considers free pages plus memory that the kernel can reclaim, such as file-backed cache and reclaimable slab objects.
How to read the important fields
| Field | Meaning | How to use it |
|---|---|---|
total |
Physical RAM or swap configured for the host, depending on the row. | Establishes the capacity being discussed. |
used |
For RAM, procps calculates this as total minus available. | Do not interpret it as the sum of application RSS. |
free |
Pages currently unused by the kernel. | A low value alone is not evidence of memory pressure. |
shared |
Memory attributed mainly to tmpfs and shared-memory use. | Investigate alongside Shmem in /proc/meminfo. |
buff/cache |
Buffers, page cache and reclaimable kernel slab memory. | This can grow during normal I/O and can often be reclaimed. |
available |
An estimate of memory that can be given to new programs without swapping. | This is usually the best first indicator of headroom. |
The kernel documents Cached as in-memory file data plus tmpfs and shared-memory pages. MemAvailable is estimated from free pages, reclaimable slab, file-LRU pages and zone watermarks. Consequently, a machine can show a large buff/cache value and still have plenty of immediately usable memory.
The Tool Desk
Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →What ps aux actually measures
ps aux prints one row per process using the user-oriented format. Among its columns are process ID, CPU percentage, memory percentage, virtual size (VSZ) and resident set size (RSS). These values describe a task, not the whole host.
| Column | Definition | Common mistake |
|---|---|---|
VSZ |
Virtual memory size, shown in KiB. It covers the process’s virtual address space, including mappings that have not been faulted into RAM. | Calling VSZ “RAM used.” A program can reserve a large address range while touching only a small part of it. |
RSS |
Resident, non-swapped physical pages currently associated with the task. | Assuming RSS is a complete bill for every kernel resource caused by the process. |
%MEM |
The task’s RSS divided by the machine’s physical memory. | Expecting process percentages to add to the used line from free. |
To get an explicit, sortable view, use:
ps -eo pid,comm,vsz,rss,%mem --sort=-rss
This sorts processes by displayed RSS. It does not make RSS additive: shared pages can still be counted in several rows, and kernel allocations that are not charged to a process row remain outside the list.
Why the numbers diverge
They have different scope
free -m accounts for the machine as a whole. Every process, the kernel, page cache, tmpfs, device mappings and swap contribute to that host view. Each ps row covers only one task. Comparing the host total with one row is therefore comparing different scopes; comparing the host total with a sum of rows still leaves accounting differences.
Linux uses memory for more than process pages
Host memory includes file page cache, filesystem and block-device buffers, reclaimable and unreclaimable slab objects, tmpfs, shared memory, page tables, kernel stacks, locked or pinned pages and other kernel-managed structures. These categories appear in /proc/meminfo and influence free, but they are not all represented as RSS in ps.
Recommended Free Tools
Virtual address space is not resident RAM
VSZ includes reserved address ranges, memory-mapped files, copy-on-write mappings, libraries and pages that have not yet been touched. A process may legitimately have a VSZ of many gigabytes while only a fraction is resident. Summing VSZ values is especially misleading because virtual ranges can overlap and do not correspond one-for-one with physical pages.
RSS counts shared pages once per mapping
If ten processes map the same shared library page, each process’s RSS can include that page. Adding the ten RSS values counts one physical page ten times. Shared-memory segments and shared file mappings create the same effect. The process list can therefore appear to consume more memory than the host physically has, even though the kernel has only one copy of many pages.
Proportional set size (PSS) addresses this specific problem. A shared page is divided among the processes that map it, so each process receives only its proportional share. PSS is the more useful measure when you need to apportion a shared workload, but it is not what ordinary ps aux displays.
Some per-process overhead is intentionally omitted
The ps manual states that SIZE and RSS do not include every process-related structure, including page tables, the kernel stack, struct thread_info and struct task_struct. The manual notes that the omitted resident amount is usually at least 20 KiB per process. Those structures are real memory costs, but they are not included in the RSS column you are adding.
The commands are snapshots, not one transaction
Both utilities read live procfs data. Processes allocate and release pages, the kernel fills or evicts cache, and swap activity can occur between commands. Running free -m and then ps aux captures two different instants. Rounding to megabytes or KiB can add a small visible discrepancy even when the underlying categories overlap.
Is RSS or VSZ the “real” RAM usage?
For physical memory currently resident in a process, RSS is the relevant starting point. It tells you how many non-swapped pages are resident for that task, whereas VSZ describes address-space commitments and mappings. Neither number is a complete answer to “how much memory would disappear if I stopped this process?” RSS may include pages shared with other processes, while VSZ may include pages that cost no RAM until accessed.
Rank #4
Use VSZ to spot large reservations, unusual mappings or address-space limits. Use RSS to rank immediate resident footprint. Use PSS from /proc/<pid>/smaps or smaps_rollup when you need a sharing-aware estimate. For a host-capacity decision, use MemAvailable and the other system counters rather than any single process column.
A practical workflow for reconciling memory
- Check host headroom first. Run
free -m(orfree -h) and readavailable,buff/cache, and both RAM and swap rows together. A highusedvalue with substantialavailableoften reflects reclaimable cache, not an emergency. - Inspect the underlying categories. Read the relevant counters with:
grep -E '^(MemTotal|MemFree|MemAvailable|Cached|SReclaimable|Slab|Shmem|SwapTotal|SwapFree):' /proc/meminfoMemTotal,MemAvailable,Cached,SReclaimable,SlabandShmemexplain why host usage can exceed what process RSS appears to show.SwapTotalandSwapFreeshow configured and unused swap.Quick wins for a faster PC:
Fix the driver behind crashes, sound loss and screen glitchesFind Drivers →Repair Windows errors before they cause bigger problemsFix Now →Scan for outdated or missing drivers - takes under a minuteDriver Scan →Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy. - Rank resident processes. Run
ps -eo pid,comm,vsz,rss,%mem --sort=-rss. Compare RSS with VSZ for each suspected process, but do not add VSZ and do not treat the RSS sum as a host total. - Measure sharing when necessary. For a process ID, inspect
/proc/<pid>/smaps_rollupwhen available, or/proc/<pid>/smaps. Look forRss,Pss, and private/shared clean and dirty values. PSS apportions shared mappings and is better suited to comparing services that use common libraries. - Investigate non-process categories. If the largest RSS values still do not explain low
MemAvailable, examine slab growth, tmpfs usage, huge pages, locked or pinned memory, device mappings and filesystem caches through/proc/meminfoand workload-specific diagnostics. - Repeat measurements under the same conditions. Capture both commands close together, record the time, and compare trends rather than a single pair of rounded snapshots. A short sampling script can run both commands repeatedly while a workload is active.
How to interpret common symptoms
“free says used is high, but RSS totals are modest”
First check available. If it remains healthy, page cache, reclaimable slab, tmpfs or shared memory probably accounts for much of the difference. If available is low, inspect Cached, SReclaimable, Shmem and swap counters to identify which host category is consuming capacity.
“The RSS percentages do not add to 100 percent”
%MEM is calculated per process from RSS and physical RAM. Shared pages may be counted in multiple rows, while caches and kernel allocations are absent from those rows. Percentages are therefore useful for ranking processes, not for reconstructing the free total.
Best Value
- New
- Mint Condition
- Dispatch same day for order received before 12 noon
- Guaranteed packaging
- No quibbles returns
“VSZ is enormous, but the machine is not out of RAM”
Large virtual mappings can be reserved without backing every page with RAM. Check RSS, PSS and the process’s mappings before concluding that the virtual size represents physical consumption. Memory-mapped files and copy-on-write regions commonly make VSZ much larger than RSS.
“Swap is in use even though RAM appears available”
Linux can leave cold pages in swap while using free RAM for useful cache. Check SwapFree, MemAvailable and whether swap activity is ongoing. A nonzero swap-used value alone does not prove current memory pressure; sustained paging and falling available memory are stronger warning signs.
Free tools Windows power users keep installed
One-click scans. No signup required.
Which number should guide a decision?
- Can I start another service? Use
MemAvailable, swap activity and recent trends. - Which process is resident-heavy? Sort by RSS with
ps. - How much address space is reserved? Inspect VSZ and mappings, while remembering that it is virtual.
- How should shared memory be charged to services? Use PSS from
smapsorsmaps_rollup. - Where did host RAM go outside applications? Break down
/proc/meminfocategories such as cache, slab, shmem and huge pages.
The apparent disagreement is therefore expected: free -m answers a host-capacity question, while ps aux answers a per-process mapping question. Select the metric whose scope and accounting model match the decision you are making, and do not turn either output into a total it was not designed to provide.
Quick Recap
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.




