systemd-report-files@.service, systemd-report-files.socket, systemd-report-files — Report the contents of files as system report metrics
systemd-report-files@.service
systemd-report-files.socket
/usr/lib/systemd/systemd-report-files
systemd-report-files@.service is a metrics source for
systemd-report(1). It
reports the contents of a configurable set of files as metrics, by implementing the
io.systemd.Metrics Varlink interface on a socket linked into the
/run/systemd/report/ directory.
The files to report are picked up from report.files/ subdirectories of the
usual configuration directories, i.e. from
/etc/systemd/report.files/,
/run/systemd/report.files/,
/var/lib/systemd/report.files/,
/usr/local/lib/systemd/report.files/ and
/usr/lib/systemd/report.files/. Typically these directories contain symlinks pointing
to the actual files in the file system whose contents shall be reported. Entries with the same name in an
earlier directory override those in a later one.
Each entry is reported as a metric named
"io.systemd.Files.", where
NAMENAME is the name of the entry (which must be a valid metric field name). The
metric value is the verbatim contents of the file. Files that cannot be read (for example because a
symlink is dangling) are skipped, as are files whose contents are not valid UTF-8 text.
Note that access to this service is unprivileged, but it runs privileged. This means take care when
symlinking files into the various report.files/ directories: this service might
provide read access even if the client does not have the required direct access rights itself.