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

JCore - Initial AVD Pattern Add from AVD Accelerator #113

Merged
merged 12 commits into from
Feb 5, 2024
  •  
  •  
  •  
5 changes: 5 additions & 0 deletions docs/content/patterns/specialized/_index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
title: Specialized Workloads
geekdocCollapseSection: true
---

33 changes: 33 additions & 0 deletions docs/content/patterns/specialized/avd/FAQ.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
---
title: Frequently Asked Questions
geekdocCollapseSection: true
weight: 80
---

## What are the Prerequisites?

An AVD deployment and the Owner Role on the Subscription containing the AVD resources, VMs and Storage. You must have also pre-configured the AVD Insights as it will enable diagnostic logging for the Host Pools and associated VMs in which the alerts rely on.

## What's deployed to my Subscription?

Names will be created with a standard 'avdmetrics' in the name and vary based on input for things like site, environment type, etc.

Resource Group starting with the name "rg-avdmetrics-" with the following:

- Automation Account with a Runbook (for Host Pool Information not otherwise available)
- Identity for the Automation Account in which the name will start with "aa-avdmetrics-"
- Logic App that execute every 5 minutes (Host Pool Info Runbook)

The Automation Account Identity will be assigned the following roles at the Subscription level:

- Desktop Virtualization Reader
- Reader and Data Access (Storage Specific)

## What's the cost?

While this is highly subjective on the environment, number of triggered alerts, etc. it was designed with cost in mind. The primary resources in this deployment are the Automation Account and Alerts. We recommend you enable alerts in stages and monitor costs, however the overall cost should be minimal.

- Automation Account runs a script every 5 minutes to collect additional Azure File Share data and averages around $5/month
- Alert Rules vary based on number of times triggered but estimates are under $1/mo each.


8 changes: 8 additions & 0 deletions docs/content/patterns/specialized/avd/Known-Issues.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
title: Known Issues
geekdocCollapseSection: true
weight: 100
---

## None at this time

39 changes: 39 additions & 0 deletions docs/content/patterns/specialized/avd/Telemetry.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
---
title: Telemetry
geekdocCollapseSection: true
weight: 90
---

<!-- markdownlint-disable -->
## Telemetry Tracking Using Customer Usage Attribution (PID)
<!-- markdownlint-restore -->

