UIM 20.3 - nas 9.31 changes in regular expression matching criteria
search cancel

UIM 20.3 - nas 9.31 changes in regular expression matching criteria


Article ID: 202285


Updated On:


DX Unified Infrastructure Management (Nimsoft / UIM)


Nas 9.31 has introduced some changes in the way strings are matched using Regular Expressions (Regex).

In Versions of NAS < 9.31 the regex was based on string matching, so not strictly following regex. 

From NAS 9.31 the regex patterns must follow the regex rules for matching. 



In NAS version < 9.31 If we want to match for example a subsys id like: (but we do not want to match we could use the following matching string:


sid =*


As seen below: is matched: (this can be verified using F2 validator:

NAS 9.30:


but NOT matched:

NAS 9.30:




This is no longer occurring in NAS 9.31 as  with the regex:


sid =*


Also is matched. 




Release : 20.3

Component : UIM NAS


Change to Pattern matching to Regular Expression starting nas 9.31




•  NAS 9.30 or earlier uses pattern matching

•  NAS 9.31 and later uses REGEX + nas 9.31 has a DEFECT(DE482613)  (that will be fixed in a future rlease) where it matches all alarms if regex pattern error string is configured. For this issue check this KB 


In nas 9.31 the regex matching respects REGEX.


If for example you configure a regex as

sid =*


This will mean that 

""  +  ".*"


".*" Means to match any characters any numbers of time so it is expected that matches. 


This can be verified by validating the matching criteria:

In the nas by pressing F2:


Or on any regex online validator:




If you'd like to match any subsys id like the following:


and so on.. you will have to "escape" the dot (".") to match the exact character:


So modify your regex as below:\.*



with the above mentioned regex, and won't be matched anymore. 


instead and etc., yes, they will be. 




This behaviour is being resolved in NAS 9.32HF1:


nas 9.32 HF1

Solution Document: LU00962

  • Release: 20.3.3
  • Hiper: NO
  • Operating System: MULTI-PLATFORM
  • Status: CONFIRMED
  • Distribution Code: AVAILABLE
  • Opened Date: 04/16/2021
  • Closed Date: 04/16/2021


Applicable for: UIM 20.3 (nas 9.31) and UIM 20.3.3 (nas 9.32)

Issues Fixed:

1. UIM 20.3 - nas 9.31 changes in pattern/regular expression matching behavior

Reason: Prior to nas 9.31 (i.e. nas 9.30 or below), nas supported pattern/regex matching. With nas 9.31 we started supporting regular expressions only.

Resolution: With this hotfix, we provide a configuration parameter which will allow to select either both pattern/regex matching or only regular expressions matching. The below configuration parameter is provided:
Key used:
Configuration - Raw config under setup
UseRegexOnly = no (default, both pattern/regex matching)
             = yes (regex matching only)

Additional details:
- UseRegexOnly = no (default, both pattern/regex matching) 
Behavior similar to nas 9.30 and below

If the pattern is starting and ending with a DELIMITER / (slash), it is treated as a true regular expression. Otherwise, it is treated as a pattern matching as described below.

The pattern matching mimics the below wildcard matching behavior. 
An asterisk (*)  matches one or more occurrences of any character, including no character.
Question mark (?)  represents or matches a single occurrence of any character.
Bracketed characters ([ ])  matches any occurrence of character enclosed in the square brackets.

Additionally, the tokens '/' '(' ')' and '.' in the pattern are treated as same character literally (not as pattern tokens) if they are not within [].

- UseRegexOnly = yes (regex matching only)
The expression is treated as a regular expression that is compliant with PCRE. It would be similar to expressions that can be checked with https://regex101.com/. The expectation is that the user provides only the regular expression without DELIMITER or FLAGS. Internally no flags are set.
For e.g. If you need to provide a regular expression you should not start and end with a delimiter like '/'.

If the regular expression is "file.*txt", you need to directly provide "file.*txt" but NOT "/file.*txt/" where / is a DELIMITER. This regular expression would match strings like "fil.txt", "fileeee.txt", "filxtxt", etc.

Regular expression validator in NAS UI will take only single regular expression as input for validation. Space and comma are NOT considered as seperators for providing multiple expressions.

Steps to apply the patch:
1. Import the zip into the local archive.
2. Deploy the imported package to the robot/hub.

Additional Information

Additionally to the change discussed in this KB, there currently is a defect in the probe where if a regex complication mistake is done, all alarms will be matched. 

If the regex string defined in the NAS contains an invalid REGEX format the nas will log the following: 


              Feb  8 12:06:07:690 [427596] 0 nas: Regex Issue : regex compilation error 
                Feb  8 12:06:07:690 [427596] 0 nas: _corrTriggerMatchAlarmPDS:: Regex Issue - regex compilation error 


And it will match ALL alarms for that rule


If you are facing this issue, please refer to the following KB:

UIM 20.3 - all alarms are matched by Nas auto-operator (AO) using regex