Manage Monitoring Using MCS Profile Types

uim203
HID_Manage_Monitoring_MCS
Determine what you want to monitor in your environment and create the corresponding configuration profiles. You can create a configuration profile for each device or you can create a group configuration profile that MCS applies to all devices in a group. Use the profile types that are displayed in the Monitoring Config page to create configuration profiles.
The safest way to roll out configuration profiles is to create preliminary device-level configuration profiles on a 'test' device. Perform tests on the device configuration profiles and verify the results. When the device configuration profile is fully tested, copy the tested device profile to production groups.
Contents
Enhanced profiles enable you to configure metrics, baselines, alarm thresholds, alarms - including Time Over Threshold alarms - and custom alarm and close alarm messages, all within a single MCS profile.
Create a Device Configuration Profile
Always create device configuration profiles, and then copy the fully tested profiles to groups.
Follow these steps:
  1. In Operator Console, expand a group in the Groups view and select a device.
    The OC group can be one of the predefined OC groups (for example, the Unix and Windows groups) in a test environment or in a test group that you created. The OC group should have at least one device.
  2. Select the Monitoring Config icon in the top-right menu.
    The profile types that apply to the selected device appear.
    If you select a device and profile types do not appear in the Profiles tab, deploy a robot to the device.
  3. In the Profiles tab, click '
    +
    ' to add a profile.
    Profile types are displayed alphabetically. Consider configuring the Setup profile types first. You can also view the version of the template in the Template Version column. The following screenshot shows the Template Version column:
  4. (Optional) Select
    Yes
    if you see a dialog asking if you want the probe to be installed. Verify that the probe resides in the local archive of the hub.
  5. Configure the monitoring settings.
  6. Create the configuration profile.
View the profile status information to verify that the configuration profile was successfully applied to the target device. Until the configuration profile is applied, you cannot modify or copy the profile. When the configuration profile is successfully applied, the status changes to Deployed and the lock disappears.
Create a Group Configuration Profile
You can create group configuration profiles, although we recommended that you copy tested device profiles to a group. Monitoring Configuration Service applies group profiles to all devices in a group that have a robot installed. If a robot is not installed on a device, Monitoring Configuration Service cannot communicate with that device.
Some profile types require data from a device before you can create a group configuration profile. For these profile types, you must select a
reference device
. Monitoring Configuration Service retrieves the data the profile type requires from a probe that is deployed to the selected reference device. Once the data is populated in the profile type, you can continue to create a group configuration profile.
Monitoring Configuration Service can take some time to apply a group configuration profile to every device in a group. After Monitoring Configuration Service has successfully applied a group profile to all devices in a group, make configuration changes to the group profile. The group profile controls the configuration for the member devices.
Follow these steps:
  1. In Operator Console, select a group in the Groups view.
    The OC group can be one of the predefined OC groups (for example, the Unix and Windows groups) in a test environment or in a test group that you created. The OC group should have at least one device.
  2. Select the Monitoring Configuration icon.
    The profile types that apply to the selected group appear.
  3. In the Profiles tab, click '
    +
    ' to add a profile.
    Profile types are displayed alphabetically. Consider configuring the Setup profile types first. You can also view the version of the template in the Template Version column.
  4. (Optional) Select
    Yes
    if you see a dialog asking if you want the probe to be installed. Verify that the probe resides in the local archive of the hub.
  5. If you select a profile type that requires Monitoring Configuration Service to retrieve data from a probe, the
    reference device
    fields appear in the Group Profile Settings section. By default, only devices in the selected group with the required probe installed appear in the Reference Device drop-down list. To add more devices:
    1. Select a reference device. Monitoring Configuration Service retrieves the required data from the probe running on the selected reference device, and the appropriate fields are populated on the profile type.
  6. Configure the remaining monitoring settings.
  7. Create the configuration profile.
