Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
en:dpi:dpi_components:dpiui:user_guide:qoe_analytics:triggers_and_notifications:start [2023/07/31 09:43] – [Step 2: Select a data source and metrics] edrudichgmailcom | en:dpi:dpi_components:dpiui:user_guide:qoe_analytics:triggers_and_notifications:start [Unknown date] (current) – removed - external edit (Unknown date) 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== QoE Triggers & Notifications ====== | ||
- | {{indexmenu_n> | ||
- | ===== Purpose of use ===== | ||
- | In the " | ||
- | < | ||
- | |||
- | Let's make the settings using two scenarios as an example: | ||
- | - **Periodic report to track the RTT delay from a subscriber.** \\ The report will show subscribers whose "RTT from subscriber" | ||
- | - **Alert about subscribers being a part of a botnet.**\\ We will set up a table check once a minute every day. Notification will be sent **to your email** as soon as at least one infected subscriber is detected in the table. | ||
- | |||
- | ===== How to create and configure triggers ===== | ||
- | - In the GUI, go to QoE analytics → Triggers and Notification. | ||
- | - Click the + on the Triggers dashboard to add a trigger. This will open the configuration pop-up window. | ||
- | |||
- | It takes 5 steps to create a new trigger. Trigger settings are divided into blocks, you need to fill all of them. | ||
- | |||
- | ==== Step 1. Schedule ==== | ||
- | Fill in the required fields: | ||
- | * Name – choose any unique name for the trigger. | ||
- | * Severity – select the level of importance: information, | ||
- | * Days of the week – on which days of the week the trigger will run. | ||
- | * Check frequency — how often the validation script will be run. For example, if the value “1 min” is set – the check script will be run once a minute on the specified days of the week. | ||
- | * Start and end date and time. **Optional fields.** | ||
- | |||
- | Also in this block there is a switch to enable/ | ||
- | |||
- | <note tip> | ||
- | ==== Step 2: Select a data source and metrics ==== | ||
- | Select a metric and data table. Triggers only work with ready-made tables found in Netflow and Clickstream, | ||
- | |||
- | To create a query, click on the **+** under the block name. | ||
- | * Report – select a table with data from the ready-made reports of the system, which are analyzed. | ||
- | * “Period from” and “-to”. For example, if you need to analyze data for the last 24 hours, set “Period from” – 24 hours, “Period to” – now. | ||
- | |||
- | < | ||
- | |||
- | For each request, you can create a filter where you can set the value of IP host, subscriber login, etc. For example, you can customize the generation of a report or notification for one specific host, if you set the filter like this: | ||
- | {{ : | ||
- | |||
- | <note tip> | ||
- | \\ \\ Example of filling out the block for notification about subscribers with cyber threats. Here you need to select the report “Top infected subscribers with botnet traffic”, it has the required metrics for this trigger. In this case, the data for the last 24 hours will be analyzed.\\ {{: | ||
- | ==== Step 3: Conditions ==== | ||
- | Set conditions – what should happen to the metric to run the trigger. \\ | ||
- | To create a condition, click the **+** below the block name.\\ | ||
- | For each condition, you need to configure the following parameters: | ||
- | * AND/OR relationship – compare with the names of requests for fulfillment of either several conditions at once or at least one of the specified conditions. | ||
- | * Name – select one of the created requests. | ||
- | * Function – select the type of aggregate function to be applied to the values in the condition: | ||
- | * " | ||
- | * " | ||
- | * " | ||
- | * " | ||
- | * " | ||
- | * " | ||
- | * " | ||
- | * " | ||
- | * Combinator – select a non-numeric/ | ||
- | * Series – select the desired metric from the report. | ||
- | * Operator – select: =, !=, >, >=, <, ⇐, between //<color # | ||
- | * Value – assign the required value for the condition. | ||
- | |||
- | <note tip> | ||
- | \\ {{: | ||
- | |||
- | ==== Step 4: Error handling ==== | ||
- | Set the trigger behavior when errors occur.\\ | ||
- | Select one of the values in the “If there is no data” and “If there is a runtime error or timeout” fields: | ||
- | * “Notification” – there is the condition specified in the trigger. | ||
- | * “No data” – no data is found when processing the reports set in the trigger. | ||
- | * “Save last condition” – no action needed. | ||
- | * “Ok” – the conditions set in the trigger did not work, everything is fine, and no actions needed. | ||
- | |||
- | <note tip> | ||
- | |||
- | ==== Step 5: Actions ==== | ||
- | Setting up an action will allow you to receive a message to E-mail or Telegram in case of triggering. \\ | ||
- | To create an action, press **+** under the block name. \\ | ||
- | To delete an action, press **✕** next to the action name. | ||
- | |||
- | === Telegram === | ||
- | **Step 1: Register your bot via https:// | ||
- | |||
- | - Start BotFather with the ''/ | ||
- | - Type ''/ | ||
- | - Enter the name of the bot.\\ {{: | ||
- | - Enter a unique '' | ||
- | - Copy the HTTP API access token from the bot registration message, it looks like this: '' | ||
- | - Paste the copied token into the GUI settings (Administrator → GUI Configuration → Telegram Settings → Telegram bot API token). \\ {{: | ||
- | |||
- | **Step 2: Get a chat ID for your personal Telegram account via https:// | ||
- | |||
- | <note important> | ||
- | |||
- | - Start Telegram Bot Raw with the ''/ | ||
- | - Copy the '' | ||
- | " | ||
- | " | ||
- | " | ||
- | " | ||
- | " | ||
- | },</ | ||
- | |||
- | **Step 3: Connect Telegram to the configured trigger** | ||
- | |||
- | Add the ID from step 2 to the Telegram action in the "Chat ID" field.\\ | ||
- | {{: | ||
- | |||
- | === E-Mail === | ||
- | Creates a notification and sends it to the specified e-mail address.\\ | ||
- | - If the “Message” field is not filled in – click on the “Set default template” button (1) to fill the action fields with default values. If necessary, all values can be edited. | ||
- | - If you click on the “Template parameters” button (2), it will open a menu with identifiers that can be used to compose the message. | ||
- | |||
- | {{: | ||
- | |||
- | For E-mail actions to work, you need to configure SMTP. Go to Administrator → GUI Configuration, | ||
- | |||
- | === GUI Notifications === | ||
- | Notification can be used to test the functionality of triggers.\\ | ||
- | - Click on the “Set default template” button (1) to fill the action fields with default values. All values can be edited if necessary. | ||
- | - Clicking on the “Template Options” button (2) opens a menu with identifiers that can be used to compose the message. | ||
- | |||
- | {{: | ||
- | |||
- | ---- | ||
- | \\ | ||
- | After creating a trigger, click “Save”. On the “Triggers” dashboard, enable the necessary triggers. If the GUI page has not been refreshed – refresh the page in the browser or click the “Refresh” button. | ||
- | |||
- | {{: | ||
- | |||
- | ===== “Triggers and Notification” page elements description ===== | ||
- | |||
- | Go to QoE Analytics → Triggers and Notification. \\ | ||
- | This will open the section as shown in the image below. | ||
- | |||
- | {{: | ||
- | |||
- | This section contains three sections: | ||
- | |||
- | * List of the triggers. | ||
- | * List of the notifications. | ||
- | * List of actions performed by triggers as a result of notifications. | ||
- | |||
- | Types of triggers: | ||
- | * System. These are set by the vendor and can only be enabled/ | ||
- | * Custom. User-defined and can be freely configured. | ||
- | |||
- | For a detailed description of configuring a trigger, see [[en: |