Skip to content

Commit 49f24b3

Browse files
authored
Merge pull request #266226 from halkazwini/nw-alert
Update screenshots
2 parents b040aa7 + 0f2a72a commit 49f24b3

File tree

5 files changed

+29
-24
lines changed

5 files changed

+29
-24
lines changed
83.6 KB
Loading
224 KB
Loading

articles/network-watcher/network-watcher-alert-triggered-packet-capture.md

Lines changed: 29 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,10 @@ author: halkazwini
55
ms.author: halkazwini
66
ms.service: network-watcher
77
ms.topic: how-to
8-
ms.date: 01/31/2024
8+
ms.date: 02/14/2024
99
ms.custom: devx-track-azurepowershell
1010
---
11+
1112
# Monitor networks proactively with alerts and Azure Functions using Packet Capture
1213

1314
Network Watcher packet capture creates capture sessions to track traffic in and out of virtual machines. The capture file can have a filter that is defined to track only the traffic that you want to monitor. This data is stored in a storage blob or locally on the guest machine.
@@ -22,13 +23,13 @@ By using Network Watcher alerting and functions from within the Azure ecosystem,
2223

2324
## Prerequisites
2425

25-
* The latest version of [Azure PowerShell](/powershell/azure/install-azure-powershell).
26-
* An existing instance of Network Watcher. If you don't already have one, [create an instance of Network Watcher](network-watcher-create.md).
27-
* An existing virtual machine in the same region as Network Watcher with the [Windows extension](../virtual-machines/extensions/network-watcher-windows.md) or [Linux virtual machine extension](../virtual-machines/extensions/network-watcher-linux.md).
26+
- The latest version of [Azure PowerShell](/powershell/azure/install-azure-powershell).
27+
- An existing instance of Network Watcher. If you don't already have one, [create an instance of Network Watcher](network-watcher-create.md).
28+
- An existing virtual machine in the same region as Network Watcher with the [Windows extension](../virtual-machines/extensions/network-watcher-windows.md) or [Linux virtual machine extension](../virtual-machines/extensions/network-watcher-linux.md).
2829

2930
## Scenario
3031

31-
In this example, your VM has more outgoing traffic than usual and you want to be alerted. Similarly, you can create alerts for any condition.
32+
In this example, a virtual machine (VM) has more outgoing traffic than usual and you want to be alerted. Similarly, you can create alerts for any condition.
3233

3334
When an alert is triggered, the packet-level data helps to analyze why the outgoing traffic has increased. You can take steps to return the virtual machine to its original state.
3435

@@ -53,29 +54,33 @@ This scenario does the following:
5354

5455
To create an Azure function to process the alert and create a packet capture, follow these steps:
5556

56-
1. In the [Azure portal](https://portal.azure.com), search for *function app* in **All services** and select it.
57+
1. Sign in to the [Azure portal](https://portal.azure.com).
58+
59+
1. In the search box at the top of the portal, enter *function app*. Select **Function App** from the search results
5760

58-
:::image type="content" source="./media/network-watcher-alert-triggered-packet-capture/search-result.png" alt-text="Screenshot of finding the function app in Azure portal.":::
61+
:::image type="content" source="./media/network-watcher-alert-triggered-packet-capture/function-app-portal-search.png" alt-text="Screenshot shows how to search for the function app in Azure portal." lightbox="./media/network-watcher-alert-triggered-packet-capture/function-app-portal-search.png":::
5962

60-
2. Select **Create** to open the **Create Function App** screen.
63+
1. Select **+ Create**.
6164

62-
:::image type="content" source="./media/network-watcher-alert-triggered-packet-capture/create-function-app.png" alt-text="Screenshot of the Create function app screen.":::
65+
1. In the **Basics** tab of **Create Function App**, enter or select values for the following settings:
6366

64-
2. In the **Basics** tab, enter the following values:
65-
1. Under **Project Details**, select the **Subscription** for which you want to create the Function app and the **Resource Group** to contain the app.
66-
2. Under **Instance details**, do the following:
67-
1. Enter the name of the Function app. This name will be appended by *.azurewebsites.net*.
68-
2. In **Publish**, select the mode of publishing, either *Code* or *Docker Container*.
69-
3. Select a **Runtime stack**.
70-
4. Select the version of the Runtime stack in **Version**.
71-
5. Select the **Region** in which you want to create the function app.
72-
3. Select **OK** to create the app.
73-
3. Under **Operating System**, select the type of Operating system that you're currently using. Azure recommends the type of Operating system based on your runtime stack selection.
74-
4. Under **Plan**, select the type of plan that you want to use for the function app. Choose from the following options:
67+
- Under **Project Details**, select the **Subscription** for which you want to create the Function app and the **Resource Group** to contain the app.
68+
- Under **Instance details**, do the following:
69+
- Enter the name of the Function app. This name will be appended by *.azurewebsites.net*.
70+
- In **Publish**, select the mode of publishing, either *Code* or *Docker Container*.
71+
- Select a **Runtime stack**.
72+
- Select the version of the Runtime stack in **Version**.
73+
- Select the **Region** in which you want to create the function app.
74+
- Select **OK** to create the app.
75+
- Under **Operating System**, select the type of Operating system that you're currently using. Azure recommends the type of Operating system based on your runtime stack selection.
76+
- Under **Plan**, select the type of plan that you want to use for the function app. Choose from the following options:
7577
- Consumption (Serverless) - For event-driven scaling for the most minimum cost.
7678
- Functions Premium - For enterprise-level, serverless applications with event-based scaling and network isolation.
7779
- App Service Plan - For reusing compute from an existing app service plan.
78-
3. Select **Review + create** to create the app.
80+
81+
:::image type="content" source="./media/network-watcher-alert-triggered-packet-capture/create-function-app-basics.png" alt-text="Screenshot of the Create function app page in the Azure portal." lightbox="./media/network-watcher-alert-triggered-packet-capture/create-function-app-basics.png":::
82+
83+
1. Select **Review + create** to create the app.
7984

8085
### Create an Azure function
8186

@@ -85,9 +90,9 @@ To create an Azure function to process the alert and create a packet capture, fo
8590

8691
2. Select **Develop in portal** from the **Development environment** drop-down.
8792
3. Under **Select a template**, select **HTTP Trigger**.
88-
4. In the **Template details** section, do the following:
89-
1. Enter the name of the function in the **New function** field.
90-
2. Select **Function** as the **Authorization level** and select **Create**.
93+
4. In the **Template details** section:
94+
- Enter the name of the function in the **New function** field.
95+
- Select **Function** as the **Authorization level** and select **Create**.
9196
5. After the function is created, go to the function and select **Code + Test**.
9297

9398
:::image type="content" source="./media/network-watcher-alert-triggered-packet-capture/code-test.png" alt-text="Screenshot of the Code + Test screen.":::

0 commit comments

Comments
 (0)