View the profile status information to verify that the configuration profile was successfully applied to all devices in the group. Until the configuration profile is applied, you cannot modify or copy the profile. When the configuration profile is successfully applied, the status changes to Deployed and the lock disappears.
Using Variables in Configuration Profiles
For some configuration profiles, it is more practical to enter a variable instead of a value. For example, when you create an Apache device configuration profile, the IP address of the device is automatically populated in the configuration profile. If you want to copy the device profile to a group of Apache Servers, you can enter the '{device.ipaddress}' variable in the
Hostname
and
URL for HTTP Response
fields.
The following figure shows variables that are entered for the the
Hostname
and
URL for HTTP Response
fields. When you copy the device profile to an OC group, Monitoring Configuration Service resolves the variables with the IP address of each server when it deploys the configuration profile to the member devices.
Manage Monitoring Configuration Service Using MCS Profile
The variables that you can enter in MCS profile types are:
  • device.name
  • device.ipaddress
  • device.origin
  • device.os_type
  • device.usertag1
  • device.usertag2
These variables are also supported with Operator Console.
Verify Overlapping Devices Are Managed by the Same UIM Account
If a device is a member of two or more OC groups, ensure that the groups are managed by the
same
UIM account. This allows users who are members of the UIM account to see the configuration profiles applied to the overlapping device and any future configuration changes.
When the same device is in two or more OC groups that are managed by
different
UIM accounts, users in each account can concurrently configure and manage configuration profiles. However, users in one account cannot see the changes being made by users in another account until the changes are applied to the overlapping device. Changes that are made by users in one account could overwrite changes that are made by users in another account. This creates a confusing situation and should be avoided. See Using Groups and Accounts with Monitoring Configuration Service for more information.
View Profile Details Information
After you create or modify a configuration profile, you can view the profile details information. You can use this information to determine if a configuration profile was successfully applied to target devices. This detailed information also helps you take informed decisions.
Follow these steps:
  1. In OC, navigate to the page that lists the created MCS profiles.
  2. Locate the
    Actions
    column.
  3. Click the profile details icon (under Actions) for the required profile. A dialog with required profile details opens:
  4. The profile details dialog displays the following information:
    1. Status:
      Displays the state of the configuration profile that was deployed.
    2. Created:
      Displays the day, date, and time the configuration profile was created.
    3. Last updated:
      Displays the day, date, and time the configuration profile was previously modified.
    4. Last deployed:
      Displays the day, date, and time the configuration profile was previously applied to target devices.
    5. Profile origin:
      Indicates how the configuration profile was created. A user can create a profile or a group profile can be applied to a device. For a group, the Profile Origin appears as 'locally'. For a device, if the configuration was created at the device level before a group profile was applied, the Profile Origin appears as 'locally'. Once a group profile is applied to a device, the Profile Origin changes to 'group profile'.
    6. Derived from Group:
      Specifies whether a configuration profile was copied.
    7. Last Audit message:
      Displays the last message added to the audit log. For example, an initial message might be generated after the current version of a profile is applied. This message is not displayed. The second message (generated when the profile is reconciled) is the last audit message that appears in this field.
    8. Profile Id:
      Displays a unique ID that is automatically assigned to each configuration profile when it is created.
    9. Created by
      : Displays an identifier of who configured the original configuration profile.
    10. Last updated by:
      Displays an identifier of who updated the configuration profile.
    11. Last reconciled:
      Displays the latest day, date, and time the configuration profile was reconciled.
    12. Template version:
      Displays the version of the probe template that was used to create a profile.
    13. Retry count:
      Displays the number of times the MCS tries to deploy the profile.
  5. Review the information.
Monitoring Configuration Service and Probe Upgrade
MCS does not automatically upgrade probes when a new probe version is available. For example, if you:
  1. Deploy an older version of the cdm probe (cdm v4.78).
  2. Configure the cdm probe.
  3. Open MCS and apply the
    Disk(s)
    template.
