Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Azure ARC - Monitoring on Worker Nodes
#To enable monitoring on the worker nodes
curl -o enable-monitoring.sh -L https://aka.ms/enable-monitoring-bash-script
subscriptionId="<subscriptionid>"
clusterName="<AzureArcName>"
resourceGroup="<ResourceGroupName>"
analyticsWorkspace="<AnalysticsWorkspaceName>"
kubeContext="<KubecontextName>"
azureArcClusterResourceId = "/subscriptions/$subscriptionId/resourceGroups/$resourceGroup/providers/Microsoft.Kubernetes/connectedClusters/$clusterName"
logAnalyticsWorkspaceResourceId="/subscriptions/$subscriptionId/resourceGroups/$resourceGroup/providers/Microsoft.OperationalInsights/workspaces/$analyticsWorkspace"
#Install script
bash enable-monitoring.sh --resource-id $azureArcClusterResourceId --kube-context $kubeContext --workspace-id $logAnalyticsWorkspaceResourceId
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment