Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Serverless] Manual rule run docs #5589

Open
wants to merge 54 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 45 commits
Commits
Show all changes
54 commits
Select commit Hold shift + click to select a range
d141cf1
First draft
nastasha-solomon Jul 22, 2024
9a544fe
Second draft
nastasha-solomon Jul 23, 2024
99f7660
Fix ref and add tech preview tag
nastasha-solomon Jul 23, 2024
c75f9b5
Minor rewording
nastasha-solomon Jul 23, 2024
d2162ca
Fix incorrect ref
nastasha-solomon Jul 23, 2024
1ce5bfc
Adding API docs
nastasha-solomon Jul 23, 2024
6b11210
Update docs/detections/api/rules/rules-api-bulk-actions.asciidoc
nastasha-solomon Jul 23, 2024
f031d1d
Zhenia's input
nastasha-solomon Jul 23, 2024
cee1fcc
Re-adding line accidentally deleted
nastasha-solomon Jul 23, 2024
fcb28c6
Removed uncessary header
nastasha-solomon Jul 23, 2024
6eabd8e
Moved section to correct spot
nastasha-solomon Jul 23, 2024
60fdc69
Updating images
nastasha-solomon Jul 23, 2024
f0a5fae
Minor wording adjustments
nastasha-solomon Jul 23, 2024
aa72b75
Fixed formatting and editorial typos
nastasha-solomon Jul 23, 2024
c6d4663
Merge branch 'main' into issue-5264-manual-rule-run
nastasha-solomon Jul 24, 2024
2db3443
Update docs/detections/rules-ui-manage.asciidoc
nastasha-solomon Jul 24, 2024
8790b12
Applying feedback to Serverless docs
nastasha-solomon Jul 24, 2024
7bf78da
Update docs/detections/rules-ui-manage.asciidoc
nastasha-solomon Jul 25, 2024
d769701
Update docs/serverless/rules/rules-ui-management.mdx
nastasha-solomon Jul 25, 2024
27f7df6
Update docs/detections/rules-ui-manage.asciidoc
nastasha-solomon Jul 25, 2024
7059db7
Update docs/serverless/rules/rules-ui-management.mdx
nastasha-solomon Jul 25, 2024
199031d
Update docs/detections/rules-ui-monitor.asciidoc
nastasha-solomon Jul 25, 2024
1ab9402
Update docs/serverless/rules/alerts-ui-monitor.mdx
nastasha-solomon Jul 25, 2024
f5e1c5e
Update docs/detections/rules-ui-monitor.asciidoc
nastasha-solomon Jul 25, 2024
877e39a
Update docs/serverless/rules/alerts-ui-monitor.mdx
nastasha-solomon Jul 25, 2024
e5f75bf
Update docs/detections/rules-ui-monitor.asciidoc
nastasha-solomon Jul 25, 2024
7e77fb4
Update docs/serverless/rules/alerts-ui-monitor.mdx
nastasha-solomon Jul 25, 2024
8f97d0d
Update docs/detections/rules-ui-monitor.asciidoc
nastasha-solomon Jul 25, 2024
9b45d8a
Update docs/serverless/rules/alerts-ui-monitor.mdx
nastasha-solomon Jul 25, 2024
f3b7f2a
Update docs/detections/rules-ui-manage.asciidoc
nastasha-solomon Jul 26, 2024
7ba4749
Joe's input
nastasha-solomon Jul 26, 2024
6974d5e
Update docs/detections/rules-ui-monitor.asciidoc
nastasha-solomon Jul 29, 2024
81aae22
Input from editorial and technical reviews
nastasha-solomon Jul 29, 2024
c7fb076
Update docs/detections/rules-ui-manage.asciidoc
nastasha-solomon Jul 30, 2024
93e0ae3
Update docs/serverless/rules/rules-ui-management.mdx
nastasha-solomon Jul 30, 2024
e56747c
Removing ESS changes
nastasha-solomon Jul 30, 2024
0295b81
Removing more ESS API changes
nastasha-solomon Jul 30, 2024
c1d0468
Cleaning up last ESS changes
nastasha-solomon Jul 30, 2024
4f0c5d2
Readding ref
nastasha-solomon Jul 30, 2024
a4f0c0b
Merge branch 'main' into issue-5264-manual-rule-run
nastasha-solomon Sep 18, 2024
86f628e
Limitations and alert field
nastasha-solomon Sep 19, 2024
75bc269
Switch sentence order
nastasha-solomon Sep 19, 2024
2bd5110
Updates note
nastasha-solomon Sep 19, 2024
a624705
Update docs/serverless/rules/rules-ui-management.mdx
nastasha-solomon Sep 24, 2024
0cf94fb
Update docs/serverless/rules/alerts-ui-monitor.mdx
nastasha-solomon Sep 24, 2024
af0729f
Update docs/serverless/rules/alerts-ui-monitor.mdx
nastasha-solomon Sep 24, 2024
326e02f
Merge branch 'main' into issue-5264-manual-rule-run
nastasha-solomon Sep 24, 2024
b3e3bd0
Update docs/serverless/alerts/alert-schema.mdx
approksiu Sep 24, 2024
ca5fb7f
Update docs/serverless/rules/rules-ui-management.mdx
approksiu Sep 24, 2024
1f4a4af
Update docs/serverless/rules/alerts-ui-monitor.mdx
approksiu Sep 24, 2024
5eedc2f
Update docs/serverless/rules/rules-ui-management.mdx
approksiu Sep 24, 2024
52dbf8b
Minor wording tweak
nastasha-solomon Sep 24, 2024
075259d
Removed incorrect path
nastasha-solomon Sep 24, 2024
d5f0489
Used EUI icon
nastasha-solomon Sep 24, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions docs/serverless/alerts/alert-schema.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -904,4 +904,13 @@ The non-ECS fields listed below are beta and subject to change.

</DocCell>
</DocRow>
<DocRow>
<DocCell> `kibana.alert.intended_timestamp`</DocCell>
<DocCell>
Represents the estimated time when the alert was created by a manual rule run.
approksiu marked this conversation as resolved.
Show resolved Hide resolved

Type: date

</DocCell>
</DocRow>
</DocTable>
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
37 changes: 34 additions & 3 deletions docs/serverless/rules/alerts-ui-monitor.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -41,27 +41,58 @@ For detailed information on a rule, the alerts it generated, and associated erro

## Execution results

Each detection rule execution is logged, including its success or failure, any warning or error messages, and how long it took to search for data, create alerts, and complete. This can help you troubleshoot a particular rule if it isn't behaving as expected (for example, if it isn't creating alerts or takes a long time to run).
Each detection rule execution is logged, including the execution type, the execution's success or failure, any warning or error messages, how long it took to search for data, create alerts, and complete. This can help you troubleshoot a particular rule if it isn't behaving as expected (for example, if it isn't creating alerts or takes a long time to run).

To access a rule's execution log, go to **Rules** → **Detection rules (SIEM)**, click the rule's name to open its details, then scroll down and select the **Execution results** tab. You can expand a long warning or error message by clicking the arrow at the end of a row.
To access a rule's execution log, go to **Rules** → **Detection rules (SIEM)**, click the rule's name to open its details, then scroll down and select the **Execution results** tab. Within the Execution log table, you can click the arrow at the end of a row to expand a long warning or error message.

![Rule execution results tab](../images/alerts-ui-monitor/-detections-rule-execution-logs.png)
![Rule execution log on the rule execution results tab](../images/alerts-ui-monitor/-detections-rule-execution-logs.png)

You can hover over each column heading to display a tooltip about that column's data. Click a column heading to sort the table by that column.

Use these controls to filter what's included in the logs table:

* The **Run type** drop-down filters the table by rule execution type:
* **Scheduled**: Rule executions that the detection engine automatically ran according to the rule's schedule.
* **Manual**: Rule executions that were <DocLink slug="/serverless/security/rules-ui-management" section="manually-run-rules">started manually</DocLink>.

* The **Status** drop-down filters the table by rule execution status:
* **Succeeded**: The rule completed its defined search. This doesn't necessarily mean it generated an alert, just that it ran without error.
* **Failed**: The rule encountered an error that prevented it from running. For example, a ((ml)) rule whose corresponding ((ml)) job wasn't running.
* **Warning**: Nothing prevented the rule from running, but it might have returned unexpected results. For example, a custom query rule tried to search an index pattern that couldn't be found in ((es)).

* The date and time picker sets the time range of rule executions included in the table. This is separate from the global date and time picker at the top of the rule details page.

* The **Source event time range** toggle includes more or less data in the table, pertaining to the time range of a manual run.

* The **Show metrics columns** toggle includes more or less data in the table, pertaining to the timing of each rule execution.

* The **Actions** column allows you to show alerts generated from a given rule execution. Click the filter icon (<DocIcon type="filterInCircle" title="Filter" size="s"/>) to create a global search filter based on the rule execution's ID value. This replaces any previously applied filters, changes the global date and time range to 24 hours before and after the rule execution, and displays a confirmation notification. You can revert this action by clicking **Restore previous filters** in the notification.

<div id="manual-runs-table"></div>

### Manual runs table

<DocBadge template="technical preview" />

Execution details of active manual runs are shown in the Manual runs table. To access the table, go to **Rules** -> **Detection rules (SIEM)**, click the rule's name to open its details, then scroll down and select the **Execution results** tab. Scroll down again to find the Manual runs table.
approksiu marked this conversation as resolved.
Show resolved Hide resolved

To stop an active run, go to the appropriate row and click **Stop run** in the **Actions** column. Completed or stopped rule runs are logged in the Execution log table.
nastasha-solomon marked this conversation as resolved.
Show resolved Hide resolved

![Manual rule runs table on the rule execution results tab](../images/alerts-ui-monitor/-detections-manual-rule-run-table.png)

The Manual runs table displays important details such as:

* The status of each manual run:
* **Pending**: The rule is not yet running.
* **Running**: The rule is executing during the time range you specified. Some rules, such as indicator match rules, can take longer to run.
* **Error**: The rule's configuration might have an issue. For example, the rule's conditions cannot be validated.

* When a manual run started and the time in which it will run

* The number of rule executions that are failing, pending, running, and completed for a manual run

* The total number of rule executions that are occurring for a manual run

<div id="troubleshoot-signals"></div>

## Troubleshoot missing alerts
Expand Down
26 changes: 26 additions & 0 deletions docs/serverless/rules/rules-ui-management.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ On the Rules page, you can:
* <DocLink slug="/serverless/security/rules-ui-management" section="check-the-current-status-of-rules">Check the current status of rules</DocLink>
* <DocLink slug="/serverless/security/rules-ui-management" section="modify-existing-rules-settings">Modify existing rules settings</DocLink>
* <DocLink slug="/serverless/security/rules-ui-management" section="manage-rules">Manage rules</DocLink>
* <DocLink slug="/serverless/security/rules-ui-management" section="manually-run-rules">Manually run rules</DocLink>
* <DocLink slug="/serverless/security/rules-ui-management" section="snooze-rule-actions">Snooze rule actions</DocLink>
* <DocLink slug="/serverless/security/rules-ui-management" section="export-and-import-rules">Export and import rules</DocLink>
* <DocLink slug="/serverless/security/rules-ui-management" section="confirm-rule-prerequisites">Confirm rule prerequisites</DocLink>
Expand Down Expand Up @@ -111,6 +112,31 @@ When duplicating a rule with exceptions, you can choose to duplicate the rule an
* To enable or disable a single rule, switch on the rule's **Enabled** toggle.
* To <DocLink slug="/serverless/security/rules-ui-management" section="snooze-rule-actions">snooze</DocLink> actions for rules, click the bell icon.

<div id="manually-run-rules"></div>

## Run rules manually

<DocBadge template="technical preview" />

Manually run enabled rules for a specfied period of time for testing purposes or additional rule coverage.

<DocCallOut title="Important" color="warning">
Before manually running rules, make sure you properly understand and plan for rule dependencies. Incorrect scheduling can lead to inconsistent rule results.
</DocCallOut>

1. Go to **Rules** -> **Detection rules (SIEM)**.
1. Do one of the following:
* Select the **All actions** menu on a rule (**...** → **All actions** in the rules list), then select **Manual run**.
* Select all the rules you want to manually run, select the **Bulk actions** menu, then select **Manual run**.
1. Specify when the manual run starts and ends. The default selection is the current day starting three hours in the past. The rule will search for events during the selected time range.
1. Click **Run** to manually run the rule.
approksiu marked this conversation as resolved.
Show resolved Hide resolved

The manual run's details are shown in the <DocLink slug="/serverless/security/alerts-ui-monitor" section="manual-runs-table">Manual runs</DocLink> table on the **Execution results** tab. Changes you make to the manual run or rule settings will display in the Manual runs table after the current run completes.

<DocCallOut title="Note">
Manual runs are executed with low priority and limited concurrency, meaning they might take longer to complete. This can be especially apparent for rules requiring multiple executions.
approksiu marked this conversation as resolved.
Show resolved Hide resolved
</DocCallOut>

<div id="snooze-rule-actions"></div>

## Snooze rule actions
Expand Down
Loading