起初按照社区上的 事件定制 | openUBMC 做了开发,但没有实现对应的告警事件,发帖求助过。
详见该帖 如何配置自定义事件
有伙伴回答是要配置在vendor/event_def.json当中,后续也尝试在该文件中添加了定义,还是没有实现告警。配置如下:
"EventDefinition": [
{
"EventCode": "0x1A0000F1",
"ReportChannel": 65535,
"OldEventCode": "",
"EventType": 0,
"LifeCycleId": 1,
"DeassertFlag": 1,
"EventKeyId": "BMC.VoltLowerNoneCritical",
"SeverityId": 1,
"ActionId": 0,
"EventName": "VoltLowerNoneCritical"
},
{
"EventCode": "0x1A0000F3",
"ReportChannel": 65535,
"OldEventCode": "",
"EventType": 0,
"LifeCycleId": 1,
"DeassertFlag": 1,
"EventKeyId": "BMC.VoltHigherNoneCritical",
"SeverityId": 1,
"ActionId": 0,
"EventName": "VoltHigherNoneCritical"
},
"EventDescription": [
{
"Suggestion": {
"En": "",
"Zh": ""
},
"EventKeyId": "BMC.VoltLowerNoneCritical",
"Description": {
"En": "Voltage %1(%2) is lower than the undervoltage threshold(%3).",
"Zh": ""
},
"Influence": {
"En": "",
"Zh": ""
},
"Cause": {
"En": "",
"Zh": ""
}
},
{
"Suggestion": {
"En": "",
"Zh": ""
},
"EventKeyId": "BMC.VoltHigherNoneCritical",
"Description": {
"En": "Voltage %1(%2) is over the overvoltage threshold(%3).",
"Zh": ""
},
"Influence": {
"En": "",
"Zh": ""
},
"Cause": {
"En": "",
"Zh": ""
}
},
收集了一键日志
framework.log 里看着好像是没有找到class: EventDefinition,和class: EventDescriptionEn
1970-01-01 00:00:25.186870 hwdiscovery WARNING: analyse.lua(372): ignore object: EventDefinition_VoltHigherNoneCritical_00, class: EventDefinition, error: fail to get class information
1970-01-01 00:00:25.187199 hwdiscovery WARNING: analyse.lua(372): ignore object: EventDescriptionEn_VoltHigherNoneCritical_00, class: EventDescriptionEn, error: fail to get class information
1970-01-01 00:00:25.187483 hwdiscovery WARNING: analyse.lua(372): ignore object: EventDefinition_VoltLowerNoneCritical_00, class: EventDefinition, error: fail to get class information
1970-01-01 00:00:25.187851 hwdiscovery WARNING: analyse.lua(372): ignore object: PCIeRASCollector_00, class: PCIeRASCollector, error: fail to get class information
1970-01-01 00:00:25.188140 hwdiscovery WARNING: analyse.lua(372): ignore object: CoolingRequirement_1_24_00, class: CoolingRequirement, error: fail to get class information
1970-01-01 00:00:25.188420 hwdiscovery WARNING: analyse.lua(372): ignore object: DataAcquisitionService_00, class: DataAcquisitionService, error: fail to get class information
1970-01-01 00:00:25.188697 hwdiscovery WARNING: analyse.lua(372): ignore object: FaultPrediction_00, class: FaultPrediction, error: fail to get class information
1970-01-01 00:00:25.189050 hwdiscovery WARNING: analyse.lua(372): ignore object: RASErrorCode_CpuMemoryCfgErr_00, class: RASErrorCode, error: fail to get class information
1970-01-01 00:00:25.189363 hwdiscovery WARNING: analyse.lua(372): ignore object: RASErrorCode_MemoryInitErr_00, class: RASErrorCode, error: fail to get class information
1970-01-01 00:00:25.189638 hwdiscovery WARNING: analyse.lua(372): ignore object: RASErrorCode_MemoryMRCErr_00, class: RASErrorCode, error: fail to get class information
1970-01-01 00:00:25.190049 hwdiscovery WARNING: analyse.lua(372): ignore object: RASErrorCode_SystemNoAvailableMem_00, class: RASErrorCode, error: fail to get class information
1970-01-01 00:00:25.190450 hwdiscovery WARNING: analyse.lua(372): ignore object: DICEConfig_1_00, class: DICEConfig, error: fail to get class information
1970-01-01 00:00:25.192216 hwdiscovery WARNING: analyse.lua(372): ignore object: EventDescriptionEn_VoltLowerNoneCritical_00, class: EventDescriptionEn, error: fail to get class information
1970-01-01 00:00:25.192944 hwdiscovery WARNING: analyse.lua(372): ignore object: RASErrorCode_SystemMemoryConfigErr_00, class: RASErrorCode, error: fail to get class information
1970-01-01 00:00:25.193555 hwdiscovery WARNING: analyse.lua(372): ignore object: FDMService_00, class: FDMService, error: fail to get class information
alarm.log 里面显示no definition,这个应该感觉就是静态配置没找到
[1970-01-04 14:45:27] [register] [Event_V12VPLowerNon_0102] [error_msg: no definition]
[1970-01-04 14:45:27] [register] [Event_V12VCCUpperNon_0102] [error_msg: no definition]
[1970-01-04 14:45:27] [register] [Event_V5VLowerNon_0102] [error_msg: no definition]
[1970-01-04 14:45:27] [register] [Event_V5VSLowerNon_0102] [error_msg: no definition]