MCS does not prompt you to install the latest version of the cdm probe, so you must deploy it manually. You can use the
upgrade_probe_to_eligible_robots
callback to deploy a new probe version to all applicable robots at the same time. For more information, see Simultaneous Deployment of a Probe on Applicable Robots.
Simultaneous Deployment of a Probe on Applicable Robots
MCS provides a callback that lets you deploy a probe to all applicable robots at the same time. This ability is helpful in situations where you have deployed a specific probe version on certain robots. Now, when a new version of a probe becomes available, you do not want to manually deploy the new probe version on each robot. You want an automated mechanism that gives you an option to deploy the probe version on the required robots.
Follow these steps:
  1. Verify that the local archive includes the appropriate version of the probe that you want to deploy.
  2. Open the probe utility for mon_config_service.
  3. Select
    upgrade_probe_to_eligible_robots
    and specify the value for the following parameters:
    • probe_name
      Specifies the name of the probe that you want to deploy. For example,
      cdm
      .
    • probe_version
      Specifies the version of the probe that you want to deploy. For example,
      1.2
      .
    • (Optional) computer_system_ids
      Specifies the robots (robot_csId) on which you want to deploy the probe version. Enter the appropriate robot_csId value in this field. You can use comma-separated values; for example,
      1,2,4
      .
      If you do not provide any value, the callback deploys the new probe version on all the robots where the existing probe version is not the same as the new version.
    When you run this callback, it deploys the required probe version on all the specified robots. You do not need to manually deploy it on each individual robot.
  4. Execute the callback.
    The specified probe version is deployed to all the required robots.
  5. Use the
    get_robots_not_having_probe
    callback to verify whether all required robots have been updated with the requested probe version. Select
    get_robots_not_having_probe
    and specify the value for the following parameters:
    • probe_name
      Specifies the name of the probe for which you want to find out the robots on which this probe is not deployed. For example,
      cdm
      .
    • probe_version
      Specifies the version of the probe for which you want to find out the robots on which this probe version is not deployed. For example,
      1.2
      .
  6. Execute the callback.
  7. When you run this callback, it lists all the robots where the specified probe version is not deployed.
You have successfully deployed a probe on all the required robots.
Get Devices Not Having Group Profile Deployed
The get_devices_not_having_group_profile_deployed callback lets you get a list of devices that do not have a specified group profile deployed on them.
Follow these steps:
  1. Open the probe utility for mon_config_service.
  2. Select
    get_devices_not_having_group_profile_deployed
    and specify the list of group profile IDs.
  3. Execute the callback.
    All the devices that do not have specified group profile deployed on them are displayed.
Copy Configuration Profiles for Consistent Monitoring
Copying configuration profiles reduces the time that it takes you to configure monitoring for your environment. It also provides consistent monitoring for groups of target devices.
Always test a configuration profile before you copy it. Confirm that the QoS data and alarms that are emitted by the probe are what you expect. When configuration profiles are fully tested, you can copy the configuration to any group or device with a robot. If you later want to make changes, you can copy the group configuration profiles back to a 'test' device.
The system prohibits you from copying invalid targets. In the following scenarios, the system prevents you from selecting invalid targets:
  • Redundant copy: You cannot select the copy source as a target.
    If you attempt to perform a duplicate copy operation, you receive a message indicating that the copy operation resulted in no changes.
  • Different Operating Systems: The copy source and targets should have the same operating system.
  • No robot deployed: You can only copy or apply configuration profiles to devices that have deployed robots.
