Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

TylerL

macrumors regular
Original poster
Jan 2, 2002
207
291
I'm constantly shocked by the number of backgound processes on macOS. On my M1 MacBook Pro with all apps closed (except Terminal to measure), I count nearly 400(!) background processes.

About 200 processes support basic system functionality (owned by root and friends), and another nearly 200 spawned by my user account.
Maybe ~20 or so are due to to installed helper software, like Adobe Creative Cloud or iStat Menus. The rest provide the basic functionality of an iCloud-connected macOS user with only Terminal open.

I'd love to hear this is not normal. What does YOUR idle system look like? Here's how I get a quick count of running processes:
Bash:
ps auxww | wc -l
...but I'm pretty confident this is simply How Things Are Done in this day and age... Everything's an always-on daemon. Daemons everywhere. Of course Software Update needs to have 4 processes taking up RAM 24/7. Deal with it.

Screen Shot 2022-01-15 at 1.49.18 PM.png


Untitled.png


On their own, each process is pretty innocuous, most taking only 5-10MB of RAM, but together they monopolize system resources.
By the time a user gets a couple Safari tabs open, 8 GB of RAM are used. And I'm not even talking about file cache! A system with 8GB of RAM total must be completely saturated and panic-compensating with compression and swapping soon after first sign-in...

Screen Shot 2022-01-15 at 1.18.13 PM.png


That's it. Just venting. Though I hope Apple improves here in macOS 13, turning many of these always-on daemons into on-demand or timed launchd triggers, etc etc.
 

chabig

macrumors G4
Sep 6, 2002
11,408
9,108
Vent all you want. It won't change anything. This is how modern operating systems work, and it's probably the best way.

On their own, each process is pretty innocuous, most taking only 5-10MB of RAM, but together they monopolize system resources.
By the time a user gets a couple Safari tabs open, 8 GB of RAM are used. And I'm not even talking about file cache!

It has long been said that free RAM is wasted RAM. You cannot judge the system by how much RAM is being used. The more RAM used, the more efficiently the OS is making use of its resources.

A system with 8GB of RAM total must be completely saturated and panic-compensating with compression and swapping soon after first sign-in...

I have two 8GB M1 systems and my memory pressure is always in the green. The system does a great job of managing it.
 

TylerL

macrumors regular
Original poster
Jan 2, 2002
207
291
It has long been said that free RAM is wasted RAM. You cannot judge the system by how much RAM is being used. The more RAM used, the more efficiently the OS is making use of its resources.
Then surely Apple should double the number of always-running background processes (again) to use even more RAM and make our computers even more efficient!

"Free RAM is wasted RAM" only works if your RAM isn't already being wasted. Your file cache can't grow and increase system responsiveness if there's no place to put it. Apple Silicon Macs' fast SSDs try to mask the problem, but this is a worrying trajectory.
 

EugW

macrumors G5
Jun 18, 2017
14,381
12,175
Technology marches on. If you don't like the way modern OSes work, then buy an old MacBook Pro with 10.7 Lion. Problem solved.
 

xgman

macrumors 603
Aug 6, 2007
5,695
1,425
Technology marches on. If you don't like the way modern OSes work, then buy an old MacBook Pro with 10.7 Lion. Problem solved.
But then isn't there something in that statement that seems odd? So one would ask why? Why do we have to get less stable as we "match on"?
 

EugW

macrumors G5
Jun 18, 2017
14,381
12,175
But then isn't there something in that statement that seems odd? So one would ask why? Why do we have to get less stable as we "match on"?
IMO, the least stable versions of OS X were 10.0-10.3 actually.

Since then, stability has fluctuated somewhat but has stayed relatively decent... if you're talking about an OS which has received all the updates, and if you're running a machine with sufficient RAM and fast enough CPU.

I might get instability and/or significant bugs with brand new OSes (eg. 12.0), when running third party peripherals or drivers, or when there is insufficient RAM and CPU performance.

In general I don't experience significantly more instability as time marches on, but I do upgrade my machines so that they have sufficient RAM and CPU performance. If the machine is too old or cannot be upgraded, then that's when running an older OS or buying a new machine makes more sense. If you don't need the new features the new OSes offer, then there isn't a need to upgrade.

tl;dr:

I didn't think fully updated Catalina - on a fully supported stock Apple machine with sufficient RAM and CPU - was less stable than fully updated High Sierra on the same machine. Monterey has its issues, mainly with bugs, but I can understand that because it is still just on 12.1. It still has 9 months of OS updates to come.
 

throAU

macrumors G3
Feb 13, 2012
9,103
7,254
Perth, Western Australia
I'm constantly shocked by the number of backgound processes on macOS. On my M1 MacBook Pro with all apps closed (except Terminal to measure), I count nearly 400(!) background processes.

This isn't necessarily anything to worry about. Splitting things into more processes is by design and there are logical, well considered reasons to do this.

Apple is likely splitting things up into more processes than before in order to
  1. more granularly limit permissions to only the specific tasks within an application that require elevated security
  2. enable more efficient use of multiple cores; and/or more efficient scheduling of E cores vs. P cores.
  3. enable more efficient swap out of idle parts of an application/system
#1 is a huge one. Security permissions are process specific. If you have one huge monolithic process that has elevated permissions then any flaw or bug in that process also gets those permissions. ergo, you want to make the privileged parts of the OS as small and task-specific as possible so they're more difficult to exploit and there's less code to find bugs in that could have catastrophic impact.

Limiting the size of processes by ensuring they do less and splitting off elevated permissions to a different process is a method of hardening security.

Microsoft, google and others are all doing this with their software specifically to limit the impact of bugs on system security.
 
Last edited:
  • Like
Reactions: chabig and EugW

semistandard

macrumors member
Aug 19, 2018
96
47
It has long been said that free RAM is wasted RAM. You cannot judge the system by how much RAM is being used. The more RAM used, the more efficiently the OS is making use of its resources.

Everyone one know that memory management can slow down the system, since releasing unnecessary memory is not a cheap operation. Hence, obviously it is better not to release the memory at all. Sure it can cause memory leaks, but SSDs are fast these days, so nothing really to worry about!
 

throAU

macrumors G3
Feb 13, 2012
9,103
7,254
Perth, Western Australia
More importantly, why throw things out of memory when they may be needed again? You can page anything to SSD but keep it in RAM. If RAM is required by something else, instantly drop (it's already swapped out). If it is required again - it's already in RAM as well as on the SSD.

Free RAM available on a modern OS isn't as simple as the "free ram" number.
 
  • Like
Reactions: chabig

throAU

macrumors G3
Feb 13, 2012
9,103
7,254
Perth, Western Australia
As a very basic example anyone can observe in modern safari using activity monitor:
With 1 tab open right now (this one), safari has spawned 4 processes:

  • The parent application thread
  • A thread for this specific tab
  • A thread for rendering graphics and playing media
  • a thread for 1blocker / other plugins
In the old days this may have been one monolithic process. Meaning that say, the rendering thread (which is a complex process involving complex codecs that have historically been full of exploitable bugs) would have had full permission to anything the parent safari process would have had access to. No more. It is sandboxed in its own process.
 

semistandard

macrumors member
Aug 19, 2018
96
47
The problem is not with the number of threads... But with the claim " It has long been said that free RAM is wasted RAM. You cannot judge the system by how much RAM is being used. The more RAM used, the more efficiently the OS is making use of its resources." It is obviously wrong, yet people throw it around for some reason.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.