summaryrefslogtreecommitdiff
path: root/meta-facebook
diff options
context:
space:
mode:
authorJayashree Dhanapal <jayashree-d@hcl.com>2021-06-15 15:33:57 +0300
committerJayashree Dhanapal <jayashree-d@hcl.com>2021-06-15 15:33:57 +0300
commit65d9cfae12a5b38300343df5a8bfade81ce68718 (patch)
treeb0c1a855eed0516079feca26e9e2a178b490b2cd /meta-facebook
parent8bfb421b066225451c3767927ac25c9b0477db86 (diff)
downloadopenbmc-65d9cfae12a5b38300343df5a8bfade81ce68718.tar.xz
meta-facebook: Add rsyslog for Redfish.
Added template for Redfish format in rsyslog conf file to save the journal entry as Redfish event. Tested : Verified journalctl log in tiogapass using Redfish. Signed-off-by: Jayashree Dhanapal <jayashree-d@hcl.com> Change-Id: Ic09530c824e65c5dd27fc4c6dac5a385370bdadc
Diffstat (limited to 'meta-facebook')
-rw-r--r--meta-facebook/meta-tiogapass/recipes-extended/rsyslog/rsyslog/rsyslog.conf17
1 files changed, 16 insertions, 1 deletions
diff --git a/meta-facebook/meta-tiogapass/recipes-extended/rsyslog/rsyslog/rsyslog.conf b/meta-facebook/meta-tiogapass/recipes-extended/rsyslog/rsyslog/rsyslog.conf
index 3aae03f31..5a85aadb5 100644
--- a/meta-facebook/meta-tiogapass/recipes-extended/rsyslog/rsyslog/rsyslog.conf
+++ b/meta-facebook/meta-tiogapass/recipes-extended/rsyslog/rsyslog/rsyslog.conf
@@ -25,11 +25,26 @@ template(name="IPMISELTemplate" type="list") {
constant(value="\n")
}
-# If the journal entry has a Redfish MessageId, save as a Redfish event
+# Template for Redfish messages
+# "<timestamp> <MessageId>,<MessageArgs>"
+template(name="RedfishTemplate" type="list") {
+ property(name="timereported" dateFormat="rfc3339")
+ constant(value=" ")
+ property(name="$!REDFISH_MESSAGE_ID")
+ constant(value=",")
+ property(name="$!REDFISH_MESSAGE_ARGS")
+ constant(value="\n")
+}
+
+# If the journal entry has a IPMI SEL MESSAGE_ID, save as IPMI SEL
if ($!IPMISEL_MESSAGE_ID != "") then {
action(type="omfile" file="/var/log/ipmi_sel" template="IPMISELTemplate")
}
+# If the journal entry has a Redfish MessageId, save as a Redfish event
+if ($!REDFISH_MESSAGE_ID != "") then {
+ action(type="omfile" file="/var/log/redfish" template="RedfishTemplate")
+}
#
# Include all config files in /etc/rsyslog.d/
#