Skip to content

Commit

Permalink
Adjust journald rules for RHEL 10
Browse files Browse the repository at this point in the history
  • Loading branch information
Mab879 committed Dec 19, 2024
1 parent 48f3aff commit ccf8c56
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ ocil: |-
Storing logs with compression can help avoid filling the system disk.
Run the following command to verify that journald is compressing logs.
<pre>
{{%- if product in ["fedora", "rhel8", "rhel9", "sle15"] %}}
{{%- if product in ["fedora", "sle15"] or "rhel" in product %}}
grep "^\sCompress" /etc/systemd/journald.conf {{{ journald_conf_dir_path }}}/*.conf
{{% else %}}
grep "^\sCompress" /etc/systemd/journald.conf
Expand All @@ -45,7 +45,7 @@ ocil: |-
Compress=yes
</pre>

{{%- if product in ["fedora", "rhel8", "rhel9", "sle15"] %}}
{{%- if product in ["fedora", "sle15"] or "rhel" in product %}}
template:
name: systemd_dropin_configuration
vars:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ ocil: |-
Storing logs remotely protects the integrity of the data from local attacks.
Run the following command to verify that journald is forwarding logs to a remote host.
<pre>
{{%- if product in ["rhel8", "rhel9", "sle15"] %}}
{{%- if product in ["sle15"] or "rhel" in product %}}
grep "^\sForwardToSyslog" /etc/systemd/journald.conf {{{ journald_conf_dir_path }}}/*.conf
{{% else %}}
grep "^\sForwardToSyslog" /etc/systemd/journald.conf
Expand All @@ -44,7 +44,7 @@ ocil: |-
ForwardToSyslog=yes
</pre>

{{%- if product in ["rhel8", "rhel9", "sle15"] %}}
{{%- if product in ["sle15"] or "rhel" in product %}}
template:
name: systemd_dropin_configuration
vars:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ ocil: |-
Storing logs with persistent storage ensures they are available after a reboot or system crash.
Run the command below to verify that logs are being persistently stored to disk.
<pre>
{{%- if product in ["fedora", "rhel8", "rhel9", "sle15"] %}}
{{%- if product in ["fedora", "sle15"] or "rhel" in product %}}
grep "^\sStorage" /etc/systemd/journald.conf {{{ journald_conf_dir_path }}}/*.conf
{{% else %}}
grep "^\sStorage" /etc/systemd/journald.conf
Expand All @@ -44,7 +44,7 @@ ocil: |-
Storage=persistent
</pre>

{{%- if product in ["fedora", "rhel8", "rhel9", "sle15"] %}}
{{%- if product in ["fedora", "sle15"] or "rhel" in product %}}
template:
name: systemd_dropin_configuration
vars:
Expand Down

0 comments on commit ccf8c56

Please sign in to comment.