Microsoft can identify the deployments of the Azure Resource Manager and Bicep templates with the deployed Azure resources. Microsoft can correlate these resources used to support the deployments. Microsoft collects this information to provide the best experiences with their products and to operate their business. The telemetry is collected through [customer usage attribution](https://docs.microsoft.com/azure/marketplace/azure-partner-customer-usage-attribution). The data is collected and governed by Microsoft's privacy policies, located at the [trust center](https://www.microsoft.com/trustcenter).

To disable this tracking, we have included a parameter called `telemetryOptOut` to the deployment template in this repo with a simple boolean flag. The default value `No` which **does not** disable the telemetry. If you would like to disable this tracking, then simply set this value to `Yes` and this module will not be included in deployments and **therefore disables** the telemetry tracking.

If you are happy with leaving telemetry tracking enabled, no changes are required.

**Check the box labeled "Opt-Out of Telemetry"** when using the "Deploy to Azure" buttons with a custom User Interface. There is no parameters file for this deployment.
<img src="../../../../img/Avd/AVDAlertsOptOut.png" width=30%>

In the avdArm.json file, you will see the following:

```json
"optoutTelemetry": {
"type": "bool",
"defaultValue": false,
"metadata": {
"description": "Telemetry Opt-Out"
}
},
```


## Module PID Value Mapping

The following are the unique ID's (also known as PIDs) used in the Alerts Pattern deployment

| Name | PID |
| ------------------------------- | ------------------------------------ |
| AVD Baseline Alerts | b8b4a533-1bb2-402f-bbd9-3055d00d885a |
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
title: Update to a new release
geekdocCollapseSection: true
weight: 70
---

# How to update to a new release

Currently, redeploying the solution will update the existing components to include the alerts. Stay tuned for additional details as new releases are made available.
20 changes: 20 additions & 0 deletions docs/content/patterns/specialized/avd/Whats-New.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
title: What´s new
geekdocCollapseSection: true
weight: 10
---

For information on what's new please refer to the [Releases](https://github.com/Azure/azure-monitor-baseline-alerts/releases) page.

To update your current deployment with the content from the latest release, please refer to the [Update to new release](../Update-to-new-Release) page.

## 2024-01-25
### New features
Initial relocation from the Azure AVD Accelerator Brownfield with AVD specific Alerts on a per Host Pool basis.
- Session Host monitoring both on performance, AVD agent health, storage, and fslogix profiles

### Bug fixes
No new bug fixes at this time.



101 changes: 101 additions & 0 deletions docs/content/patterns/specialized/avd/_index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
---
title: Azure Virtual Desktop
geekdocCollapseSection: true
---

## Overview

This solution provides a baseline of alerts for AVD that are disabled by default and for ensuring administrators and staff get meaningful and timely alerts when there are problems related to an AVD deployment. The deployment has been tested in Azure Global and Azure US Government and will incorporate storage alerts for either or both Azure Files and/or Azure Netapp Files. This solution initially was part of the Azure Virtual Desktop Solution Accelerator as a brownfield and moved to this location.

**Current Version:**
v2.1.5 (Dec 5, 2023)

## Alerts Table

Table below shows the Alert Names however the number of alert rules created may be multiple based on different severity and/or additional volume or storage name designators. For example, a deployment with a single Azure Files Storage Account and an Azure NetApp Files Volume would yield 20 alert rules created. [(Excel Table)](../media/alerts.xlsx)

| Name | Threshold(s) (Severity) | Signal Type | Frequency | # Alert Rules |
|--- |--- |--- |--- |---
| AVD-HostPool-Capacity (1.) | 95% (1) / 85% (2) / 50% (3)| Log Analytics | 5 min | 3/hostpool |
| AVD-HostPool-Disconnected User over n Hours (hostpoolname) | 24 (1) / 72 (2) | Log Analytics | 1 hour | 2/hostpool |
| AVD-HostPool-No Resources Available (hostpoolname) | Any are Sev1 | Log Analytics | 15 min | 1/hostpool |
| AVD-HostPool-VM-Available Memory Less Than nGB (hostpoolname) | 1gb (Sev1) / 2gb (Sev2) | Metric Alerts | 5 min | 2/hostpool |
| AVD-HostPool-VM-FSLogix Profile DiskCompactFailed (hostpoolname) | (2) | Log Analytics | 5 min | 1/hostpool |
| AVD-HostPool-VM-FSLogix Profile FailedAttachVHD (hostpoolname) | (1) | Log Analytics | 5 min | 1/hostpool |
| AVD-HostPool-VM-FSLogix Profile Less Than n% Free Space (hostpoolname) | 2% (1) / 5% (2) | Log Analytics | 5 min | 2/hostpool |
| AVD-HostPool-VM-FSLogix Profile Failed due to Network Issue (hostpoolname)| (1) | Log Analytics | 5 min | 1/hostpool |
| AVD-HostPool-VM-FSLogix Profile Service Disabled (hostpoolname) | (1) | Log Analytics | 5 min | 1/hostpool |
| AVD-HostPool-VM-Health Check Failure (hostpoolname) | (1) | Log Analytics | 5 min | 1/hostpool |
| AVD-HostPool-VM-High CPU nn Percent (hostpoolname) | 95 (1) / 85 (2) | Metric Alerts | 5 min | 2/hostpool |
| AVD-HostPool-VM-Local Disk Free Space n% (hostpoolname) | 5 (1) / 10 (2) | Log Analytics | 15 min | 2/hostpool |
| AVD-HostPool-VM-Personal Assigned Not Healthy (hostpoolname) | Any are Sev 1 | Log Analytics | 5 min | 1/hostpool |
| AVD-HostPool-VM-OS Disk Bandwidth Avg n% (hostpoolname) | 95 (1) / 85 (2) | Metric Alerts | 5 min | 2/hostpool |
| AVD-HostPool-VM-User Connection Failed (hostpoolname) | Any are Sev 3 | Log Analytics | 15 min | 1/hostpool |
| AVD-HostPool-VM-Missing Critical Updates (hostpoolname) | Any are Sev 1 | Log Analytics | 1 day | 1/hostpool |
| AVD-Storage-Low Space on ANF Share-XX Percent Remaining-{volumename} | 5 / 15 | Metric Alerts | 1 hour | 2/vol |
| AVD-Storage-Low Space on Azure File Share-X% Remaining-{volumename} (1.) | 5 / 15 | Log Analytics | 1 hour | 2/share |
| AVD-Storage-Over XXms Latency for Storage Act-{storacctname} | 100ms / 50ms | Metric Alerts | 15 min | 2/stor acct |
| AVD-Storage-Over XXms Latency Between Client-Storage-{storacctname} | 100ms / 50ms | Metric Alerts | 15 min | 2/stor acct |
| AVD-Storage-Possible Throttling Due to High IOPs-{storacctname} (2.) | na / custom :two: | Metric Alerts | 15 min | 1/stor acct |
| AVD-Storage-Azure Files Availability-{storacctname} | 99 / na | Metric Alerts | 5 min | 1/stor acct |
| AVD-ServiceHealth-Health Advisory | na | Service Health | na | 4 |
| AVD-ServiceHealth-Planned Maintenance | na | Service Health | na | 4 |
| AVD-ServiceHealth-Security | na | Service Health | na | 4 |
| AVD-ServiceHealth-Service Issue | na | Service Health | na | 4 |

**NOTES:**
1. Alert based on associated Automation Account / Runbook
2. See the following for custom condition. Note that both Standard and Premium values are incorporated into the alert rule. ['How to create an alert if a file share is throttled'](https://docs.microsoft.com/azure/storage/files/storage-troubleshooting-files-performance#how-to-create-an-alert-if-a-file-share-is-throttled)
Service Health - The alert severity cannot be set or changed from 'Verbose'

## 📣Feedback 📣

Once you've had an opportunity to deploy the solution we'd love to hear from you! Click [here](https://aka.ms/alz/monitor/feedback) to leave your feedback.

If you have encountered a problem please file an issue in our GitHub repo [GitHub Issue](https://github.com/Azure/azure-monitor-baseline-alerts/issues).

## Deployment Guide

We have a [Deployment Guide](./deploy/Avd-Deploy) available for guidance on how to consume the contents of this repo.

## Known Issues

Please see the [Known Issues](Known-Issues).

## Frequently Asked Questions

Please see the [Frequently Asked Questions](../avd/FAQ).

## Contributing

This project welcomes contributions and suggestions.
Most contributions require you to agree to a Contributor License Agreement (CLA)
declaring that you have the right to, and actually do, grant us the rights to use your contribution.
For details, visit [https://cla.opensource.microsoft.com](https://cla.opensource.microsoft.com).

When you submit a pull request, a CLA bot will automatically determine whether you need to provide
a CLA and decorate the PR appropriately (e.g., status check, comment).
Simply follow the instructions provided by the bot.
You will only need to do this once across all repos using our CLA.

This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or
contact [[email protected]](mailto:[email protected]) with any additional questions or comments.

{{< hint type=note >}}
Details on contributing to this repo can be found [here](../../../contributing/)
{{< /hint >}}

## Telemetry

When you deploy the IP located in this repo, Microsoft can identify the installation of said IP with the deployed Azure resources. Microsoft can correlate these resources used to support the software. Microsoft collects this information to provide the best experiences with their products and to operate their business. The telemetry is collected through customer usage attribution. The data is collected and governed by [Microsoft's privacy policies](https://www.microsoft.com/trustcenter).

If you don't wish to send usage data to Microsoft, or need to understand more about its' use details can be found [here](./Telemetry).

## Trademarks

This project may contain trademarks or logos for projects, products, or services.
Authorized use of Microsoft trademarks or logos is subject to and must follow
[Microsoft's Trademark & Brand Guidelines](https://www.microsoft.com/legal/intellectualproperty/trademarks/usage/general).
Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship.
Any use of third-party trademarks or logos are subject to those third-party's policies.
40 changes: 40 additions & 0 deletions docs/content/patterns/specialized/avd/deploy/Avd-Deploy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
---
title: Deploying the AVD pattern
geekdocCollapseSection: true
weight: 50
---

## Background

The Azure Virtual Desktop portal within Azure has a really great feature with regards to knowing the status of all things AVD via the provided Insights. However with the provided workbook it is not possible to create alerts based on what you see in Insights or having some knowledge of Log Analytics and Kusto queries. In order to provide customers with a quick list of common alerts and pre-created queries based on recommendations between the community with coordination with the Product Group, this solution was created. The alerts are intended to be disabled upon initial deployment to provide you with a method to phase in what you want to be alerted on, and verify the threshold values that work for your environment.

## Prerequisites

An AVD deployment with associated Insights configuration per the AVD Portal's AVD Insights Configuration workbook.
1. An Azure Tenant and Subscription
2. At least 1 Host Pool with Session Hosts deployed
3. Log Analytics Workspace for AVD with diagnostics enabled per the configuration workbook.
- Host Pool Diagnostics enabled
- Workspace Diagnostics enabled
- Data Collection Rule associated with the Log Analytics Workspace
4. Storage either Azure Files or Azure NetApp Files configured for FSLogix Profiles (optional)

## Deploy via the Azure Portal UI

[![Deploy to Azure](https://aka.ms/deploytoazurebutton)](https://portal.azure.com/#blade/Microsoft_Azure_CreateUIDef/CustomDeploymentBlade/uri/https%3A%2F%2Fraw.githubusercontent.com%2FAzure%2Fazure-monitor-baseline-alerts%2Fblob%2F%2Fmain%2Fpatterns%2Favd%2FavdArm.json/uiFormDefinitionUri/https%3A%2F%2Fraw.githubusercontent.com%2FAzure%2Fazure-monitor-baseline-alerts%2Fblob%2F%2Fmain%2Fpatterns%2Favd%2FavdCustomUi.json) [![Deploy to Azure Gov](https://aka.ms/deploytoazuregovbutton)](https://portal.azure.com/#blade/Microsoft_Azure_CreateUIDef/CustomDeploymentBlade/uri/https%3A%2F%2Fraw.githubusercontent.com%2FAzure%2Fazure-monitor-baseline-alerts%2Fblob%2F%2Fmain%2Fpatterns%2Favd%2FavdArm.json/uiFormDefinitionUri/https%3A%2F%2Fraw.githubusercontent.com%2FAzure%2Fazure-monitor-baseline-alerts%2Fblob%2F%2Fmain%2Fpatterns%2Favd%2FavdCustomUi.json)

## View / Enable Alerts after deployment

By design the alerts solution is deployed with all alerts being disabled in order to provide administrators to view, adjust and enable them in phases or as needed. It is recommended to start with only a few to ensure the thresholds meet your needs and false alerts are not produced or an overwhelming number of alerts flood an email account.

You can also review the Alert Action Group and adjust as needed with additional email addresses or other methods for recieving notifications.

1. Open the [Alerts Azure Portal Page](https://portal.azure.com/#blade/Microsoft_Azure_Monitoring/AzureMonitoringBrowseBlade/alertsV2)
2. Click on the "Alert rules" section at the top of the page.
<img src="../../../../../img/Avd/avdAlertRules.jpg" width=30%>

3. Initially the list of alert rules may be filtered out or appear missing. Simply change the filter to include "disabled" or click the "Clear filters" option.
<img src="../../../../../img/Avd/avdAlertRulesFilter.jpg" width=30%>

4. Select the check box next to each you would like to enable and click "Enable" at the top of the page.
<img src="../../../../../img/Avd/avdAlertRulesEnable.jpg" width=30%>
Binary file added docs/static/img/Avd/AVDAlertsOptOut.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/static/img/Avd/alerts.xlsx
Binary file not shown.
Binary file added docs/static/img/Avd/avdAlertRules.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/static/img/Avd/avdAlertRulesChange.jpg
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.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/static/img/Avd/avdAlertRulesCopy1.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/static/img/Avd/avdAlertRulesCopy2.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/static/img/Avd/avdAlertRulesCopy3.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/static/img/Avd/avdAlertRulesEnable.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/static/img/Avd/avdAlertRulesFilter.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/static/img/Avd/avdAlertRulesProperties.jpg
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.
Loading