systemd-delta
Show differences between systemd configuration files
TLDR
Show all overridden configuration files
Show only files of specific types (comma-separated list)
Show only files whose path starts with the specified prefix (Note: A prefix is a directory containing subdirectories with systemd configuration files)
Further restrict the search path by adding a suffix (the prefix is optional)
SYNOPSIS
systemd-delta [OPTIONS...]
PARAMETERS
-h, --help
Shows a short help text and exits.
--version
Shows a short version string and exits.
--diff
Shows a full diff for modified files, similar to the output of the diff command.
--diff-color[=WHEN]
Controls color output for diffs. WHEN can be 'always', 'never', or 'auto' (default is 'auto').
--no-pager
Do not pipe output into a pager.
--no-legend
Do not print the legend for the output symbols.
--no-summary
Do not print the summary of differences found.
--check-vendor
Compares vendor configuration files with each other (e.g., within /usr/lib/systemd/) to find potential conflicts or overrides from different vendor paths, in addition to the default comparison.
--type=TYPE
Only show files of a specific configuration type. Common types include 'service', 'socket', 'mount', 'timer', 'scope', 'slice', 'path', 'swap', 'automount', 'device', 'target', 'link', 'preset', 'journal-remote', 'journal-upload', 'logind', 'resolved', 'timesyncd', 'coredump', 'hostnamed', 'localectl', 'machined', 'networkd', 'nss-mymachines', 'oom', 'portabled', 'quotamgr', 'sleep', 'system', 'sysusers', 'tmpfiles', 'user', 'userdb', 'udev', 'units'.
--root=PATH
Operates on an alternate root directory. All paths will be relative to this root.
DESCRIPTION
systemd-delta is a utility designed to identify and highlight differences between the vendor-supplied systemd configuration files and those that have been modified or created locally by the system administrator. It is an invaluable tool for understanding how local overrides affect system behavior, diagnosing configuration issues, and maintaining system consistency.
The command primarily compares files found in /etc/systemd/ (and /run/systemd/) with their corresponding default versions in /usr/lib/systemd/. It can display whether a file is new (exists locally but not in vendor defaults), deleted (exists in vendor defaults but not locally), or modified (exists in both but has different content). For modified files, it can optionally show a detailed diff. This helps administrators quickly pinpoint which configurations have been altered from the system's defaults.
CAVEATS
systemd-delta specifically targets systemd configuration files and does not analyze other system configurations. Its output can be extensive on systems with numerous local modifications, potentially requiring careful review. While it helps identify deviations, it does not suggest solutions or automatically revert changes.
OUTPUT SYMBOLS
The command's output uses specific symbols to indicate the status of configuration files:
+: Indicates a new file, found in /etc/systemd/ or /run/systemd/ but not in /usr/lib/systemd/.
-: Indicates a deleted file, found in /usr/lib/systemd/ but absent from /etc/systemd/ and /run/systemd/.
!: Indicates a modified file, present in both /usr/lib/systemd/ and /etc/systemd/ (or /run/systemd/) but with differing content.
HISTORY
systemd-delta was introduced as part of the systemd suite, evolving alongside its development to provide administrators with enhanced introspection and troubleshooting capabilities for complex system configurations. It became available in systemd version 214 (released in 2014), reflecting systemd's focus on robust configuration management and transparency.