HeartbeatHocusFocusFilesMacHyperTile
Guide

logd, the daemon that writes everything down

logd is the macOS daemon that collects, compresses and keeps every line your Mac logs. Measured live: its 2.3 GB self pruning library, and the processes that fill it.

By Chethan Kumar S N · Updated

Every process on a Mac is talking, all the time. WindowServer mutters about frames, installd announces an update, a daemon you have never heard of files a complaint about a failed connection, and almost none of it reaches the screen. It reaches logd. Each talking process drops its lines into a page of memory it shares with the daemon, and logd collects the pages, compresses what it finds, and files it in a library that on the Mac measured here has reached 2.3 GB. It has been on the job without a single exit since the machine last booted, it spends about nine minutes of processor time a day on the work, and it is the busiest of the quiet background daemons this series has measured so far.

The measurements come from one Mac: a 10 core MacBook Pro on macOS 27.0.1, up 27 days at the time of writing. Everything was read read only: the manual page, the launch configuration, the daemon’s own statistics files, the store on disk, the binary’s strings. Nothing was quit, killed, deleted or changed, and every command is at the end if you want to interrogate your own machine the same way.

A manual page from 2018

logd ships with its own manual page, logd(8), dated August 30, 2018, and it is one of the better ones in this series because it contains a picture. In the original it is drawn in ASCII, boxes and arrows, and it says more about the architecture than a page of prose could:

Processes append entries to shared pages. logd reads the pages and combines and compresses the data. Depending on configured policies, it keeps the results in a local ring buffer or writes them out to persistent storage. The log command can view both, by requesting access from logd.

That is the whole system in four sentences. Every process writes into memory it shares with logd, so logging a line costs almost nothing, no file is opened, no lock is taken. The daemon is the only one that ever touches disk. The picture even names the front door: the log command, and behind it the Console app, both of which ask logd politely rather than reading anything themselves.

Apple’s own developer documentation for the Logging API describes the same design without ever naming the daemon, which is the usual hedge: “The unified logging system provides a comprehensive and performant API to capture telemetry across all levels of the system. This system centralizes the storage of log data in memory and on disk, rather than writing that data to a text-based log file.” The same page notes that the system “supersedes the Apple System Logger (ASL) and Syslog APIs”. The old world is still on the disk if you know where to look: /etc/asl holds ten configuration files from the ASL era, among them com.apple.authd and com.apple.mail, retired but not deleted, like furniture left in a house after the family that owned it moved out.

The binary itself is modest for what it does: 628,256 bytes at /usr/libexec/logd, arm64e and arm64e.x1 slices only, no Intel, built on 24 September 2026 and signed by Apple with platform identifier 26. It holds just 1,043 strings, thin for a daemon this central, because the real machinery lives one framework over in LoggingSupport, the same arrangement the hollow symptomsd uses.

Six doors and one very old socket

The launch configuration lists six Mach services, and their names read like the floor plan of a records office. There is com.apple.logd itself, the main counter. There is logd.admin for configuration changes. There is logd.cachedelete, for when another part of the system asks that something be thrown away early. There is logd.events and logd.realtime, the two doors the log stream and Console read through, one for subscribing to events as they happen, one for live tailing. And there is logd.watchdog, a service whose entire purpose is to be watched. At the moment this page was written, seven client connections were active across those doors.

Then there is the seventh door, and it is the oldest thing on the premises. The plist declares a socket named BSDSystemLogger at /var/run/syslog, type datagram, with a path mode that decodes to 666: readable and writable by every user on the machine. That is deliberate. Any process on a Mac, including one you wrote yourself in a scripting language, can still make a classic syslog call, and the call lands in that socket, and the socket belongs to logd. On the disk of the measured Mac the socket file carries a date from the day the machine was set up. Unix logging from the 1980s and Apple’s unified logging from 2016 pour into the same clerk.

