← All rules
SOCLE-RUN-LOG-004// Loggingmediumeffective runtime

A system logging daemon is active

Ensures a system logging daemon, rsyslog or syslog-ng, is installed and actively running.

Checked against the resolved running state (e.g. sshd -T, sysctl, systemctl show), catches drop-ins and Includes a file read would miss. Caveat: runtime ≠ persistence; a value correct now may not survive a reboot.

A pass proves✓ running now? on disk? survives rebootthe qualified verdict →

This domain is partially covered by Pavois today, see coverage.

Debian 12CIS 1.1.0Debian 13CIS 1.0.0FedoraRHEL 10 / Rocky 10 / AlmaLinux 10RHEL 8 / Rocky 8 / AlmaLinux 8CIS 4.0.0RHEL 9 / Rocky 9 / AlmaLinux 9CIS 2.0.0Ubuntu 22.04CIS 3.0.0Ubuntu 24.04CIS 1.0.0Ubuntu 26.04
One check, maps to 3 standards

Pavois asserts the effective configuration, the live, resolved state, not a file. File-based scanners (OVAL/SCAP, Lynis) miss Includes, drop-ins and runtime defaults; this check sees what is actually applied.

A mapping is a cross-reference to where each standard places this requirement, anchored and cross-validated, not a claim of equivalence. A passing check is evidence toward these references, how to read it.

Why this rule matters

A running syslog daemon (rsyslog or syslog-ng) is required to capture, persist and forward system and security events. Without an active logging daemon, evidence of intrusions, service failures and policy violations is lost, defeating incident response, forensics and compliance auditing. Centralized logging also enables off-host retention so an attacker cannot simply erase local traces.

What Pavois checks

Pavois checks the effective service state: it iterates over rsyslog and syslog-ng and accepts the rule as soon as systemctl is-active reports one of them running. Querying systemd reflects whether the daemon is truly up right now, a package being installed or a unit file present says nothing about a service that failed to start or was masked.

describe command('for s in rsyslog syslog-ng; do systemctl is-active --quiet "$s" && { echo ok; exit 0; }; done; echo ko') do
  its('stdout.strip') { should eq 'ok' }
end

How to verify it is applied

  • systemctl is-active rsyslog (or syslog-ng) should return active.
  • systemctl status rsyslog should show running.
  • logger -t test 'Pavois check'; tail -n1 /var/log/syslog (Debian/Ubuntu) or /var/log/messages (RHEL) should show the test line.

Inspect & investigate

  • systemctl status rsyslog / systemctl status syslog-ng for daemon health.
  • journalctl -u rsyslog for the daemon's own start/stop and error events.
  • /var/log/syslog or /var/log/messages are the files the daemon itself produces.

Remediation

Pavois's harden plan uses a choose resource: it installs and enables a logging daemon, defaulting to rsyslog (package rsyslog, service rsyslog), with syslog-ng as an alternative. It installs the package, then enables and starts the service so logging is active immediately and on boot. Apply with pavois harden apply.

Pavois applies this with its own harden engine, the plan below, not a shell script:

defaultrsyslog
optionsrsyslog: package: rsyslog, service: rsyslog, syslog-ng: package: syslog-ng, service: syslog-ng
resourcechoose
pavois harden plan local

where the target is local, a user@host SSH alias, or a container , Docs

Impact & precautions

Low risk, adding a syslog daemon is non-disruptive. Caution: do not run both rsyslog and syslog-ng simultaneously, as they compete for the same sockets and inputs; pick one. On minimal/container images that rely solely on the systemd journal, installing rsyslog increases disk usage from /var/log, ensure log rotation is configured.

Standards mapping

StandardReferenceTypeVersionConfidence
ANSSI BP-028R71direct2.0high
CIS6.1.3.2, 6.2.2.2directper OS, see the benchmark tablehigh
DISA STIGUBTU-22-652010, UBTU-24-100200directper OS STIG releasehigh

Each reference is a cross-reference anchored in the upstream benchmark and cross-validated against the SCAP Security Guide and ansible-lockdown, not a claim of equivalence. Direct = a prescriptive, line-level requirement; supporting = an abstract control family (NIST) the check provides evidence toward. How to read a mapping.

Sources & references