Thanks & Regards | Rajesh | Consultant | ENTIIS Pte., Ltd. |
Original Message:
Sent: 2/22/2024 4:22:00 AM
From: Catalin Farcasanu
Subject: RE: Viewing all available alarms in Spectrum
This should extract all custom events that have associated custom alarms.
for event in $(find $SPECROOT/custom -type f -name EventDisp | xargs egrep " A " | gawk '{print $1}'); do
id=$(echo $event | gawk -F"0x" '{print $2}');
alarm=$(find $SPECROOT/custom -type f -name "Prob*${id}*" | xargs head -1);
if [[ ${alarm} != "" ]]; then
alarm_severity=$(find $SPECROOT/custom -type f -name EventDisp |xargs egrep $event |grep A |gawk -F" A " '{print $2}' | gawk -F"," '{print $1}');
case ${alarm_severity} in
1)
severity="MINOR";;
2)
severity="MAJOR";;
3)
severity="CRITICAL";;
4)
severity="4";;
5)
severity="5";;
esac
echo -e "$event | $severity | $alarm" >> /tmp/alarms.txt
fi
done
------------------------------
Cătălin Fărcășanu
Senior Consultant
SolvIT Networks
------------------------------
Original Message:
Sent: Feb 21, 2024 11:15 AM
From: Joseph Ackley
Subject: Viewing all available alarms in Spectrum
Catalin,
Nice script. I will use this in the future.
Thank you,
Joe
Original Message:
Sent: Feb 21, 2024 11:06 AM
From: Catalin Farcasanu
Subject: Viewing all available alarms in Spectrum
You'll need to script your way around $SPECROOT/custom.
find . -type f -name EventDisp | xargs egrep " A "
would yield the custom events that have alarms associated.
---
0x06ec1001 E 20 A 2,0x06ec1001
0x06ec1002 E 20 A 2,0x06ec1002
0x06ec1004 E 20 A 2,0x06ec1004
0x06ec1006 E 20 A 2,0x06ec1006
0x06ec1008 E 20 A 2,0x06ec1008
0x06ec100a E 20 A 3,0x06ec100a
0x06ec100e E 20 A 3,0x06ec100e
---
1 is MINOR
2 is MAJOR
3 is CRITICAL
You'd have to grep your way around the files named "*Prob*US" under $SPEROOT/custom/Events/CsPCause and get the information from there.
Prob06ec100a_en_US;AX GDM MY S Q L NOT REACHABLE
Prob06ec1002_en_US;AX GDM TEST FAIL
Prob06ec1001_en_US;AX GDM SHUTDOWN
Prob06ec1006_en_US;AX GDM N B I DOWN
Prob06ec1004_en_US;AX GDM G U I DOWN
Prob06ec1008_en_US;AX GDM T R069 DOWN
Prob06ec100e_en_US;AX GDM REDIS NOT REACHABLE
------------------------------
Cătălin Fărcășanu
Senior Consultant
SolvIT Networks
Original Message:
Sent: Feb 21, 2024 09:56 AM
From: Joseph Ackley
Subject: Viewing all available alarms in Spectrum
Rejesh,
No shortcut for that that I am aware of.
You will need to check each individual event.
Joe
Original Message:
Sent: Feb 21, 2024 09:48 AM
From: Rajesh Rajesh
Subject: Viewing all available alarms in Spectrum
Thank you Joe, I need the alarm criticality also. How to get them have any shortcut
Get Outlook for Android</http:></mailto:rajesh@entiis.com>