The rest of the configuration is short and firm. KeepAlive true, RunAtLoad true, and in launchd’s own ledger the daemon shows runs equal to 1: started once, at boot, never exited. The immediate reason for the start is given as ipc (socket), meaning something knocked on one of those doors early and the daemon was brought up to answer. Minimum runtime is one second, exit timeout five, and two environment variables that have become familiar in this series, OSLogRateLimit set to 64 and MallocSpaceEfficient set to 1, telling it to rate limit itself and to prefer small memory. One line is unique among the dozens of daemons measured so far: the job will only load on a system variant with full logging, HasFullLogging, a reminder that the stripped-down builds Apple ships on other devices do not all get this clerk at all.

The library, 2.3 GB of it

The store lives at /var/db/diagnostics, permissioned to root only, and it is the biggest single pile of diagnostic data an ordinary Mac accumulates. On this machine, 27 days after boot:

Persist holds 508 MB in 51 files, the ordinary run of the mill logs. Signpost holds 238 MB in 125 files, the performance instrumentation that tools like Instruments and os_signpost read. Special holds 1.5 GB in 1001 files, and it is the shelf that surprises people who find this folder with a disk space tool. HighVolume is empty, reserved for processes that deliberately opt into logging above normal rates. And a timesync directory keeps three small files that reconcile log timestamps against the machine’s continuous clock.

The files themselves are named as bare sixteen digit hex counters, 0000000000000fcb.tracev3 and its neighbours, and they are all the same size, just over ten megabytes, because that is the point at which logd closes one archive and opens the next. The format is compressed and indexed, which is why a 2.3 GB store holds vastly more raw log text than it appears to.

Two small files in the root of the store deserve a mention. roles.plist contains four entries, DCP, DCPEXT0, DCPEXT1 and AOP, and they are not obscure: those are the display coprocessor engines and the Always On Processor, the chips that keep working while the main CPU sleeps, each with its own logging role. And version.plist tracks time to live bookkeeping in buckets named ttl01 and ttl03 against the machine’s continuous uptime clock, the daemon’s own notes on how long each class of history is worth keeping.

The purge engine

Nothing about this folder needs your management, and the proof is that logd writes down its own housekeeping. Inside the store sits logdata.statistics.0.txt, a plain text file, and it is the daemon’s diary of everything it threw away. The current file on this Mac holds 295 records: 129 memory rollovers, 90 file rotations, 48 persist purges and 28 special purges.

A purge record is three lines. Type, time, and the files deleted with their sizes, one or two at a time, ten megabytes each, quietly reclaimed on a schedule measured in minutes. And then one field that is the most honest number in the whole store: the goal. On this machine it reads 9223372036854775807, which is the largest value a signed 64-bit integer can hold. That is logd saying, in the only language it has, that the disk has room and no size limit is being enforced today. On a fuller disk the goal drops, and the purges get hungrier. The library manages itself, and it has been doing so since long before you looked.

Who fills the shelves

The best document in the store is not about the daemon at all. Each memory rollover record ends with a list of who filled the buffer, with byte counts and percentages, and it reads like a noise complaint filed against the whole system. The largest rollover in the current statistics file, from seven in the morning on the day of writing, carried 40,877,875 bytes and laid the blame thus: 23.8 percent from a simulator rendering service, 15.4 percent from opendirectoryd, the accounts and directory daemon, 13.6 percent from WindowServer, and 6.9 percent from launchservicesd. The signpost rotations tell the same story with one voice: a single WindowServer entry holding 58.4 percent of a rotated file.

This is the answer to almost every logd question in one table. The daemon does not generate this volume, it carries it. A busy logd means somebody on the machine is chatty, and the statistics file names the talkers to the byte.

The flood has consequences upstream, too, and the spindump page measured them from the other side: the system’s resource checker grants logd a write budget of about 24.86 KB per second, roughly 2 GB a day, and flags the daemon when it exceeds the allowance. On a heavy day the writer can blow through the budget in hours. The library is big because the system is loud, not because the clerk is greedy.

The cost, measured honestly

For all that volume, the price is small and it is paid in instalments. In 27 days and 9 hours of continuous running, logd used 245 minutes and 46 seconds of processor time, which works out to just under nine minutes a day, or 0.62 percent of a single core on this 10 core machine. That is the heaviest of the quiet background daemons measured in this series: nearly double fseventsd’s five and a quarter minutes a day of file system diary keeping, and fourteen times apsd’s 38 seconds of holding one connection open to Apple.

