Defining users and processes


You can customize a workload definition according to users and processes by configuring user and transaction filters. You can further customize the definition by configuring workload filters, which enables you to include only specific servers, users, and processes in the definition.

You can configure these filters for new and existing workload definitions. For details, see the following topics:

To configure user filters

Configure user filters to customize your workload definition based on user names.

The following video illustrates how to configure a user filter.

For more information about using patterns and regular expressions, see Patterns and regular expressions.

To configure transaction filters

Configure transaction filters to customize your workload definition based on processes.

The following video illustrates how to configure a transaction filter.

For more information about using patterns and regular expressions, see Patterns and regular expressions.

To configure workload filters

Configure workload filters to further customize the workload definition according to servers, user filters, and transaction filters.

The following video illustrates how to configure a workload filter.

Patterns and regular expressions

While configuring a user or transaction filter, you can specify any of these patterns to match a user or process name:

  • An exact complete sequence of characters, such as a complete user name or complete process name or full command
  • A regular expression
  • A substring of a full command. The substring can be a regular expression.

Regular expressions

You can use regular expressions to define users and processes. Regular expressions contain a combination of characters that define a pattern of text to be matched. The following table describes the characters that are commonly used in regular expressions:

Character

Details

Example

Period (.)

A dot represents any single character.

The expression ab. matches aba, abb, ab1, and so on.

Asterisk (*)

An asterisk represents none, one, or more of the preceding characters or regular expressions.

The expression ab* matches a (note that 'b' is allowed to disappear), ab, abb, abbb, and so on.

ab.* matches ab, aba, abab, aba1, abcdefg, and so on. 
Important: This example states the use of .* to match any string. Although * without the preceding period has the similar meaning when matching file names in the shell, you must use both the period and the asterisk (.*)

\

The backslash quotes special and ordinary characters that are specified after it.

The backslash is used to specify a special character, such as dot (.). The following expression is used to select all .csv files:

^*\.csv$

where the backslash indicates that the dot following it is a real dot. It does not indicate any character.

Square brackets [character_set]

A set of characters that are enclosed in square parentheses matches a consecutive range of letters or digits where the first and last characters in the range are specified and separated with a minus sign. For example, [0-9].


The expression [abc] matches all the three character strings that begin with a or b or c.

^

A hat (circumflex) at the beginning of an expression indicates that the match must begin at the start of the string or line. Anywhere else in the expression, it matches itself.

  • The expression ^ab[.]* returns strings that begin with ab.
  • The expression ^..C[.]* returns strings that begin (^) with any two characters and the third character is C.

$

The dollar sign at the end of a regular expression indicates that the match must begin at the end of the string or line. Anywhere else in the expression, it matches itself.

The expression [.]*t$ returns every string that ends with t irrespective of the number or type of characters in the string.

Important

  • The match for user and process patterns occurs only when the entire name is specified. A substring is not matched (except for full commands). Therefore, the use of '^' and '$' to indicate the beginning and end of a string is redundant.
  • The extended regular expressions that are used by the egrep command are not available. 

Pattern matching while specifying processes

A pattern or a regular expression for a transaction filter must include a process name or the full command name that runs the process. The process name is matched exactly. The full command name can match as a substring. If you specify only the process, the full command name is assumed to be .*. If you specify only the command, the process name is assumed to be .*.

  • If a process name contains blank spaces, enclose the process name in quotation marks.
  • If a command name includes spaces for separating options or the command name is specified without the process name, enclose the full command in quotation marks.

Pattern matching examples for UNIX

  • “httpd -c sports\.cfg” (same as .* “httpd -c sports\.cfg” or httpd “httpd -c sports\.cfg”)
  • bgscollect “bgscollect -Z” (process name and full command)
  • ptydaemon /etc/ptydaemon (process name and full command]
  • bgscollect (process name only. Same as bgscollect .*)
  • “bgsanalyze -Z” (full command only. Same as .* “bgsanalyze -Z”)
  • “notes -u accounting” (full command)

Pattern matching examples for Windows

To match a special character, precede it with a backslash.

  • Patrol_Scheduler "C:\\Program Files\\BMC Software\\Patrol3\\BEST1\\NTC\\bgs\\bin\\Patrol_Scheduler\.exe"
  • BGS_SDservice "C:\\Program Files\\BMC Software\\Patrol3\\BEST1\\7\.1\.01\\bgs\\bin\\BGS_SDservice\.exe"
  • sqlservr "C:\\PROGRA~1\\MICROS~4\\MSSQL\$~1\\binn\\sqlservr\.exe -sTEST2" 

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*