Hi Team,
I want to script particular trap logs but there are different values in /var/log/snmptt/snmptt.log & /var/log/messages.
how can i get the same data in /var/log/snmptt/snmptt.log ?
logs in /var/log/snmptt/snmptt.log:-
Mon Jun 24 2019 09:24:31 .1.3.6.1.4.1.29723.500.3.89 Normal "Status Events" 66.76.80.24 - 23310 IE status=Adjust White Point Status: False Lef <AdjustInitial Camera Value Delta:t RGBLeft RGB: 24.5488986784141,22.3281938325991,23.7916299559471, Right RGB: 23.4321585903084,28.3044052863436, .600000Final Camera Value Delta: Left RGB: 24.5488986784141,22.3281938325991,23.7916299559471, Right RGB: 23.4321585903084,28.3044052863436, , IE adjust white point completed. - smsAdjustWhitePointCompleteNotify
logs in /var/log/messages:-
Jun 24 09:24:35 NagiosXI nagios: SERVICE ALERT: 23310;laser-smsAdjustWhitePointCompleteNotify;OK;HARD;1;info 23310 IE status=Adjust White Point Status:#011False #011Left: ReachMaximumAttempts: Right: ReachMaximumAttempts#015 <Adjust White Point Task Statistics>#015 #011Final Laser Power:#011Left RGB: 60.4646168535145,57.7099715735505,45, Right RGB: 56.591931060616,68.2778659605457,100#015 #011Laser Power Change:#011Left RGB: -15.1145141412564,-17.9286315754699,-4.7461386762685, Right RGB: -14.3959143096404,-14.4293465428976,0#015 #011Target Camera Value:#011Left RGB: 97.4511013215859,84.4718061674009,93.4083700440529, Right RGB: 91.0678414096916,109.295594713656,96.6#015 #011Initial Camera Value Delta:#011Left RGB: 24.5488986784141,22.3281938325991,23.7916299559471, Right RGB: 23.4321585903084,28.3044052863436,0.600000000000009#015 #011Final Camera Value Delta:#011Left RGB: 24.5488986784141,22.3281938325991,23.7916299559471, Right RGB: 23.4321585903084,28.3044052863436,0.600000000000009#015 #011Total Iterations:#0110#015 #011Left ft-L Reference:#0119.55#015 #011Right ft-L Reference:#0119.47#015 #011Left ft-L Current:#0116.77334801762115#015 #011Right ft-L Current:#0116.71660792951542#015 <End of Adjust White Point Task Statistics>#015 #015 <Laser Information>#015 #011Left Projector:#015 #011#011Installed RED Diodes:#01124#015 #011#011#011Total ON Diodes:#01121#015 #011#011#011Total BLOCKED Diodes:#0112#015 #011#011#011Max Diode Hours:#01118004#015 #011#011#011Mean Diode Hours:#01117600#015 #011#011Installed GREEN Diodes:#01140#015 #011#011#011Total ON Diodes:#01136#015 #011#011#011Total BLOCKED Diodes:#0111#015 #011#011#011Max Diode Hours:#01118006#015 #011#011#011Mean Diode Hours:#01117707#015 #011#011Installed BLUE Diodes:#01120#015 #011#011#011Total ON Diodes:#01120#015 #011#011#011Total BLOCKED Diodes:#0110#015 #011#011#011Max Diode Hours:#0113482#015 #011#011#011Mean Diode Hours:#0113421#015 #011Right Projector:#015 #011#011Installed RED Diodes:#01112#015 #011#011#011Total ON Diodes:#01112#015 #011#011#011Tota
Trap Info
Re: Trap Info
Edit /etc/snmp/smptt.ini and change:
to
then restart:
Code: Select all
syslog_enable = 0Code: Select all
syslog_enable = 1Code: Select all
service snmptt restartAs of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
-
jatindeepsharma
- Posts: 70
- Joined: Wed Apr 04, 2018 10:52 am
Re: Trap Info
Hi cdienger,
I have tried same code as shown above but still no luck on these logs. can you please help?
/var/log/snmptt/snmptt.log
Wed Jun 26 2019 09:46:20 .1.3.6.1.4.1.29723.500.3.89 Warning "Status Events" 67.71.247.162 - 21427 IE status=Adjust White Point Status: True Current laser power left:65.20, 84.98, 50.33 Right: 80.15, 89.39, 71.65. Laser power relative to initial set point Left: 98.2%, 98.9%, 100.7% Right: 9 <AdjustFinal Laser Power:StatisLeft RGB: 65.1988439862706,84.9762820196916,50.3347785929809, Right RGB: 80.1528118454679,89.3855292857075,71.64521 , IE adjust white point completed. - smsAdjustWhitePointCompleteNotify2,-0.399999999999999, Right RGB: -6.3,-5.8,0.8999999999999992116173506
/var/log/messages
Jun 26 09:46:24 NagiosXI nagios: SERVICE ALERT: 21427;laser-smsAdjustWhitePointCompleteNotify;WARNING;HARD;1;maj 21427 IE status=Adjust White Point Status:#011True #011Current laser power left:65.20, 84.98, 50.33 Right: 80.15, 89.39, 71.65. Laser power relative to initial set point Left: 98.2%, 98.9%, 100.7% Right: 92.6%, 92.5%, 92.4%#015 <Adjust White Point Task Statistics>#015 #011Final Laser Power:#011Left RGB: 65.1988439862706,84.9762820196916,50.3347785929809, Right RGB: 80.1528118454679,89.3855292857075,71.6452171476879#015 #011Laser Power Change:#011Left RGB: 4.25754294916747,1.91675824104568,0, Right RGB: 12.8067853637387,12.5014726273717,-2.11412116173506#015 #011Target Camera Value:#011Left RGB: 73,52,58.3, Right RGB: 36.6,36.9,31.4#015 #011Initial Camera Value Delta:#011Left RGB: -5.09999999999999,-1.2,-0.399999999999999, Right RGB: -6.3,-5.8,0.899999999999999#015 #011Final Camera Value Delta:#011Left RGB: -5.09999999999999,-1.2,-0.399999999999999, Right RGB: -6.3,-5.8,0.899999999999999#015 #011Total Iterations:#0113#015 #011Left ft-L Reference:#01111#015 #011Right ft-L Reference:#01111#015 #011Left ft-L Current:#01111#015 #011Right ft-L Current:#01111#015 <End of Adjust White Point Task Statistics>#015 #015 <Laser Information>#015 #011Left Projector:#015 #011#011Installed RED Diodes:#01124#015 #011#011#011Total ON Diodes:#01124#015 #011#011#011Total BLOCKED Diodes:#0110#015 #011#011#011Max Diode Hours:#0113001#015 #011#011#011Mean Diode Hours:#0113001#015 #011#011Installed GREEN Diodes:#01132#015 #011#011#011Total ON Diodes:#01132#015 #011#011#011Total BLOCKED Diodes:#0110#015 #011#011#011Max Diode Hours:#0113000#015 #011#011#011Mean Diode Hours:#0112977#015 #011#011Installed BLUE Diodes:#01120#015 #011#011#011Total ON Diodes:#01120#015 #011#011#011Total BLOCKED Diodes:#0110#015 #011#011#011Max Diode Hours:#0112992#015 #011#011#011Mean Diode Hours:#0112936#015 #011Right Projector:#015 #011#011Installed RED Diodes:#01112#015 #011#011#011Total ON Diodes:#01112#015 #011#011#011Total BLOCKED Diodes:#0110#015
I have tried same code as shown above but still no luck on these logs. can you please help?
/var/log/snmptt/snmptt.log
Wed Jun 26 2019 09:46:20 .1.3.6.1.4.1.29723.500.3.89 Warning "Status Events" 67.71.247.162 - 21427 IE status=Adjust White Point Status: True Current laser power left:65.20, 84.98, 50.33 Right: 80.15, 89.39, 71.65. Laser power relative to initial set point Left: 98.2%, 98.9%, 100.7% Right: 9 <AdjustFinal Laser Power:StatisLeft RGB: 65.1988439862706,84.9762820196916,50.3347785929809, Right RGB: 80.1528118454679,89.3855292857075,71.64521 , IE adjust white point completed. - smsAdjustWhitePointCompleteNotify2,-0.399999999999999, Right RGB: -6.3,-5.8,0.8999999999999992116173506
/var/log/messages
Jun 26 09:46:24 NagiosXI nagios: SERVICE ALERT: 21427;laser-smsAdjustWhitePointCompleteNotify;WARNING;HARD;1;maj 21427 IE status=Adjust White Point Status:#011True #011Current laser power left:65.20, 84.98, 50.33 Right: 80.15, 89.39, 71.65. Laser power relative to initial set point Left: 98.2%, 98.9%, 100.7% Right: 92.6%, 92.5%, 92.4%#015 <Adjust White Point Task Statistics>#015 #011Final Laser Power:#011Left RGB: 65.1988439862706,84.9762820196916,50.3347785929809, Right RGB: 80.1528118454679,89.3855292857075,71.6452171476879#015 #011Laser Power Change:#011Left RGB: 4.25754294916747,1.91675824104568,0, Right RGB: 12.8067853637387,12.5014726273717,-2.11412116173506#015 #011Target Camera Value:#011Left RGB: 73,52,58.3, Right RGB: 36.6,36.9,31.4#015 #011Initial Camera Value Delta:#011Left RGB: -5.09999999999999,-1.2,-0.399999999999999, Right RGB: -6.3,-5.8,0.899999999999999#015 #011Final Camera Value Delta:#011Left RGB: -5.09999999999999,-1.2,-0.399999999999999, Right RGB: -6.3,-5.8,0.899999999999999#015 #011Total Iterations:#0113#015 #011Left ft-L Reference:#01111#015 #011Right ft-L Reference:#01111#015 #011Left ft-L Current:#01111#015 #011Right ft-L Current:#01111#015 <End of Adjust White Point Task Statistics>#015 #015 <Laser Information>#015 #011Left Projector:#015 #011#011Installed RED Diodes:#01124#015 #011#011#011Total ON Diodes:#01124#015 #011#011#011Total BLOCKED Diodes:#0110#015 #011#011#011Max Diode Hours:#0113001#015 #011#011#011Mean Diode Hours:#0113001#015 #011#011Installed GREEN Diodes:#01132#015 #011#011#011Total ON Diodes:#01132#015 #011#011#011Total BLOCKED Diodes:#0110#015 #011#011#011Max Diode Hours:#0113000#015 #011#011#011Mean Diode Hours:#0112977#015 #011#011Installed BLUE Diodes:#01120#015 #011#011#011Total ON Diodes:#01120#015 #011#011#011Total BLOCKED Diodes:#0110#015 #011#011#011Max Diode Hours:#0112992#015 #011#011#011Mean Diode Hours:#0112936#015 #011Right Projector:#015 #011#011Installed RED Diodes:#01112#015 #011#011#011Total ON Diodes:#01112#015 #011#011#011Total BLOCKED Diodes:#0110#015
Re: Trap Info
The second message is coming from the nagios process which will be different than what snmptt logs. Enabling the option I pointed out should allow snmptt to log to both syslog and the snmptt.log, but if it is not, then you may be better assisted contacting the maintainer of snmptt - http://snmptt.sourceforge.net/.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.