Hidden Mac Daemons: Should You Use cfprefsd


Most computing platforms are chock full of bundled daemons. Daemons, not to be confused with daemons, are usually small agencies that run in the background without interacting directly with the user of the technology. They are often used to implement or help provide support needed for operating systems or products.

The word demon comes from classical Greek belief and is used to refer to a supernatural being that functions between the gods and therefore man. If we replace computer users and gods with some sort of operating system or applications, we get a reasonable idea of ​​what many of these Mac daemons do: perform repetitive tasks that provide the center of the operating system and application or user marketplace.

Activity monitor and daemons
Daemons have no interface; They are visible in the background and are almost always independent of other applications and programs. This prevents the main user from directly interacting with them or even knowingoh they are there. But unnecessarily, your Mac will likely run slower or freeze, perhaps not displaying a spinning beach ball often.

In most cases, only daemons should be deferred; You are very satisfied with the performance of the tasks assigned to you. But if you’re curious, you can use Activity Monitor, the application that comes with your Mac, to see daemongarden.com various daemons and other running programs are typically using your Mac’s resources.

In this example, we’ll work with Activity Monitor to see what two common Mac daemons are: cfprefsd and cloudd. We chose these two daemons because there were a lot of questions on the Internet about what they implement, and also that all these daemons use too many resources.

You may have noticed that the names of our two daemons end in “d”. By convention, developers, all daemon names must end with “d”. Equally important, the daemon’s name often describes its function. For this developer logic, when we subscribe to our two daemon demo we get:

cfprefsd: background process (a daemon because it is an with a d at the end of the name), which is somehow related to cfprefs. If we scratch our heads a little, we can guess that this precious daemon has something to do with settings, and if we knew a little more about Mac development, our group could guess that cf stands for Core Foundation.

(You can also see the characterization of the daemon’s function by using the “man” command in “Allow Terminal”. [Press the “q” key to exit the man page. We ])
en Actually, we cheated a bit and used terminal application to tell us all what cfprefsd is. You can use this strategy with most of these daemons generated by the operating configuration to find out what function they perform.

Launch a terminal located in the And/applications/utilities folder and at the terminal prompt type:

The terminal tells us that “cfprefsd provides preference services for CFP links in addition to the NSUserDefaults API.” If we want to learn more, we could start by looking for references to CFP and NSUserDefaults in the Apple developer documentation. Essentially, cfprefsd helps an iPhone application or system parse or write preference files. When you open an application and configure one of its settings, cfprefsd is the daemon that is currently prompted to make changes to the path to the application settings file.

cloudd: A macOS-related daemon is interfering with services. Taking a closer look at the terminal, the technique above shows that it is now a daemon used by CloudKit, a nice developer API used to pass evidence between an app and a service.Apple iCloud Transfer.

To test this action, the daemon raises the activity flag located in the /Applications/Utilities folder.

When the activity monitor window opens, we are really interested inwhat resources each daemon implements.

In the Activity Monitor window, look at the CPU button on the current toolbar.

You will see a long list of procedures running on your Mac. You might notice several daemons, processes whose names end in d, are listed. But you probably won’t see Cloudd or cfprefsd unless someone scrolls down a bit to show them. An easy way to see each daemon is to enter the person’s name in the search field at the top right of the Activity Monitor window.

The activity monitor contains a list of all running corresponding process sites. You may see multiple daemons with the same name, indicating that multiple users (system, power, or other applications and processes) are still using the daemon. In my case, there are three replicas of the cfprefsd daemon running; The one my logged in user gets, the one controlled by the root user, and the one definitely used by the localized (other daemon).

The most important Back Monitor activity columns to look at are the exact %CPU and Threads columns. In this example, any cfprefsd daemon generates 0 CPU and only two threads are used.

If the number of %CPUs or threads has been high and persisted for a long time, this may indicate a problem with the daemon and more likely with the overall application or process using it.

Daemons usually don’t even use much memory for long periods of time. They may actively need storage applications to perform their tasks, but usually only for a short time. If anyone sees a daemon using a large amount of RAM and staying that way for long periods of timeand, you might have a problem with the software or process each daemon is using.

Clear the Activity Search Monitor panel to see a complete list of physically active processes. You can either enter the name cloudd to see the methods used to support iCloud.

(The cloudd daemon uses a reasonable amount of CPU resources. The photo was taken so large that the folder looks like it was backed up to my iCloud drive, CPU usage dropped to zero after a few minutes.)

What to do if a daemon is abusing resources
First, be patient; Most daemons use memory or CPU resources only duringnot short periods of time. There are exceptions; Of course with Cloudd, for example, assuming you are syncing a large collection of datasets, storage resources can be maxed out for the duration of the transfer. cfprefsd,

He does his job quite simply: he reads and writes the files he needs. or if you have recently installed or updated a better application, it may change the plist files. As with the cloudd-specific daemon, it’s a good idea to wait and see if application usage drops.