|
1 | 1 | --- |
2 | | -title: Deleted Azure Event Hub is automatically recreated by Diagnostic Settings |
3 | | -description: Resolve issues with an Azure Event Hub that is automatically recreated by Diagnostic Settings after being deleted. |
4 | | -ms.date: 03/10/2025 |
5 | | -ms.reviewer: jfanjoy |
| 2 | +title: Deleted Azure Event Hub Is Automatically Recreated By Diagnostic Settings |
| 3 | +description: Resolve issues with an Azure Event Hub that is automatically recreated by diagnostic settings after being deleted. |
| 4 | +ms.date: 03/13/2025 |
| 5 | +ms.reviewer: jfanjoy, v-weizhu |
6 | 6 | ms.service: azure-monitor |
7 | 7 | --- |
| 8 | +# Deleted Azure Event Hub is automatically recreated by diagnostic settings |
8 | 9 |
|
9 | | -# Deleted Azure Event Hub is automatically recreated by Diagnostic Settings |
| 10 | +This article provides a solution to an issue where a deleted Azure Event Hub is automatically recreated by Azure diagnostic settings or their configuration cache. |
10 | 11 |
|
11 | 12 | ## Symptoms |
12 | 13 |
|
13 | | -1. When an Azure Event Hub is deleted from an Azure Event Hub Namespace, it is automatically recreated by the data flowing into the Event Hub through an Azure Diagnostic Setting. |
| 14 | +You might see the following symptoms: |
14 | 15 |
|
15 | | -1. After deleting an Azure Event Hub and all Azure Diagnostic Settings configured to send data to it, the Event Hub is automatically recreated. |
| 16 | +- When you delete an Event Hub from an Event Hub namespace, the Event Hub is recreated automatically by the data flowing into it through diagnostic settings. |
| 17 | +- After you delete an Event Hub and all diagnostic settings configured to send data to it, it's recreated automatically. |
16 | 18 |
|
17 | | -## Causes |
| 19 | +## Cause |
18 | 20 |
|
19 | | -1. This is by-design behavior of the Azure Diagnostic Settings. When configured to send data to an Azure Event Hub, if the Diagnostic Setting receives an error that the Event Hub does not exist, it will attempt to create it and then continue attempting to send the data. |
| 21 | +Here's are causes of the issue: |
20 | 22 |
|
21 | | -1. Azure Diagnostic Settings maintain a cache of configurations that lasts approximately 1 hour. Since the Diagnostic Setting will continue to send data for up to an hour after having been deleted, an Azure Event Hub that is the destination could get recreated even though the relevant Diagnostic Setting was deleted. |
| 23 | +- When a diagnostic setting is configured to send data to an Azure Event Hub, if it receives an error that the Event Hub doesn't exist, it will try to create it and then continue trying to send the data. |
| 24 | +- Azure diagnostic settings maintain a cache of configurations for approximately one hour. During this period, even if diagnostic settings have been removed, they will continue to send data to the destination such as a deleted Event Hub, causing it to be recreated. |
22 | 25 |
|
23 | | -## Resolutions |
| 26 | +## Solution |
24 | 27 |
|
25 | | -1. Update any Diagnostic Settings that are configured to send data to the problem Azure Event Hub so that either the Diagnostic Setting is no longer configured to send data to that destination, or delete the Diagnostic Settings. |
| 28 | +In a scenario where you delete an Event Hub from an Event Hub namespace, use one of the following methods to resolve the issue: |
26 | 29 |
|
27 | | -1. Update any Diagnostic Settings that are configured to send data to the problem Azure Event Hub so that either the Diagnostic Setting is no longer configured to send data to that destination, or delete the Diagnostic Settings. Wait a minimum of 1 hour, then delete the Azure Event Hub. |
| 30 | +- Update the diagnostic settings to prevent them from sending data to the Event Hub. |
| 31 | +- Delete the diagnostic settings. |
| 32 | + |
| 33 | +In a scenario when you delete an Event Hub and related diagnostic settings, update the diagnostic settings to prevent them from sending data to the Event Hub, delete them, wait for at least one hour to allow their configuration cache to expire, and then delete the Event Hub. |
| 34 | + |
| 35 | +[!INCLUDE [Azure Help Support](../../../../includes/azure-help-support.md)] |
0 commit comments