Verify rsyslog service doesn't leave any footprint on the BMC itself
Changes:
- Search journald entry and fail if there are unexpected
rsyslog footprint.
Change-Id: Ibfaa6583278fe644db5e27911fc2862b12468131
Signed-off-by: George Keishing <gkeishin@in.ibm.com>
diff --git a/remote_logging/test_remote_logging.robot b/remote_logging/test_remote_logging.robot
index 813cad9..ea4db55 100644
--- a/remote_logging/test_remote_logging.robot
+++ b/remote_logging/test_remote_logging.robot
@@ -23,6 +23,9 @@
${BMC_START_MSG} Starting Flush Journal to Persistent Storage
${BMC_BOOT_MSG} Startup finished in
+# Strings to check from journald.
+${RSYSLOG_REGEX} start|exiting on signal 15
+
*** Test Cases ***
Test Remote Logging REST Interface And Verify Config
@@ -36,6 +39,22 @@
Verify Rsyslog Config On BMC remote_host=remote-host remote_port=port
+Verify Rsyslog Does Not Log On BMC
+ [Documentation] Check that rsyslog journald doesn't log on BMC.
+ [Tags] Verify_Rsyslog_Does_Not_Log_On_BMC
+
+ # Expected filter rsyslog entries.
+ # Example:
+ # Sep 03 13:20:07 wsbmc123 rsyslogd[3356]: [origin software="rsyslogd" swVersion="8.29.0" x-pid="3356" x-info="http://www.rsyslog.com"] exiting on signal 15.
+ # Sep 03 13:20:18 wsbmc123 rsyslogd[3364]: [origin software="rsyslogd" swVersion="8.29.0" x-pid="3364" x-info="http://www.rsyslog.com"] start
+ ${bmc_journald} ${stderr} ${rc}= BMC Execute Command
+ ... journalctl -b --no-pager | egrep 'rsyslog' | egrep -Ev '${RSYSLOG_REGEX}'
+ ... ignore_err=${1}
+
+ Should Be Empty ${bmc_journald}
+ ... msg=${bmc_journald} contains unexpected rsyslog entries.
+
+
Verfiy BMC Journald Synced To Remote Logging Server
[Documentation] Check that BMC journald is sync to remote rsyslog.
[Tags] Verfiy_BMC_Journald_Synced_To_Remote_Logging_Server