search cancel

How to have an alert email sent when SD package fails.

book

Article ID: 49951

calendar_today

Updated On:

Products

CA Client Automation - IT Client Manager CA Client Automation

Issue/Introduction

Having in mind the following use case: It is essential that a specific package has 100% roll out, any failure needs to be notified to specific personnel to allow remediation to take place.

How to send an email to the administrator when a SD delivery job fails?

Environment

Client Automation 14.0 and above

Resolution

A Query Based policy can be created to monitor the specific patch for deployment failures and can send several different types of notification including email.

  1. If not done yet, it's required to configure the email integration in the Configuration Policy, as explained here:

    How to configure SMTP Email integration?

  2. Next create the query to monitor the specific package:

  • Expand "Queries", right-click "All Queries", and select "New":

  • Double click "Computers", expand "Software", click on "Software Packages". In the "Select Field" Dialogue Expand "Deployment", select "SW Name"

  1. Against Package Name keep the operator = and Select the Package Name you wish the alert to be generated for in the drop down:

  2. Against Status Select keep the operator = and Select "Deployment Failed" in the drop down

  • Click OK and name the Query.

  1. Now, let's create the Alert:

  • Expand "Policies", right-click "Query Based" and select "New...".

  • Name the Policy, set the Policy severity to "Alert" and select the Query you defined above:

  • Click on "Evaluation" and choose the frequency desired for this Policy to be evaluated.

  • Click on "Send Mail" under "Add Action", enter the email addresses that will receive the alert:

  • Type the message you wish sent, Note there are Macro's that can be used for data that will help locate the failed job.

    For example if you named the Policy " Failed package 1 installs" and defined the following in the message.

    $POLICY$ $NAME$ $DATE$ $TIME$

    You would receive the Message Policy: Failed package 1 installs
    Message: Failed package 1 installs <Agent Name> YYYY-MM-DD HH:SS

Attachments