Episode #345

Private Data and the log Utility

Series: Unified Logging and Activity Tracing

6 minutes
Published on July 6, 2018

This video is only available to subscribers. Get access to this video and 573 others.

In this episode we talk about public versus private data (and how to change the defaults). We also look at using the log command line tool for a deeper understanding of the unified logging system and how we can tweak it for our needs.

Links

Using the log Utility to Set Log Levels

Check the status of the logging system:

sudo log config --status

Set the log level to debug:

sudo log config --mode "level:debug"

Tell the system to persist info messages to disk, and show debug messages, only for our subsystem:

sudo log config --mode "level:debug,persist:info" --subsystem com.ficklebits.UnifiedLoggingDemo

Turn on (or off) private data:

sudo log config --mode "private_data:on"

Reset settings back to the default:

sudo log config --reset

This episode uses Xcode 10.0-beta2.