LinuxCommandLibrary
GitHubF-DroidGoogle Play Store

systemctl-cat

Display systemd unit file contents

TLDR

Show unit file contents
$ systemctl cat [unit]
copy
Show multiple unit files
$ systemctl cat [unit1 unit2 ...]
copy
Show template unit file
$ systemctl cat [template@]
copy
Show user unit file
$ systemctl cat [unit] --user
copy

SYNOPSIS

systemctl cat PATTERN...

DESCRIPTION

systemctl cat displays the full contents of unit files as systemd sees them, including the main unit file and any drop-in override files. It shows the absolute path of each file before its contents.This is useful for debugging unit configuration, especially when drop-in files in `.d/` directories modify the base unit.

PARAMETERS

--user

Query the calling user's systemd --user manager instead of the system manager.
--system
Query the system manager (default).
--no-pager
Do not pipe output through a pager.
--root=PATH
Read unit files from an alternate filesystem root (useful for inspecting a chroot or mounted image).
--image=PATH
Read unit files from a disk image file at PATH.
-M, --machine=NAME
Operate on the systemd manager inside the named container or VM.
-l, --full
Do not ellipsize displayed paths.

CAVEATS

Shows the raw file contents, not the effective configuration after parsing. Use `systemctl show` to see the actual runtime values. Template units should be specified with the trailing @ symbol.

HISTORY

The cat subcommand is part of systemctl in the systemd project. It provides a convenient way to inspect unit configuration without manually locating files across multiple directories.

SEE ALSO

Copied to clipboard
Kai