StyleBookで定義された仮想サーバーでアナリティクスを有効にし、アラームを設定する
You can use the operations construct to configure NetScaler Console analytics to collect AppFlow records on all or some of the traffic transactions handled by any virtual server component that is part of a StyleBook. You can also use this construct to configure alarms to get insight into the traffic managed by the virtual server.
次の例は、StyleBookのoperationsセクションを示しています。
operations:
analytics:
-
name: lbvserver-ops
properties:
target: $components.basic-lb-comp
filter: HTTP.REQ.URL.CONTAINS("catalog")
alarms:
-
name: lbvserver-alarm
properties:
target: $components.basic-lb-comp
email-profile: $parameters.emailprofile
sms-profile: "MyProdSMS"
rules:
-
metric: "total_requests"
operator: "greaterthan"
value: 25
period-unit: $parameters.period
-
metric: "total_bytes"
operator: "lessthan"
value: 60
period-unit: "day"
The attributes in the analytics section are used to instruct NetScaler Console analytics feature to collect AppFlow records on a virtual server component identified by the target property. You can also optionally specify a filter property that accepts a NetScaler Console policy expression to filter requests for which AppFlow records are collected on the virtual server.
このStyleBookから構成パックが作成されると、NetScaler Consoleのアナリティクス機能は、構成パックの作成プロセスで作成される際に指定された仮想サーバーでAppFlowレコードを収集するように構成されます。
alarmsセクションの属性は、targetプロパティによって識別される仮想サーバーでアラームを生成し、通知を送信するためのしきい値を設定するために使用されます。上記の例では、email-profileおよびSMS-profileプロパティは、通知の送信先を指定するために使用されます。rulesセクションはしきい値を定義します。たとえば、仮想サーバーによって処理される合計リクエストが25を超え、ユーザーによって定義された期間の場合、アラームが設定され、通知が送信されます。「period-unit」は、アラームがトリガーされる頻度を指定します。これは、日、時間、または週の値を取ることができます。
メトリック値をしきい値と比較する際に、次の演算子を使用できます。
-
>の場合、greaterthan -
<の場合、lessthan -
>=の場合、greaterthanequal -
<=の場合、lessthanequal
StyleBookはメトリックにAPI名を使用し、NetScaler ConsoleアナリティクスGUIに表示される名前ではないことに注意してください。
構成パックの一部として作成された仮想サーバーで収集されたデータを表示および分析する方法については、NetScaler Consoleアナリティクスドキュメントを参照してください。