When you copy a configuration profile to a group, the configuration is applied to the devices in the group. The group configuration profile for the target group is independent, meaning there is no link to the copy source. All device configuration profiles in the target group correctly show in the profile status that configuration is derived from the group profile.
You can temporarily change configuration settings that are derived from a group profile for any device in a group. These device-level changes are overridden only for the device. You can copy overridden device configuration profiles to any device or group in your environment
Copy Tested Configuration Profiles
When configuration profiles are fully tested, you can copy the profiles to devices or groups. Copy only applicable configuration profiles to target groups or devices. For example, the
Apache
or
CPU Monitor
configuration profiles are applicable for any device or group. The
Event Log Exclude
or
Windows Services
configuration profiles apply only to Microsoft Windows devices or groups of Windows devices.
If you inadvertently copy a configuration profile that does not apply to a target group or device, the profile is copied to the target. However, the configuration profile is not applied to the group or device. Delete the profile from the target group or device. See Delete Monitoring Profiles for information about deleting profiles.
For detailed information about the copy function and user scenarios, see How to Copy and Apply Profiles in MCS. The following screenshot shows the location where you can find the copy profile icon (first icon under the Actions column):
In UIM 20.3.0, Filter and Activate Filter options have been removed from the monitoring configurations of the MCS templates. You can use the normal drop-down to select the values without any filtering conditions on the values by scrolling the drop-down list.
When you copy a configuration profile to a group, the configuration profile is applied to all devices in the selected group. The copied configuration profile overwrites any existing configuration settings.
When you copy a configuration profile to another device, the configuration profile is only applied to the selected device. If the copy target is a device with a group-level configuration previously applied, any settings on the copied profile override any group settings.
If a probe license expires after configuration profiles are applied, the probe continues to monitor the device and to emit QoS data and alarms.
Profile Types That Allow Multiple Configuration Profiles
Many profile types are restricted to one configuration profile. However, some profile types let you create multiple configuration profiles. Some of the profile types that support multiple profiles are:
  • Log Monitoring
    - Create a configuration profile for each log file, web page, message in the queue, or command output you want to monitor. For each log monitoring configuration profile, you can create a sub-profile for exclude rules, exit codes, format rules, and watcher rules to filter what you want to monitor.
  • Processes
    - Create a configuration profile for each process you want to monitor on a host operating system.
  • Disk(s)
    - Create a configuration profile for each disk or file system you want to monitor.
Follow these steps:
  1. On the Monitoring Config, click '
    +
    ' to add a profile.
  2. (Optional) Select the
    Active
    option to make the profile active.
  3. Enter a unique profile name.
  4. Configure monitoring settings.
    Example:
    Select the Log Monitoring profile type and configure the general log monitoring settings. Then configure the desired Rules profiles. When
    Generate metrics
    and
    Generate alarms
    are enabled, the probe generates QoS metrics and alarms when the content of a monitored log matches the configured exclude rules, exit codes, format rules, or watcher rules profiles.
  5. Create this profile.
Create a Log Monitoring Profile
The Log Monitoring profile type lets you create an initial profile and one or more Rules sub-profiles. After you create a new Log Monitoring configuration profile, the Exclude Rules, Exit Code Monitoring, Format Rules, and Watcher Rules sub-profiles appear. Configure the desired log monitoring rules.
When you create device log monitoring configuration profiles, you can continue to modify the device configuration settings and add or delete rules at any time. This configuration profile is applied only to the selected device. The same holds true for group configuration profiles.
After group log monitoring configuration profiles are applied to devices in the group, you can override the group configuration for a selected device. There are two ways to do this:
  • Modify a
    few
    configuration settings:
    Select a device log monitoring profile or one of the associated rules sub-profiles. Modify configured settings to override the group settings for a device. The configuration changes are applied only to the selected device. An * (asterisk) appears for each setting override. You can revert device overrides back to the group configuration settings by using the Revert arrow. However, you cannot delete the device profiles or sub-profiles. And you cannot add or delete sub-profiles.
    In UIM 20.3.0, you cannot revert device overrides back to the group configuration settings.
  • Modify several configuration settings and add or remove rules:
    Select the desired device log monitoring profile. Clear the
    Active
    option to deactivate the configuration profile for the selected device, and then save the change. For the selected device, create a replacement device log monitoring configuration profile and add rules sub-profiles. At the device level, you can continue to modify device configuration settings and add or remove rules sub-profiles for this new device configuration profile. Group configuration changes are not applied to the new device configuration profile. However, group configuration changes are applied to the deactivated device configuration profile, although changes do not affect log monitoring because the device profile is deactivated.
