Even without guard records and pels, SERVICEABLE_EVENT is displayed in faultlog. Removing the SERVICEABLE_EVENT section if there is no data in it.
Before:
root@p10bmc:/tmp# guard -l
No Records to display
root@p10bmc:/tmp# peltool -l
{}
root@p10bmc:/tmp# faultlog -f
<6> faultlog app to collect deconfig/guard records details <6> Latest chassis poweron time read is :12/06/2023 06:39:33 [
{
"SYSTEM": {
"SYSTEM_TYPE": "9105-22B"
}
},
{
"POLICY": {
"FCO_VALUE": 0,
"MASTER": true,
"PREDICTIVE": true
}
},
{
"SERVICEABLE_EVENT": [] ----> It is displayed even if it is empty
}
]
root@p10bmc:/tmp# faultlog -u
<6> faultlog app to collect deconfig/guard records details <6> Latest chassis poweron time read is :12/06/2023 06:39:33 [
{
"SYSTEM": {
"SYSTEM_TYPE": "9105-22B"
}
},
{
"SERVICEABLE_EVENT": [] ----> It is displayed even if it is empty
}
]
root@p10bmc:/tmp# faultlog -g
<6> faultlog app to collect deconfig/guard records details [
{
"SYSTEM": {
"SYSTEM_TYPE": "9105-22B"
}
},
{
"SERVICEABLE_EVENT": [] ----> It is displayed even if it is empty
}
]
Test Results:
root@p10bmc:/tmp/test# guard -l
No Records to display
root@p10bmc:/tmp/test# peltool -l
{}
root@p10bmc:/tmp/test# faultlog -f
<6> faultlog app to collect deconfig/guard records details <6> Latest chassis poweron time read is :12/06/2023 06:39:33 [
{
"SYSTEM": {
"SYSTEM_TYPE": "9105-22B"
}
},
{
"POLICY": {
"FCO_VALUE": 0,
"MASTER": true,
"PREDICTIVE": true
}
}
]
root@p10bmc:/tmp/test# faultlog -g
<6> faultlog app to collect deconfig/guard records details [
{
"SYSTEM": {
"SYSTEM_TYPE": "9105-22B"
}
}
]
root@p10bmc:/tmp/test# faultlog -u
<6> faultlog app to collect deconfig/guard records details <6> Latest chassis poweron time read is :12/06/2023 06:39:33 [
{
"SYSTEM": {
"SYSTEM_TYPE": "9105-22B"
}
}
]
Even without guard records and pels, SERVICEABLE_EVENT is displayed in faultlog. Removing the SERVICEABLE_EVENT section if there is no data in it.
Before:
Test Results:
Change-Id: Ifbf1704fbd0a87a2b7ca2615d471e559be9008f8 Signed-off-by: Parasa Swetha Parasa.Swetha1@ibm.com