Receiving Errors in logs while trying to use Evaluation Script for populating Additional field in Summary of Alert mail.Same is working perfectly fine for few alerts.

Receiving Errors in logs while trying to use Evaluation Script for populating Additional field in Summary of Alert mail.Same is working perfectly fine for few alerts.

  • Refer Below Evaluation Script Used to populate Additional field from BMV to Summary of Alert Mail.

def get_vumetric_value(metric_dict, vuMetricName, metricName):

  if not metric_dict:

    return None

  if vuMetricName not in metric_dict:

    return None

  if ‘metrics’ not in metric_dict[vuMetricName]:

    return None

  if metricName not in metric_dict[vuMetricName][‘metrics’]:

    return None

  if ‘value’ not in metric_dict[vuMetricName][‘metrics’][metricName]:

    return None

  if metric_dict[vuMetricName][‘metrics’][metricName][‘value’] == “N.A.”:

    return None

  return metric_dict[vuMetricName][‘metrics’][metricName][‘value’]

RESULT = False

R1 = get_vumetric_value(D[0], ‘CIB Login Count 30 mins’, ‘Login count in last 30 mins’)

if R1==0:

  RESULT=True

  add_fields=D[0][‘CIB Login Count 30 mins’][‘metrics’][‘Login count in last 30 mins’][‘includes’]

  value1 = add_fields.get(‘Application’,”NA”)

  DYNAMIC_FIELDS[‘summary’] = ‘Login count in last 30 mins ‘+str(value1)+’ %S’


Error Logs - 

Reference to Vusmartmaps logs for errors

ANS New release, we don’t need to define get_vumetric_value() in the evaluation criteria remove the function part from this and try again? It should be from “RESULT = False”

removed the block above “RESULT = Faslse” and it started working
    • Related Articles

    • Logstash config and enrichment backup using script

      Question: I want to take backup of the logstash config ( /etc/logstash/conf.d ) and enrichment files. I can do it manually. But do we have script for it ? Answer: You can use below script and modify the server details. This script will take a backup ...
    • Device Temperature Alert Issue

      For Device temperature alert, Alert should trigger only if temperature_value > temperature_threshold How to check the above condition? Initially, we are giving a custom threshold in BMV. Temperature_value and temperature_threshold are getting from ...
    • Event Duration field is not showing 331

         Solution Document        Event Duration field is not showing      Overview   General/Customer specific ICICI Author Thirupathi Rao Vardhineni Reviewer Seema Approver  Deepak Release date 05/07/2022 Product Version       8.5r5           Audience: ...
    • Logstash Strip plugin is not working 338

      VuNet Systems Private Limited Solution Document Ticket #338 Logstash Strip plugin is not working.​ Overview General/Customer specific RBL Author Rachitha H V Reviewer Seema Approver Deepak Release date Product Version 8.5r5 Audience: ...
    • Automatic health check report-mail setting

      Solution Document Healthcheck Report Mail Settings Overview General/Customer specific General Author Mantika Jadhav Reviewer Rukmini Approver  Ravi  Release date 08/09/2022 Product Version 8.5r5 Steps to be followed to send a health check report via ...