If you are using a MySQL database, all sub-profile names must be unique across all monitoring profiles. If you attempt to create a sub-profile with a name that is already in use, an error stating that a duplicate name profile already exists. The system prevents you from creating the new sub-profile with a duplicate name.
Modify Configuration Profiles
After configuration profiles are applied to a selected device or a group of devices, you can modify the configuration. Any modifications to a group configuration profile are applied to all devices in the group. Any changes to a device configuration profile are applied
only
to the selected device. The order in which configuration profiles are applied to devices determines if configuration settings are
applied
,
overwritten
, or
overridden
.
Group Profile Applied
When you configure group configuration profiles or copy a configuration profile to a group, the group configuration is
applied
to all devices in the group. If this is the first time the group configuration is applied to the group, the group configuration
overwrites
any device configuration settings.
After group configuration profiles are applied, you cannot delete profiles at the device level because device configurations are now derived from the group profile. The delete (trash) icon no longer appears next to the configured profile name at the device level. You can, however, delete group configuration profiles.
If you inadvertently delete a OC group, the group profiles and any overriding device configuration are removed from devices in the group. If a device is a member of other groups, active group profiles are applied to the device according to the Group Profile Priority (or precedence) assigned to group profiles. The group profile with the highest priority number is applied to the devices in the group.
Override Group Configuration Settings - Temporary Configuration Changes for Selected Devices
After group profiles are applied, you can temporarily
override
group configuration settings for a specific device in the group. You might do this while troubleshooting an issue with a specific device. Overriding group configuration settings lets you adjust monitoring settings to generate more reported data only for the selected device. For example, you might select more QoS options or you might adjust thresholds to receive more alarms.
When you override a group configuration setting, an * (asterisk) appears next to a field name to denote that a setting differs from the group configuration. A
Revert
arrow appears to the right of the profile name. Use the Revert arrow to return the device configuration overrides to the group configuration profile settings. After the revert action completes, any future group configuration profile changes are applied to this device.
Modify Group Configuration when Device Overrides Exist
After group configuration profiles are applied to devices in a group, device configuration is derived from the group profile. When group configuration overrides are made on the device level, the override values are applied only to the selected device. Future group configuration changes are not applied to overridden fields, although they are applied to device settings that do not have override values.
Delete Monitoring Profiles
You can delete configuration profiles for devices or OC groups when your monitoring requirements change. The system lets you delete a device or group profile one at a time. Deleting a group profile removes the configuration from all devices in a group.
While the delete action is in progress, the affected profiles are locked. When Monitoring Configuration Service removes the configuration from the appropriate devices, the associated probe stops emitting alarms and QoS data.
After profiles are deleted, the Profile Types that are displayed on the
Profiles
tab are reordered. The profile types that had profiles removed are moved to the lower portion of the list of profile types. Profile types that can have multiple configuration profiles are only redistributed within the list of profile types after all profiles have been removed.
Delete a Group Profile
You can delete group configuration profiles as long as the profiles are not locked. The delete process removes the selected group profile from all devices in the group, including device profiles that override the group profile.
Delete a Device Profile
You cannot delete device profiles that are derived from group profiles. When a device profile is derived from a group profile, the delete (trash) icon next to the device profile name is replaced by the Revert arrow. Use the Revert arrow to reapply the group profile and remove device overrides.
Note:
If a target device is unreachable and the retry attempts are exceeded, the configuration profile remains unchanged.
Delete Configuration Profiles
Follow these steps:
  1. Navigate to the appropriate device or group.
  2. Click the Monitoring Config icon to display the list of created MCS profiles.
  3. Locate the profile that you want to delete, and follow one of the methods to delete a profile:
    • Locate the
      Actions
      column and click the delete profile icon (trash) for the required profile:
    • Click the required MCS profile to navigate to the profiles page and use the delete (trash) icon that is displayed in the top-right menu to remove the configuration profile:
  4. Select
    Yes
    on the Delete Confirmation dialog.
    Select
    No
    to cancel the delete request.
While the delete action is taking place, the profile remains visible on the
Profiles
tab but is locked. It can take some time to remove configuration profiles.
In-Context Linking of Profiles to MCS Deployment Dashboard
The MCS Deployment Overview tab provides an in-context linking of the profiles to MCS Deployment Dashboard. You can access this tab through the same Monitoring Config icon (gear icon) that you use to access the Profiles and Alarm Policies tabs.
Follow these steps:
  1. Click the Monitoring Config icon in the top-right menu.
  2. Locate the
    MCS Deployment Overview
    tab next to the
    Alarm Policies
    tab.
  3. Click the
    MCS Deployment Overview
    tab.
  4. Review the information in the
    View By Groups
    tab and
    View By Devices
    tab, as required.