Memory sits in the low thirties of megabytes, and between the two samples taken while writing this page it fell from 33.8 MB to 27.4 MB. A daemon whose footprint shrinks while you watch is not leaking; it is trimming, because every rollover throws buffer contents away. EnablePressuredExit is set to false in the launch file, putting logd in the small club, with fseventsd and apsd, of daemons the system has explicitly promised not to reclaim under memory pressure. A clerk everyone hands evidence to cannot afford to vanish mid sentence.

The daemon that is too important to crash

One block in the launch configuration stops you cold the first time you read it. It is called PanicOnCrash, it contains a single key, PanicOnConsecutiveCrash, and it is set to true. Read as English: if this daemon crashes, launchd restarts it within a second, the throttle interval is one second, the fastest restart policy measured in this series. If it crashes again and again, the operating system does not limp on with degraded logging. It panics, deliberately, on purpose, because a Mac with no one keeping the records is not considered a Mac worth running.

This is the context for the one logd message most people ever see, the dialog that says logd experienced a problem. It appears after a crash, which on a healthy machine is rare, and it is worth reading as the system telling you the clerk fainted once. The daemon’s own diary, logd.0.log, goes back further than the current boot: its opening lines are dated 19 September, the day this Mac was set up, written by a logd with process number 27 under an older system build, and they include an assertion failure, a note about harvesting kernel UUIDs, and the marvellous line Exclaves log server not available, Exclaves not supported on this device, the daemon asking after Apple’s secure execution environments and noting the answer. The diary survived a reboot, and the shutdown it recorded, 34 KB of final flush in shutdown.0.log, is filed beside it.

Even the power button passes through. Twice on the afternoon this page was written, the diary records a flush for power button: the moment someone presses that button, the system tells the clerk to write everything down before anything drastic happens. BeginTransactionAtShutdown, another line in the launch file, means the last thing logd does before the lights go out is close its books cleanly, so the next boot opens a fresh set.

The neighbourhood

logd does not work alone, and the two colleagues are worth knowing by sight. logd_helper is a 244 KB binary with a resident memory footprint of 416 KB, smaller than most web pages, which spent 1.5 seconds of processor time across a day and a half on the job; it is spawned by logd itself rather than by launchd, which is why launchctl has never heard of it. diagnosticd, named in the manual page’s see also, is the live wire sibling that streams logs to Console and Xcode as they happen. And syslogd, the ASL era remnant, is still running after 27 days with a 1.6 MB footprint, keeping the oldest corners of the old system warm.

And the copies. There were three logd processes on the measured Mac: the real one, pid 409, root, parent launchd, and two more running under the user account out of iPhone simulator runtimes, iOS 27.0 and iOS 27.1, each booted simulator keeping its own clerk for its own little phone. If you develop for iOS, three or four logd rows in Activity Monitor is a slow Tuesday, not an incident. It is the same story as the duplicate apsd and usernoted copies, and now you know the pattern by heart.

The short version

logd is the system’s clerk, the only process that writes the unified log to disk. Every process shares pages of memory with it, it compresses and files what it collects into a self pruning 2.3 GB library, it costs about nine minutes of processor time a day, and the system considers it so load bearing that repeated crashes are answered with a deliberate kernel panic. If it looks busy, the statistics file it keeps names whoever is actually talking. There is nothing to configure, nothing to clean, and no decision for you to make.

How to look at your own

The daemon and its row in Activity Monitor:

ps -Awwo pid,ppid,user,%cpu,rss,etime,args | grep "[/]logd"

The launch configuration, including the panic clause and the old socket:

plutil -p /System/Library/LaunchDaemons/com.apple.logd.plist
launchctl print system/com.apple.logd
ls -l /var/run/syslog

The library and its shelves:

du -sh /var/db/diagnostics
du -sh /var/db/diagnostics/Persist /var/db/diagnostics/Signpost /var/db/diagnostics/Special
ls -ltr /var/db/diagnostics/Persist | tail -3

The purge engine and the noise complaint, both plain text:

