You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -34,62 +34,62 @@ Advanced Network Observability is one of the features of Advanced Container Netw
34
34
35
35
Install or update the Azure CLI preview extension using the [`az extension add`](/cli/azure/extension#az_extension_add) or [`az extension update`](/cli/azure/extension#az_extension_update) command.
36
36
37
-
```azurecli-interactive
38
-
# Install the aks-preview extension
39
-
az extension add --name aks-preview
40
-
41
-
# Update the extension to make sure you have the latest version installed
42
-
az extension update --name aks-preview
43
-
```
37
+
```azurecli-interactive
38
+
# Install the aks-preview extension
39
+
az extension add --name aks-preview
40
+
41
+
# Update the extension to make sure you have the latest version installed
42
+
az extension update --name aks-preview
43
+
```
44
44
45
45
### Register the `AdvancedNetworkingPreview` feature flag
46
46
47
47
Register the `az feature register --namespace "Microsoft.ContainerService" --name "AdvancedNetworkingPreview"
48
48
` feature flag using the [`az feature register`](/cli/azure/feature#az_feature_register) command.
49
49
50
-
```azurecli-interactive
51
-
az feature register --namespace "Microsoft.ContainerService" --name "AdvancedNetworkingPreview"
52
-
```
50
+
```azurecli-interactive
51
+
az feature register --namespace "Microsoft.ContainerService" --name "AdvancedNetworkingPreview"
52
+
```
53
53
Verify successful registration using the [`az feature show`](/cli/azure/feature#az_feature_show) command. It takes a few minutes for the registration to complete.
54
54
55
-
```azurecli-interactive
56
-
az feature show --namespace "Microsoft.ContainerService" --name "AdvancedNetworkingPreview"
57
-
```
55
+
```azurecli-interactive
56
+
az feature show --namespace "Microsoft.ContainerService" --name "AdvancedNetworkingPreview"
57
+
```
58
58
59
59
Once the feature shows `Registered`, refresh the registration of the `Microsoft.ContainerService` resource provider using the [`az provider register`](/cli/azure/provider#az_provider_register) command.
60
60
61
61
## Create a resource group
62
62
63
63
A resource group is a logical container into which Azure resources are deployed and managed. Create a resource group using the [`az group create`](/cli/azure/group#az_group_create) command.
64
64
65
-
```azurecli-interactive
66
-
# Set environment variables for the resource group name and location. Make sure to replace the placeholders with your own values.
67
-
export RESOURCE_GROUP="<resource-group-name>"
68
-
export LOCATION="<azure-region>"
69
-
70
-
# Create a resource group
71
-
az group create --name $RESOURCE_GROUP --location $LOCATION
72
-
```
65
+
```azurecli-interactive
66
+
# Set environment variables for the resource group name and location. Make sure to replace the placeholders with your own values.
67
+
export RESOURCE_GROUP="<resource-group-name>"
68
+
export LOCATION="<azure-region>"
69
+
70
+
# Create a resource group
71
+
az group create --name $RESOURCE_GROUP --location $LOCATION
72
+
```
73
73
74
74
## Create an AKS cluster with Advanced Network Observability
75
75
76
76
### [**Non-Cilium**](#tab/non-cilium)
77
77
Create an AKS cluster with Advanced Network Observability with a non-Cilium data plane using the [`az aks create`](/cli/azure/aks#az_aks_create) command and the `--enable-advanced-networking-observability` flag.
78
78
79
-
```azurecli-interactive
80
-
# Set an environment variable for the AKS cluster name. Make sure to replace the placeholder with your own value.
81
-
export CLUSTER_NAME="<aks-cluster-name>"
82
-
83
-
# Create an AKS cluster
84
-
az aks create \
85
-
--name $CLUSTER_NAME \
86
-
--resource-group $RESOURCE_GROUP \
87
-
--generate-ssh-keys \
88
-
--network-plugin azure \
89
-
--network-plugin-mode overlay \
90
-
--pod-cidr 192.168.0.0/16 \
91
-
--enable-advanced-network-observability
92
-
```
79
+
```azurecli-interactive
80
+
# Set an environment variable for the AKS cluster name. Make sure to replace the placeholder with your own value.
81
+
export CLUSTER_NAME="<aks-cluster-name>"
82
+
83
+
# Create an AKS cluster
84
+
az aks create \
85
+
--name $CLUSTER_NAME \
86
+
--resource-group $RESOURCE_GROUP \
87
+
--generate-ssh-keys \
88
+
--network-plugin azure \
89
+
--network-plugin-mode overlay \
90
+
--pod-cidr 192.168.0.0/16 \
91
+
--enable-advanced-network-observability
92
+
```
93
93
94
94
### [**Cilium**](#tab/cilium)
95
95
@@ -99,25 +99,25 @@ Create an AKS cluster with Advanced Network Observability with a Cilium data pla
99
99
> Clusters with the Cilium data plane support Advanced Network Observability starting with Kubernetes version 1.29.
100
100
101
101
102
-
```azurecli-interactive
103
-
# Set an environment variable for the AKS cluster name. Make sure to replace the placeholder with your own value.
104
-
export CLUSTER_NAME="<aks-cluster-name>"
105
-
106
-
# Create an AKS cluster
107
-
az aks create \
108
-
--name $CLUSTER_NAME \
109
-
--resource-group $RESOURCE_GROUP \
110
-
--generate-ssh-keys \
111
-
--location eastus \
112
-
--max-pods 250 \
113
-
--network-plugin azure \
114
-
--network-plugin-mode overlay \
115
-
--network-dataplane cilium \
116
-
--node-count 2 \
117
-
--pod-cidr 192.168.0.0/16 \
118
-
--kubernetes-version 1.29 \
119
-
--enable-advanced-network-observability
120
-
```
102
+
```azurecli-interactive
103
+
# Set an environment variable for the AKS cluster name. Make sure to replace the placeholder with your own value.
104
+
export CLUSTER_NAME="<aks-cluster-name>"
105
+
106
+
# Create an AKS cluster
107
+
az aks create \
108
+
--name $CLUSTER_NAME \
109
+
--resource-group $RESOURCE_GROUP \
110
+
--generate-ssh-keys \
111
+
--location eastus \
112
+
--max-pods 250 \
113
+
--network-plugin azure \
114
+
--network-plugin-mode overlay \
115
+
--network-dataplane cilium \
116
+
--node-count 2 \
117
+
--pod-cidr 192.168.0.0/16 \
118
+
--kubernetes-version 1.29 \
119
+
--enable-advanced-network-observability
120
+
```
121
121
122
122
---
123
123
@@ -128,85 +128,85 @@ Enable Advanced Network Observability on an existing cluster using the [`az aks
128
128
> [!NOTE]
129
129
> Clusters with the Cilium data plane support Advanced Network Observability starting with Kubernetes version 1.29.
130
130
131
-
```azurecli-interactive
132
-
az aks update \
133
-
--resource-group $RESOURCE_GROUP \
134
-
--name $CLUSTER_NAME \
135
-
--enable-advanced-network-observability
136
-
```
131
+
```azurecli-interactive
132
+
az aks update \
133
+
--resource-group $RESOURCE_GROUP \
134
+
--name $CLUSTER_NAME \
135
+
--enable-advanced-network-observability
136
+
```
137
137
138
138
## Get cluster credentials
139
139
140
140
Get your cluster credentials using the [`az aks get-credentials`](/cli/azure/aks#az_aks_get_credentials) command.
141
141
142
-
```azurecli-interactive
143
-
az aks get-credentials --name $CLUSTER_NAME --resource-group $RESOURCE_GROUP
144
-
```
142
+
```azurecli-interactive
143
+
az aks get-credentials --name $CLUSTER_NAME --resource-group $RESOURCE_GROUP
144
+
```
145
145
146
146
## Azure managed Prometheus and Grafana
147
147
148
148
Use the following example to install and enable Prometheus and Grafana for your AKS cluster.
149
149
150
150
### Create Azure Monitor resource
151
151
152
-
```azurecli-interactive
153
-
#Set an environment variable for the Grafana name. Make sure to replace the placeholder with your own value.
154
-
export AZURE_MONITOR_NAME="<azure-monitor-name>"
155
-
156
-
# Create Azure monitor resource
157
-
az resource create \
158
-
--resource-group $RESOURCE_GROUP \
159
-
--namespace microsoft.monitor \
160
-
--resource-type accounts \
161
-
--name $AZURE_MONITOR_NAME \
162
-
--location eastus \
163
-
--properties '{}'
164
-
```
152
+
```azurecli-interactive
153
+
#Set an environment variable for the Grafana name. Make sure to replace the placeholder with your own value.
154
+
export AZURE_MONITOR_NAME="<azure-monitor-name>"
155
+
156
+
# Create Azure monitor resource
157
+
az resource create \
158
+
--resource-group $RESOURCE_GROUP \
159
+
--namespace microsoft.monitor \
160
+
--resource-type accounts \
161
+
--name $AZURE_MONITOR_NAME \
162
+
--location eastus \
163
+
--properties '{}'
164
+
```
165
165
166
166
### Create Grafana instance
167
167
168
168
Use [az grafana create](/cli/azure/grafana#az-grafana-create) to create a Grafana instance. The name of the Grafana instance must be unique.
169
169
170
-
```azurecli-interactive
171
-
# Set an environment variable for the Grafana name. Make sure to replace the placeholder with your own value.
172
-
export GRAFANA_NAME="<grafana-name>"
173
-
174
-
# Create Grafana instance
175
-
az grafana create \
176
-
--name $GRAFANA_NAME \
177
-
--resource-group $RESOURCE_GROUP
178
-
```
170
+
```azurecli-interactive
171
+
# Set an environment variable for the Grafana name. Make sure to replace the placeholder with your own value.
172
+
export GRAFANA_NAME="<grafana-name>"
173
+
174
+
# Create Grafana instance
175
+
az grafana create \
176
+
--name $GRAFANA_NAME \
177
+
--resource-group $RESOURCE_GROUP
178
+
```
179
179
180
180
### Place the Grafana and Azure Monitor resource IDs in variables
181
181
182
182
Use [az grafana show](/cli/azure/grafana#az-grafana-show) to place the Grafana resource ID in a variable. Use [az resource show](/cli/azure/resource#az-resource-show) to place the Azure Monitor resource ID in a variable. Replace **myGrafana** with the name of your Grafana instance.
183
183
184
-
```azurecli-interactive
185
-
grafanaId=$(az grafana show \
186
-
--name $GRAFANA_NAME \
184
+
```azurecli-interactive
185
+
grafanaId=$(az grafana show \
186
+
--name $GRAFANA_NAME \
187
+
--resource-group $RESOURCE_GROUP \
188
+
--query id \
189
+
--output tsv)
190
+
azuremonitorId=$(az resource show \
187
191
--resource-group $RESOURCE_GROUP \
192
+
--name $AZURE_MONITOR_NAME \
193
+
--resource-type "Microsoft.Monitor/accounts" \
188
194
--query id \
189
195
--output tsv)
190
-
azuremonitorId=$(az resource show \
191
-
--resource-group $RESOURCE_GROUP \
192
-
--name $AZURE_MONITOR_NAME \
193
-
--resource-type "Microsoft.Monitor/accounts" \
194
-
--query id \
195
-
--output tsv)
196
-
```
196
+
```
197
197
198
198
### Link Azure Monitor and Grafana to the AKS cluster
199
199
200
200
Use [az aks update](/cli/azure/aks#az-aks-update) to link the Azure Monitor and Grafana resources to your AKS cluster.
1. We have created sample dashboards. They can be found under the **Dashboards > Azure Managed Prometheus** folder. They have names like **"Kubernetes / Networking / `<name>`"**. The suite of dashboards includes:
236
236
* **Clusters:** shows Node-level metrics for your clusters.
0 commit comments