SAP Solution Manager monitors the behavior of SAP Instances and sends notification email in case of misbehaviors. Integrating this solution with NetEye the benefit is the possibility to have the mails sent to a user on NetEye Server and thanks to a procmail script rows are inserted into the MessageConsole Application. The script could be like this:
#! /bin/sh
#
export PATH=/usr/local/bin:/usr/bin:/bin:$PATH
#
mailfile=~/tmp/mail$$.log
logfile=~/tmp/mailout$$.log
tmpfile=~/tmp/mailmsg$$.log
#
trap 'rm -f $mailfile $logfile $tmpfile; exit 1' 1 2 15
trap 'rm -f $mailfile $logfile $tmpfile' 0
#
cat >$mailfile
echo EOF >>$mailfile
#
if [ ! -e $mailfile ]
then
echo "Cannot write to $mailfile"
exit 1
fi
#
subject=`cat $mailfile | formail -xSubject | sed -e 's/^ *//g'`
if ! echo "$subject" | grep "SAP Alert"
then
exit 1
fi
#
state=$(grep -E "^[A-Z]* CCMS alert" $mailfile | tail -1 | awk '{ print $1 }')
if [ "$state" = "YELLOW" ]
then
severity=w
else
severity=c
fi
clienthost=SAP
#
to=`cat $mailfile | formail -X "From " | cut -d' ' -f2`
#
cat $mailfile | formail -I "" | (
line=""
read line
while [ "$line" = "" ]
do
read line
done
startblock=0
while [ "$line" != "EOF" ]
do
if echo "$line" | grep "^ALERT f"
then
cat /dev/null >$tmpfile
startblock=1
fi
if [ -z "$line" ]
then
startblock=0
fi
if [ $startblock -gt 0 ]
then
echo "$line" >>$tmpfile
fi
read line
done
)
#
if [ -s $tmpfile ]
then
msgfile="-f $tmpfile"
fi
#
nesendmsg -H localhost -s "$subject" -S "$severity" -l "$clienthost" $msgfile
exit 0
One of the advantage would be to monitor actively if the SAP instances are running, at the very least the one running the Solution Manager. This is done using the binary rfcping and the Nagios check command check_sap_rfcping using the following command syntax:
check_sap_rfcping -a $HOSTADDRESS$ -s-w 2000 -c 5000
Doing so it gives you a pretty good overview over your running SAP instances. 😉
I have over 20 years of experience in the IT branch. After first experiences in the field of software development for public transport companies, I finally decided to join the young and growing team of Würth Phoenix. Initially, I was responsible for the internal Linux/Unix infrastructure and the management of CVS software. Afterwards, my main challenge was to establish the meanwhile well-known IT System Management Solution WÜRTHPHOENIX NetEye. As a Product Manager I started building NetEye from scratch, analyzing existing open source models, extending and finally joining them into one single powerful solution. After that, my job turned into a passion: Constant developments, customer installations and support became a matter of personal. Today I use my knowledge as a NetEye Senior Consultant as well as NetEye Solution Architect at Würth Phoenix.
Author
Juergen Vigna
I have over 20 years of experience in the IT branch. After first experiences in the field of software development for public transport companies, I finally decided to join the young and growing team of Würth Phoenix. Initially, I was responsible for the internal Linux/Unix infrastructure and the management of CVS software. Afterwards, my main challenge was to establish the meanwhile well-known IT System Management Solution WÜRTHPHOENIX NetEye. As a Product Manager I started building NetEye from scratch, analyzing existing open source models, extending and finally joining them into one single powerful solution. After that, my job turned into a passion: Constant developments, customer installations and support became a matter of personal. Today I use my knowledge as a NetEye Senior Consultant as well as NetEye Solution Architect at Würth Phoenix.
Elastic 8.16, which comes with NetEye 4.39, made Elastic Universal Profiling generally available for self-hosted installations. This means that NetEye SIEM installations will now be able to take advantage of the continuous profiling solution by Elastic. In this blogpost we'll Read More
In the first part of this series, we explored how Jira Service Management (JSM) helps streamline Incident Management, aligning with ITIL v4 best practices. Incident Management aims to restore normal service operation as quickly as possible after a disruption, ensuring Read More
Hello everyone! Today, I'd like to briefly discuss an improvement to the update and upgrade procedures that we've started to adopt with NetEye 4.39! What we wanted to improve One aspect that made quite an impact was that whenever the Read More
Hello everyone! Today, I’d like to share an exciting improvement we’ve made to the installation and upgrade procedures in NetEye, introducing a faster and more efficient parallel architecture! Why Modernize the Installation and Upgrade Processes? At Würth Phoenix, we strive Read More
Monitoring SAP systems has always been a major hurdle in every job I've held. SAP has its own monitoring tools, primarily CCMS, but extracting metrics and configurations from the SAP world has always been a challenge. In the past, I Read More