grep "^type" /var/db/diagnostics/logdata.statistics.0.txt | sort | uniq -c
grep -A8 "Memory Rollover" /var/db/diagnostics/logdata.statistics.0.txt | head -12

The manual page, the front door, and the talkers on your machine:

man logd
log stats --last 1h

The last of those prints what the statistics file keeps on file: which processes filled the buffer, and by how much. On a quiet Mac it is a short list, and on a loud one it is a diagnosis, which is the entire point of keeping a clerk.

Questions

What is logd on Mac?

It is the unified logging daemon, the single clerk that every other process on the system hands its log lines to. When an app writes to the log with os_log, it appends entries into a page of memory shared with logd, and logd reads those pages, compresses them, and either keeps them in a ring buffer in memory or writes them into the store under /var/db/diagnostics. Its manual page, logd(8), has described the job since August 2018 in one line: logd is the part of the unified logging system responsible for handling and managing historical data. On the Mac measured here it has run since the last boot without exiting once, at a cost of about nine minutes of processor time a day, and it was holding 2.3 GB of compressed logs from the last 27 days.

Why is logd using CPU or memory?

Because everything else is talking. logd is the funnel for the whole system, so its CPU column moves when its clients do, and the daemon keeps its own receipts about who the talkers are. On this Mac, the largest rollover in the current statistics file attributed 23.8 percent of one batch to a simulator rendering service, 15.4 percent to [opendirectoryd](/guides/opendirectoryd-mac), 13.6 percent to WindowServer and 6.9 percent to launchservicesd. The command log stats, run for a recent window, names the chattiest processes on your own machine. Around 30 MB of memory is normal and healthy: that is the buffer, and on the Mac measured here it fell from 33.8 MB to 27.4 MB between two samples taken an hour apart, because every rollover trims it. A busy logd is a symptom, and the cure is always upstream, in whatever process is shouting.

What is /var/db/diagnostics, and can I delete the tracev3 files?

That folder is logd's library. On the Mac measured here it holds 2.3 GB across four shelves: Persist, 508 MB of ordinary logs in 51 files; Signpost, 238 MB of performance instrumentation in 125 files; Special, 1.5 GB in 1001 files; and a small timesync directory, plus an empty HighVolume shelf that fills only when a process opts into high volume logging. The tracev3 files are compressed log archives, named as bare hex counters, and each one closes and a new one opens at roughly ten megabytes. You do not need to delete them, and deleting them live is the wrong moment if you ever need recent logs: logd prunes its own shelves on a schedule, and its purge records are visible in the statistics file, 48 persist purges and 28 special purges in the current one. If disk space is the worry, know that the store is already managed and its size goal on a machine with free disk reads as the largest number a 64-bit integer can hold, meaning plenty.

Is logd a virus or malware?

No. The copy measured here lives at /usr/libexec/logd, 628 KB of code signed by Apple with platform identifier 26, built on 24 September 2026, running as root with launchd, process ID 1, as its direct parent, and it ships with a manual page that has been in macOS since 2018. The quick checks for any process you are unsure about: the path must be /usr/libexec/logd, the user must be root, and the parent must be launchd. One thing that is not a sign of trouble: if you develop iOS apps, every booted iPhone simulator runs its own copy of logd under your user account, from the simulator runtime's RuntimeRoot. Three logd rows in Activity Monitor on this machine, one from the system and two from simulators, is normal, not an infestation.

Can I quit or disable logd?

No, and the system has written that decision into its launch file in the starkest terms available: a block named PanicOnCrash with PanicOnConsecutiveCrash set to true. If logd crashes, launchd restarts it within a second, the throttle interval is one second and the minimum runtime is one second, both the lowest in this series. If it crashes again and again, the operating system deliberately panics rather than keep running with no one keeping the records. There is no switch in System Settings because nothing on the Mac can run without logging. The honest levers that do exist are upstream: find the process flooding the logs with log stats, quiet that app or uninstall it, and logd goes quiet with it. The daemon's own cost, about nine minutes of processor time a day to keep 27 days of history, is not the thing to optimise.

Ready? Buy Ribbon for $15, or read all the guides.