R12.1 JA-2025July15

Main Components of Diagnosis

When you add a diagnosis to a NI, you can define various diagnosis actions to make the NI more flexible and verify the network design more accurately.

Table/Paragraph/Collector Variable

A variable can be a single variable such as $state or a table (paragraph, collector). For the table/paragraph/collector variable, you can add the Loop node for the system to loop through each table's row. Take the OSPF neighbor table as an example. There are four lines of neighbor information in the CLI result (the blue rows on the left). The diagnosis execution will determine whether the state contains full line by line (four lines in total).

You can also loop a list variable. See List Variable for more details.

Different Variable Types

Different types of variables have various operations such as Equals, Does not equal, Contains, etc. Compound variables and compound tables can be used in diagnosis definition as well.

Variable TypeExample
String
Note: For detailed description for the Compare Lines, see Appendix.
Int/Float 

Different Data Source

For each variable defined in the diagnosis, you can select its data sources:
 

  • Current: the value of this execution result of the NI .
  • Baseline: the baseline data.
  • Last: the NI will be executed twice and compare the current data with the last data.

The following diagnosis compares the current memory_usage with the baseline memory_usage:

Check Device Pair

You can compare the variables from the different devices. The following compares Mgmt_IP from two neighbor devices.

Use Compound Condition

You can have multiple simple conditions and combine them into a Boolean expression (and/or).
 

 Appendix: Diagnosis Operators

Variable Type
Corresponding Operator
Description
Sample


String
Equals
If the text of the left string variable matches the text of the right string variable, this result is True.
state Equals FULL
Does not equal
If the text of the left string variable does not match the text of the right string variable, this result is True.
state Does not equal FULL
Contains
If the text of the left string variable contains the text of the right string variable, this result is True.
Left:
10.8.1.49
10.11.11.11
10.8.8.8

Right:
10.8.1.49
Does not contain
If the text of the left string variable does not contain the text of the right string variable, this result is True.
Left:
10.11.11.11
10.8.8.8

Right:
10.8.1.49
Is empty
If the text of the left string variable is null,  this result is True.
neighbor_id Is empty
Is not empty
If the text of the left string variable is not null,  this result is True.
neighbor_id Is not empty
Subnet contains

If the text of the left string variable (IPv4 or IPv6) contains the text of the right string variable (IPv4 or IPv6), this result is True.

“Subnet contains” expresses the containment relationship.

10.10.0.0/16 Subnet contains 10.10.5.26
In subnet
“In subnet” expresses affiliation, which is contrary to “Subnet contains”.
10.10.5.26 In subnet 10.10.0.0/16
Match pattern
If the text of the left string variable matches the golden baseline with the format {$var}, {$_dummy}, or enmu in ADT of the right string variable, this result is True.

Left:

Enable password 234
Enable secret 45 access-list 20
No ip domain lookup

Right 1:

Enable password {$_dummy}
Enable secret {$_dummy) access-list {$_dummy}
No ip domain lookup

Right 2:

Enable password {$_dummy}
Enable secret {$var1 = 24|46|47} access-list {$var2 = 20|30}
No ip domain lookup


Int/Float
Equals
If the text of the left number variable equals the text of the right number variable, this result is True.
increasing_error Equals 3
Does not equal
If the text of the left number variable does not equal the text of the right number variable, this result is True.
increasing_error Does not equal 3
Less than
If the text of the left number variable is less than the text of the right number variable, this result is True.
increasing_error Less than 3
Greater than
If the text of the left number variable is more than the text of the right number variable, this result is True.
increasing_error Greater than 3
Less or equal
If the text of the left number variable is less than or equal the text of the right number variable, this result is True.
increasing_error Less or equal 3
Greater or equal
If the text of the left number variable is more than or equal the text of the right number variable, this result is True.
increasing_error Greater or equal 3
In range
If the text of the left number variable is in the range of the text of the right number variable, this result is True.
increasing_error In range [1, 6]
Is empty
If the text of the left number variable is null,  this result is True.
increasing_error Is empty
Is not emprt
If the text of the left number variable is not null,  this result is True.
increasing_error Is not empty