Rule Actions Best Practices

For rule actions, consider the following factors:

  1. Aggregate over the fields of interest on the rule’s Aggregation tab.

  2. Use the Set Event Field action to set unused fields to the fields you specified for aggregation. Start with the $ symbol followed by the exact name of the variable but without any special characters like spaces and dots. For example, if the variable is ActorByAccountID.Last Name, you may use something like:

    $ActorByAccountIDLast_Name
            
        
  1. Continue by specifying the list to be acted on by the rule.

Note: Duplicate rule actions after a crash recovery:

If you stop ESM, it takes a checkpoint of the rules engine so that it knows what actions have been performed and where it stopped. If ESM crashes in such a way that it cannot take a checkpoint (during a power failure, for example), it returns to the last checkpoint when ESM restarts, and replays events from there. Any actions that occurred between that checkpoint and the ESM crash are therefore repeated. Repeated actions that generate audit events generate duplicate audit events.

You should investigate repeated actions that do not duplicate well. For example, if an action adds an item to an Active List, that item’s counter will be incremented. If the action runs a command, it will run the command again, and so on.