ONTAP 9.12.1 commands

50←PDF
  • ONTAP 9.12.1 commands(CA08871-263en.pdf)
  • event filter test

    Test an event filter

    Availability: This command is available to cluster administrators at the admin privilege level.

    Description

    The event filter test command is used to test an event filter. When specified with a message name, the command displays whether the message name is included or excluded from the filter. When specified without a message name, the command displays the number of events from the catalog that match the filter. For more information, see the event filter create command.

    Parameters

    -filter-name <text> - Filter Name

    Use this mandatory parameter to specify the name of the event filter to test.

    [-message-name <Message Name>] - Message Name

    Use this optional parameter to specify the message name of the event to test against the filter.

    Examples

    The following example tests an event filter named err-wafl-no-scan-but-clone:

    cluster1::> event filter show
    Filter Name Rule     Rule      Message Name           SNMP Trap Type  Severity
                Position Type
    ----------- -------- --------- ---------------------- --------------- --------
    default-trap-events
                1        include   *                      *               EMERGENCY, ALERT
                2        include   *                      Standard, Built-in
                                                                          *
                3        exclude   *                      *               *
    err-wafl-no-scan-but-clone
                1        include   wafl.scan.clone.*      *               *
                2        exclude   wafl.scan.*            *               *
                3        include   wafl.*                 *               EMERGENCY, ALERT, ERROR
                4        exclude   *                      *               *
    important-events
                1        include   *                      *               EMERGENCY, ALERT
                2        include   callhome.*             *               ERROR
                3        exclude   *                      *               *
    no-info-debug-events
                1        include   *                      *               EMERGENCY, ALERT, ERROR, NOTICE
    
    Filter Name Rule     Rule      Message Name           SNMP Trap Type  Severity
                Position Type
    ----------- -------- --------- ---------------------- --------------- --------
    no-info-debug-events
                2        exclude   *                      *               *
    12 entries were displayed.
    
    cluster1::> event filter test -filter-name err-wafl-no-scan-but-clone
    271 events will be included in the given filter.
    
    cluster1::> event filter test -filter-name err-wafl-no-scan-but-clone -message-name wafl.scan.clone.split.cantLock
    The message-name "wafl.scan.clone.split.cantLock" is included in the given filter.
    
    cluster1::> event filter test -filter-name err-wafl-no-scan-but-clone -message-name wafl.scan.layout.cantWrite
    The message-name "wafl.scan.layout.cantWrite" is excluded from the given filter.
    Top of Page