< Home

display ops assistant

Function

The display ops assistant command displays information about Python script assistants.

Format

display ops assistant { current [ verbose ] | history } [ name assistant-name ]

Parameters

Parameter

Description

Value

current

Displays brief information about the current status of Python script assistants.

-

verbose

Displays detailed information about the current status of Python script assistants.

-

history

Displays historical operation records of Python script assistants.

-

name assistant-name

Specifies the name of a Python script assistant, namely, a Python script name for a script assistant.

The value must be the name of a script file for which the script assistant has been configured.

Views

All views

Default Level

3: Management level

Usage Guidelines

You can use this command to check the current status and historical operation record of a Python script assistant, including the Python script assistant name, running status, and execution result. The command can display a maximum of 100 latest Python script assistant records.

Example

# Display brief information about the current status of Python script assistants.

<HUAWEI> display ops assistant current
------------------------------------------------------                          
Assistant                     State          Condition                          
------------------------------------------------------                          
subscribe_cli_sync_1.py       ready          cli                                
user-correlat-10.py           ready          multi                              
------------------------------------------------------ 
Table 1 Description of the display ops assistant current command output

Item

Description

Assistant

Name of a Python script assistant.

State

Current status of the Python script assistant.
  • ready: The Python script assistant is waiting to be triggered.
  • pending: The Python script assistant is waiting to run.
  • waiting: A resident script is waiting to be triggered the second time.
  • running: The Python script assistant is running.
  • shutdown: The Python script assistant stops.
  • suspend: The OPS maintenance assistant function is disabled.

Condition

Triggering condition for a Python script assistant.
  • cli: command line event
  • device: stack status change event
  • iclog: log event
  • ifm: interface statistics collection event event
  • lldp: LLDP neighbor change event
  • multi: complex event
  • timer: timer event
  • trap: trap event
  • URM: routing event

# Display detailed information about the current status of Python script assistants.

<HUAWEI> display ops assistant current verbose
Assistant information                                                           
  Name                          :user-correlat-10.py                            
  State                         :ready                                          
Running statistics                                                              
  Running times                 :0                                              
  Queue size/(free)             :5/(5)                                          
  Skip for queue full           :0                                              
  Skip for delay                :0                                              
  Skip for suppression          :0                                              
Condition information                                                           
  Condition tag                 :cli1                                           
    Condition type              :multi                                          
    Threshold                   :1                                              
    Period (s)                  :0                                              
    Hits in period              :0                                              
  Condition tag                 :cli2                                           
    Condition type              :multi                                          
    Threshold                   :1                                              
    Period (s)                  :0                                              
    Hits in period              :0                                              
  Condition tag                 :cli3                                           
    Condition type              :multi                                          
    Threshold                   :1                                              
    Period (s)                  :0                                              
    Hits in period              :0                                              
  Condition tag                 :cli4                                           
    Condition type              :multi                                          
    Threshold                   :1                                              
    Period (s)                  :0                                              
    Hits in period              :0                                              
  Correlate expression          :((cli1 andnot cli2) and (cli3 andnot cli4))    
  Trigger control                                                               
    Threshold                   :1                                              
    Period (s)                  :30                                             
    Delay (s)                   :0                                              
    Suppress max                :0                                              
    Hits in period              :0   
Table 2 Description of the display ops assistant current verbose command output
Item Description

Assistant information

Information about a Python script assistant.

Name

Name of a Python script assistant.

State

Current status of a Python script assistant.
  • ready: The Python script assistant is waiting to be triggered.
  • pending: The Python script assistant is waiting to run.
  • waiting: A resident script is waiting to be triggered the second time.
  • running: The Python script assistant is running.
  • shutdown: The Python script assistant stops.
  • suspend: The OPS maintenance assistant function is disabled.

Running statistics

Detailed running information about a Python script assistant.

Running times

Number of running times.

Queue size/(free)

Number of buffered Python script assistants. If the number of buffered Python script assistants reaches the maximum value, excessive assistants will be discarded.

Skip for queue full

Number of tasks discarded because the queue is full.

Skip for delay

Number of tasks discarded within the delay.

Skip for suppression

Number of times the triggering of the assistant is suppressed.

Condition information

Condition information about a Python script assistant. The Condition information field is displayed only for a complex event script.

Condition tag

Condition name.

Condition type

Type of triggering condition. The value is multi.

Threshold

Maximum number of times that tasks are executed. The default value is 1.

Period (s)

Detection period, in seconds. The default value is 30.

Hits in period

Number of times the triggering condition is met in the detection period.

Correlate expression

Condition combination mode.

Trigger control

Trigger control.

Delay (s)

Delay in triggering a working task. The default value is 0 seconds.

Suppress max

Maximum number of times working tasks are triggered within the delay. The default value is 0, indicating that working tasks will not be suppressed.

# Display historical operation records of Python script assistants.

<HUAWEI> display ops assistant history
Assistant history information                                                   
  Name                          :subscribe_cli_sync_1.py                        
  Running information                                                           
    Trigger condition           :cli                                            
    Trigger event name          :cli1                                           
    Trigger time                :2017-03-25 19:48:51                            
    Execute start time          :2017-03-25 19:48:51                            
    Execute end time            :2017-03-25 19:48:53                            
    Execute result              :normal 
Table 3 Description of the display ops assistant history command output
Item Description

Assistant history information

Historical information about a Python script assistant.

Name

Name of a Python script assistant.

Running information

Running information about a Python script assistant.

Trigger condition

Triggering condition for a Python script assistant.
  • cli: command line event
  • device: stack status change event
  • iclog: log event
  • ifm: interface statistics collection event event
  • lldp: LLDP neighbor change event
  • multi: complex event
  • timer: timer event
  • trap: trap event
  • URM: routing event

Trigger event name

Trigger event name for a Python script assistant.

Trigger time

Triggering time of a Python script assistant.

Execute start time

Execution time of a Python script assistant.

Execute end time

End time of a Python script assistant.

Execute result

Execution result of a Python script assistant.
  • normal: The script assistant ends normally.
  • abnormal: An exception occurs in the script.
  • userCancel: A user stops the script.
  • duplicate: The script file name conflicts with the database file name.
  • os: The system kills the script process due to a script exception.
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >