Unified Logging¶
The unified logging payload allows you to configure logging levels by Subsystem (bundle ID), Process or for the System as a whole. It also allows you to configure a different log level for persistent logs.
Also see the log(1) man page for more information about the configuration.
Keys correspond to the directories under /Library/Preferences/Logging
.
Contents
Summary¶
PayloadType: | com.apple.system.logging |
---|---|
Supervised Only: | |
N/A | |
macOS: | 10.12 |
macOS Deprecated: | |
N/A | |
iOS: | N/A |
iOS Deprecated: | N/A |
Highlander: | N/A |
Keys¶
Note
Only the keys for Subsystems are shown because the other types adhere to the same structure.
Subsystems¶
Subsystems
Configure Subsystem Logging
Type | Default | Required | Regex | iOS | macOS | Supervised |
---|---|---|---|---|---|---|
dictionary | N/A | N/A | N/A | N/A | N/A | N/A |
This dict contains one key by default called DEFAULT-OPTIONS
which is applied when no logging category is matched.
The format of this dict is as below:
Default Options¶
Name | Type | Title | Description | Required |
---|---|---|---|---|
Level | dictionary | Minimum Level | Configures minimum logging level and persistence level | n/a |
Default-Privacy-Setting | string | Sensitive Data Logging Settings | Changes how variables eg string substitutions are formatted in the log | n/a |
TTL | dictionary | Log entry time to live by level | Changes how long a log entry will remain before being removed | n/a |
Propagate-with-Activity | boolean | Messages attached to the activity tree | Messages are attached to the activity tree in Console and crash dumps | n/a |
Level¶
Minimum Level
Configures minimum logging level and persistence level
Type | Default | Required | Regex | iOS | macOS | Supervised |
---|---|---|---|---|---|---|
dictionary | N/A | N/A | N/A | N/A | N/A | N/A |
Name | Type | Title | Description | Required |
---|---|---|---|---|
Enable | string | Minimum log level enabled | The minimum log level that will be enabled. Messages sent through NSLog are at the Default level. The default value of this is inherited from the System setting. | n/a |
Persist | string | Minimum log level to persist | The minimum log level that will be persisted. Messages sent through NSLog are at the Default level. The default value of this is inherited from the System setting. | n/a |
Default-Privacy-Setting¶
Sensitive Data Logging Settings
Changes how variables eg string substitutions are formatted in the log
Type | Default | Required | Regex | iOS | macOS | Supervised |
---|---|---|---|---|---|---|
string | N/A | N/A | N/A | N/A | N/A | N/A |
Valid Choices¶
- Inherit
- Public
- Private
TTL¶
Log entry time to live by level
Changes how long a log entry will remain before being removed
Type | Default | Required | Regex | iOS | macOS | Supervised |
---|---|---|---|---|---|---|
dictionary | N/A | N/A | N/A | N/A | N/A | N/A |
Name | Type | Title | Description | Required |
---|---|---|---|---|
Default | integer | Default | Default Log Level TTL in days | n/a |
Debug | integer | Debug | Debug Log Level TTL in days | n/a |
Info | integer | Info | Info Log Level TTL in days | n/a |
Propagate-with-Activity¶
Messages attached to the activity tree
Messages are attached to the activity tree in Console and crash dumps
Type | Default | Required | Regex | iOS | macOS | Supervised |
---|---|---|---|---|---|---|
boolean | N/A | N/A | N/A | N/A | N/A | N/A |
CategoryName¶
Category Logging Options
Default logging settings for the category specified by (CategoryName). This dictionary takes the same format as DEFAULT-OPTIONS.
Type | Default | Required | Regex | iOS | macOS | Supervised |
---|---|---|---|---|---|---|
dictionary | N/A | N/A | N/A | N/A | N/A | N/A |
Enable-Oversize-Messages¶
Enable Oversize Messages
Enables large messages in the log. This WILL have a detrimental effect on performance.
Type | Default | Required | Regex | iOS | macOS | Supervised |
---|---|---|---|---|---|---|
boolean | N/A | N/A | N/A | N/A | N/A | N/A |