Friday, October 25, 2019

Solaris Server SNMP

Monitoring Solaris Server services using custom OID's

Assumption: SNMP server side configuration is completed

# vi /etc/sma/snmp/snmpd.conf
exec pscheduler_snmpd /bin/bash /usr/bin/Scheduler_snmpd.sh
 

Place the scripts under /usb/bin/
# cat /usr/bin/Scheduler_snmpd.sh
count=`ps -ef | grep BBL |egrep -i 'CHECK1|CHECK2'|wc -l` > /dev/null
if [ $count -eq 2 ]
then
   echo "1"
else
   echo "0"
fi


Set the permission of the script to  (would prefer only execute permission)
#chmod 777 /usr/bin/Scheduler_snmpd.sh

Restart the SNMP service on the Solaris server by running command
 #svcsadm restart sma




 












 


 




No comments: