Skip to main content
本繁體中文版使用機器翻譯,譯文僅供參考,若與英文版本牴觸,應以英文版本為準。

更新EMS事件對應、以取代過時ONTAP 的EISO命令

貢獻者

如果您的 EMS 事件對應目前是使用過時的 ONTAP 命令集進行設定 (event destinationevent route)、您應該遵循此程序來更新對應以使用 event filterevent notification`和 `event notification destination 命令集。

步驟
  1. 使用列出系統中的所有事件目的地 event destination show 命令。

    cluster-1::event*> destination show
                                                                             Hide
    Name             Mail Dest.        SNMP Dest.         Syslog Dest.       Params
    ---------------- ----------------- ------------------ ------------------ ------
    allevents        -                 -                  -                  false
    asup             -                 -                  -                  false
    criticals        -                 -                  -                  false
    pager            -                 -                  -                  false
    test             test@xyz.com      -                  -                  false
    traphost         -                 -                  -                  false
    6 entries were displayed.
  2. 針對每個目的地、使用列出對應至目的地的事件 event route show -destinations <destination name> 命令。

    cluster-1::event*> route show -destinations test
                                                                   Freq    Time
    Message                          Severity       Destinations   Threshd Threshd
    -------------------------------- -------------- -------------- ------- -------
    raid.aggr.autoGrow.abort         NOTICE         test           0       0
    raid.aggr.autoGrow.success       NOTICE         test           0       0
    raid.aggr.lock.conflict          INFORMATIONAL  test           0       0
    raid.aggr.log.CP.count           DEBUG          test           0       0
    4 entries were displayed.
  3. 建立對應的 event filter 其中包括所有這些事件子集。 例如、如果您只想要包含 raid.aggr.* 事件、請使用萬用字元 message-name 建立篩選器時的參數。您也可以為單一事件建立篩選器。

    註 您最多可以建立50個事件篩選器。
    cluster-1::event*> filter create -filter-name test_events
    
    cluster-1::event*> filter rule add -filter-name test_events -type include -message-name raid.aggr.*
    
    cluster-1::event*> filter show -filter-name test_events
    Filter Name Rule     Rule      Message Name           SNMP Trap Type  Severity
                Position Type
    ----------- -------- --------- ---------------------- --------------- --------
    test_events
                1        include   raid.aggr.*            *               *
                2        exclude   *                      *               *
    2 entries were displayed.
  4. 建立 event notification destination 針對每個 event destination 端點(例如 SMTP/SNMP/Syslog )

    cluster-1::event*> notification destination create -name dest1 -email test@xyz.com
    
    cluster-1::event*> notification destination show
    Name            Type        Destination
    --------------  ----------  ---------------------
    dest1           email       test@xyz.com (via "localhost" from "admin@localhost", configured in "event config")
    snmp-traphost   snmp        - (from "system snmp traphost")
    2 entries were displayed.
  5. 將事件篩選器對應至事件通知目的地、以建立事件通知。

    cluster-1::event*> notification create -filter-name asup_events -destinations dest1
    
    cluster-1::event*> notification show
    ID   Filter Name                     Destinations
    ---- ------------------------------  -----------------
    1    default-trap-events             snmp-traphost
    2    asup_events                     dest1
    2 entries were displayed.
  6. 針對每個項目重複步驟 1-5 event destination 那有 event route 對應:

    註 路由至 SNMP 目的地的事件應對應至 snmp-traphost 事件通知目的地。SNMP traphost目的地使用系統設定的SNMP traphost。
    cluster-1::event*> system snmp traphost add 10.234.166.135
    
    cluster-1::event*> system snmp traphost show
            scspr2410142014.gdl.englab.netapp.com (scspr2410142014.gdl.englab.netapp.com) <10.234.166.135>    Community: public
    
    cluster-1::event*> notification destination show -name snmp-traphost
    
                    Destination Name: snmp-traphost
                 Type of Destination: snmp
                         Destination: 10.234.166.135 (from "system snmp traphost")
     Server CA Certificates Present?: -
       Client Certificate Issuing CA: -
    Client Certificate Serial Number: -
           Client Certificate Valid?: -