Previous 6.4 Thresholds Next

6.4.5 Creating thresholds from templates

Creating thresholds with the help of a template enables the creation of more thresholds, even for the same measurement. First, the threshold template needs to be selected. Then the attributes (type, e-mail, …) stored in the template and the expression defined in the template appear.

Figure 51. Creating thresholds from template I.

 

As shown in the figure above, when inserting thresholds based on a template, it is not possible or necessary to edit the expression manually. Instead, the concrete expression of the threshold to be created can be defined by filling out the fields in the Variables row. Even several variables can exist in the expression, which are named as Variable1, Variable2, … and are identified with their sequence number in the Variables row. The expression can contain INPUT1, INPUT2, … parts too, in which case the user has to specify these values before the threshold is created.

 

The figure above can vary depending on certain fields of the template and the starting page (editing started from the menu or equipment page) as follows:

·       If threshold creation was started from the equipment configuration page, then obviously neither the Equipment name filter nor the Measurements within the same equipment item appear on the page. The later can be used when we are creating threshold using a template on the Threshold => Configuration page and the template contains more than one measurement. If the checkbox is checked then PVSR will not select measurements belonging to different equipments. For example if the threshold expression uses the Uptime and Availability measurements then this option tells PVSR that it shouldn't select the Uptime measurement on equipment X and the Availability measurement on equipment Y.

·       If more variables exist in the expression, then they appear in separate rows within the Variables row.

·       If one variable has many INPUT fields, the more input fields appear in the Variables row. However, if no INPUT field belongs to a certain variable, then no input field appears.

·       If the threshold level was defined in the template (Critical, Major, …) or no variable has an INPUT field, then no extra INPUT field is displayed for the individual threshold level, and a threshold level pull-down list is displayed instead

 

The “Measurements with the same description” option is similar to the “Measurements within the same equipment” but it allows additional filtering when selecting measurements for a threshold template, so this option is also available when the threshold configuration was started from the equipment configuration page. If it is checked then PVSR will only select measurements if their description queried from the equipment is the same (for example the name of a tablespace for an Oracle tablespace usage measurement) or if they do not have any description at all. So we can also create and use a threshold template like:

            Raise an alarm if the Oracle tablespace usage > x% or

when the Oracle tablespace free space is < yM

because with the option selected PVSR will not select measurements of different tablespaces for the same threshold.

 

On the figure below, the case is shown where there are two variables in the expression (traffic and availability). For the in and out traffic, different input values can be specified, whereas the availability value is 50 (%) and the Critical threshold level is defined in the template.

Figure 52. Creating thresholds from template II.

 

As the two figures show, the user can overwrite the values given in the template before the threshold is created. The usage of the input fields in the Variables row depends on whether it is a filter or an INPUT field:

·       Filter field: allows you to filter for the name of the equipment and measurement. There are two types of filters:

    • “Like” expression: the _ and ? characters match an arbitrary single letter, while % and * match an arbitrary string
    • “Regular” expression: the value must be in the format “r=XXX”, where XXX is interpreted as a regular expression

Based on the filter expression the application filters the possible list of measurements and offers thresholds to be created for the results. An important rule is that if a template has more than one variable, then the system will show the thresholds only if there is a single variable to which the system finds more than one measurement. For example, in the case above, if the system finds several traffic measurements, and only one round trip time measurement, then it shows the thresholds to be created. However, if it finds several round trip time measurements too, it forces the user with an error message to further narrow down the number of possible measurements using the filter options.

·       INPUT field: according to the measurement unit of the variable, always a numerical value (K, M and G can be used) or minus 1 must be written here and this value is substituted in the concrete threshold (minus 1 means that the measurement was unsuccessful). If the threshold level is defined in the template, every INPUT value must be filled in for successful creation. However, if the threshold level is not defined there, then only those thresholds are created to which all INPUTS are given. Therefore, for at least one INPUT all values must be defined for successful creation.

 

After entering each field, the list of thresholds to be created can be viewed after clicking on the OK button. The application automatically filters out those thresholds which already exist in the database. The application first checks whether a threshold with the same name already exists. If not then it checks whether a threshold with the same expression already exists. It treats two expression as the same if the differences between them are only white-space characters. For example it treats "X>5" and "X     >    5" as the same expression, however "5<X" is not the same as these two expressions.

 

Before the actual creation this list can be modified by selecting the ones that should be created and unselecting the others.

Figure 53. List of thresholds to be created

 

Pressing the OK button again, the system creates the selected thresholds. As opposed to the equipment and chart templates, the system remembers if a threshold was created from a template, and also that if during the creation process only the INPUT fields were different. The system uses this information later in different ways:

·       In case of the modification of these kinds of thresholds, it warns the user that a possible template modification later can overwrite the adjusted values (see the part about the editing of Threshold templates)

·       The expression in these thresholds cannot be modified together with the help of the template, but they can be deleted in bulk, and in fact when deleting the template the system automatically offers this (see the part about the editing of Threshold templates)

·       When deleting a threshold, if there is another threshold which was created at the same time, from the same measurement but for a different level, then the deletion of this threshold is also offered. For example, in the case above, when "Nvsw1 Availability < 80% Critical" threshold is deleted, then the system offers the deletion of the "Nvsw1 Availability < 90% Major" threshold as well.