For-Each Profiles
The For-Each profiles feature is available in the Profiles section of the Monitoring Config in the Operator Console. For-Each functionality supports the Bulk deployment of the profiles at a group level based on custom attribute for each of the devices available in SSRV2DeviceCustomAttribute table. Using this feature, you can create For-Each profile at a group level. While creating the profile, you need to specify on which custom attribute you want to iterate over.
If a device in a group have one instance of Oracle, on another device in the same group have 2 instances of Oracle and so on. In this case, you need to select the Oracle device instance (device.custom.oracleInstance) variable, and can create a profile for every instance of Oracle on the device in the group. If a device has 10 instances, it will create 10 profiles, if a device has 1 instance it will create 1 profile and so on.
Process to use For-Each profiles
The following steps are needed for using the For-Each feature
  1. Register a Custom attribute for a device in database on which the values can be iterated to create profile should be present.
    Device custom attributes can be present in ssrv2devicecustomattribute, and ssrv2devicecustomattrvalue tables.
  2. If the Device custom attributes are not present, they can be created using manual sql scripts or uimapi (http://<uimserver>/uimapi) under DeviceOperations (/PUT /deviceoperations/{identifier}). Sample device payload to insert with custom attributes is given below as an example which can be executed through UIMAPI.
    1. Perform GET API call to get the device payload using name
    2. Modify the payload and add the custom attribute elements. Sample payload is shown below:
      <?xml version="1.0" encoding="UTF-8" standalone="yes"?> <device> <cs_id>1</cs_id> <device_id>1</device_id> <csdev_id>D86221456EEA5CF0ABEE4A804860767FF</csdev_id> <name>pp671588-win1</name> <status>modified</status> <custom1>device.name</custom1> <origin>pp671588-win1_hub</origin> <os_type>Windows</os_type> <nimbus_type>2</nimbus_type> <ip>10.17.165.209</ip> <cs_type>A</cs_type> <customattribute> <name>custom.instance</name> <scope>default</scope> <value>4</value> <value>D:\testdr</value> <encrypted>true</encrypted> </customattribute> <customattribute> <name>custom.pandu.instance</name> <scope>default</scope> <value>5</value> <value>E:\testdr</value> <encrypted>true</encrypted> </customattribute> <customattribute> <name>device.usertag1</name> <scope>default</scope> <encrypted>true</encrypted> <modified>0</modified> </customattribute> <customattribute> <name>device.usertag2</name> <scope>default</scope> <encrypted>true</encrypted> <modified>0</modified> </customattribute> <customattribute> <name>device.origin</name> <scope>default</scope> <value>pp671588-win1_hub</value> <encrypted>true</encrypted> <modified>0</modified> </customattribute> <customattribute> <name>device.ipaddress</name> <scope>default</scope> <value>10.17.165.209</value> <encrypted>true</encrypted> <modified>0</modified> </customattribute> <customattribute> <name>device.name</name> <scope>default</scope> <value>pp671588-win1</value> <encrypted>true</encrypted> <modified>0</modified> </customattribute> <customattribute> <name>device.os_type</name> <scope>default</scope> <value>Windows</value> <encrypted>true</encrypted> <modified>0</modified> </customattribute> <deviceattribute> <name>Origin</name> <scope>default</scope> <value>pp671588-win1_hub</value> </deviceattribute> <deviceattribute> <name>RobotInstanceId</name> <scope>default</scope> <value>D86221456EEA5CF0ABEE4A804860767FF</value> </deviceattribute> <deviceattribute> <name>DisplayAlias</name> <scope>default</scope> <value>pp671588-win1</value> </deviceattribute> <deviceattribute> <name>PrimaryIPV4Address</name> <scope>default</scope> <value>10.17.165.209</value> </deviceattribute> <deviceattribute> <name>typeName</name> <scope>default</scope> <value>ComputerSystem</value> </deviceattribute> <deviceattribute> <name>PrimaryRole</name> <scope>default</scope> <value>Host</value> </deviceattribute> <deviceattribute> <name>Roles</name> <scope>default</scope> <value>Device</value> <value>Host</value> </deviceattribute> <deviceattribute> <name>label</name> <scope>default</scope> <value>pp671588-win1</value> </deviceattribute> <deviceattribute> <name>PrimaryOSType</name> <scope>default</scope> <value>WindowsServer-2012-R2</value> </deviceattribute> <deviceattribute> <name>RobotName</name> <scope>default</scope> <value>pp671588-win1</value> </deviceattribute> <deviceattribute> <name>CorrelationNames</name> <scope>default</scope> <value>pp671588-win1</value> </deviceattribute> <deviceattribute> <name>DisplayName</name> <scope>default</scope> <value>pp671588-win1</value> </deviceattribute> <deviceattribute> <name>CorrelationId</name> <scope>default</scope> <value>D86221456EEA5CF0ABEE4A804860767FF</value> </deviceattribute> <deviceattribute> <name>OSDescription</name> <scope>default</scope> <value>Service Pack 0 Build 9600</value> </deviceattribute> <deviceattribute> <name>PrimaryOSVersion</name> <scope>default</scope> <value>6.3.9600</value> </deviceattribute> <deviceattribute> <name>PrimaryMacAddress</name> <scope>default</scope> <value>00-50-56-8D-E9-0A</value> </deviceattribute> <deviceattribute> <name>RobotVersion</name> <scope>default</scope> <value>9.2</value> </deviceattribute> </device>
  3. Perform PUT operation  /PUT/deviceoperations/{identifier} using the modified payload containing the device custom attributes.
    The device custom attributes and their values are populated in ssrv2devicecustomattribute, ssrv2devicecustomattrvalue tables respectively. For a device, there are three entries in ssrv2devicecustomattribute, ssrv2devicecustomattrvalue tables and monitoring the log files C:\Test\Log1.log, C:\Test\Log2.log, C:\Test\Log3.log, C:\Test\Log4.log, C:\Test\Log5.log, C:\Test\Log6.log. The for-each profile is created for each of the values of log file directories with custom attribute {device.logfilepath} defined in database.
  4. Once For-Each profile is created at group level, the device attribute values selected are iterated to create profiles at device level and alarms are raised matching the threshold.
    1. The below are the operations performed using For-Each profiles.
      1. Monitors all log files on a particular device.
      2. Notifies if “error” string exist in each log file (If "error" is selected while profile creation).
      3. Count of string “error” from the log files.
      4. Alert if the count is greater than the specified values in the Metric Definition as per the defined Alarm severity.
For-Each Profile Creation Example
With this example, you can create a For-Each profile using the logmon template to raise alarms when the text "error" is found in the log files .
  • Click on the Log Monitoring (Enhanced) profile under Monitoring Config of a group and click + icon. Select For-Each deployment as 'yes' .
    "For-Each Value of" specifies the attribute on which the For-Each profile is created.
  • Provide the Profile Name details as FED{foreach-instance}
    In this example, {foreach-instance} is substituted with value of {device.logfilepath} for the device.
  • Click on save after setting the alarm message to match.
  • Create watcher rule in the Enhanced Profile to match the pattern for creating alarm on log file. Search for the string 'error' and configure thresholds.
  • Click on save for creating the For-Each profile at a group level.
  • The profiles are created at device level for each of the custom attributes configured for the device. In this case we will have 6 profiles created as below.
  • The instance variables are substituted at device level for profile name.
  • The alarms are raised once the string "error" is matched in log files.
Considerations
  • For-Each does not create default alarm policies. As a pre-requisite, disable the flag policy_mode_enabled = false in mon_config_service probe under configure/timed section. The thresholds are configured at template level.
  • For-Each profile is not supported at child template level, but sub profiles can be created. For-Each attribute is enabled at group level for parent templates having maximum profile count as > 1.
  • For-Each flag is visible in the UI for those templates which do not have parent template. Maximum profiles that can be created are more than 1.