跳到主内容
智客 ZICQ

技能库 智客分类:运维与云 azure-diagnostics

Azure 诊断

Azure上使用AppLens,AzureMonitor,资源健康,安全分型的调试Azure生产问题. 当:调试生产问题,故障解答应用服务,应用服务高CPU,应用服务部署失败,故障解答容器应用,故障解答功能,故障解答AKS,VM RDP,Linux SSH,VM黑屏幕,无法连接到VM,重置VM密码,NSG或防火墙屏蔽,kubectl无法连接,kube-system/CoreDNS故障,cost待发,崩溃loop,节点不准备,升级故障,分析日志,KQL,透析,图像拉故障,冷起问题,健康探测故障,资源健康,出错的根源,故障解答事件中心,故障解答服务巴士,消息SDK错误,AMQ连接故障,消息锁丢失,服务巴士死信.

577704 安装量

官方网址:skills.sh

技能介绍

先看中文介绍;官方 description 原文单独保留,不改写 SKILL.md。

做什么

Azure上使用AppLens,AzureMonitor,资源健康,安全分型的调试Azure生产问题. 当:调试生产问题,故障解答应用服务,应用服务高CPU,应用服务部署失败,故障解答容器应用,故障解答功能,故障解答AKS,VM RDP,Linux SSH,VM黑屏幕,无法连接到VM,重置VM密码,NSG或防火墙屏蔽,kubectl无法连接,kube-system/CoreDNS故障,cost待发,崩溃loop,节点不准备,升级故障,分析日志,KQL,透析,图像拉故障,冷起问题,健康探测故障,资源健康,出错的根源,故障解答事件中心,故障解答服务巴士,消息SDK错误,AMQ连接故障,消息锁丢失,服务巴士死信.

何时用

官方 description 未单独写出 Use when。按规范,代理会在用户任务与这段 description 的关键词匹配时激活本技能。

代理如何加载

按 Agent Skills 渐进披露:启动时只加载 name 与 description(约 100 token);任务匹配后才读入整份 SKILL.md 正文;scripts/、references/、assets/ 仅在需要时再读。 本文件正文结构:Azure Diagnostics、Triggers、Rules、Quick Diagnosis Flow、Troubleshooting Guides by Service、Routing。

文件分析

文件分析:除 SKILL.md 外,正文引用了 references/container-apps/README.md、references/app-service/README.md、references/functions/README.md、references/kql-queries.md、references/azure-resource-graph.md,属于带资源的技能包,这些文件按需再读。

官方 description(原文)

Debug Azure production issues on Azure using AppLens, Azure Monitor, resource health, and safe triage. WHEN: debug production issues, troubleshoot app service, app service high CPU, app service deployment failure, troubleshoot container apps, troubleshoot functions, troubleshoot AKS, VM RDP, Linux SSH, VM black screen, can't connect to VM, reset VM password, NSG or firewall blocking, kubectl cannot connect, kube-system/CoreDNS failures, pod pending, crashloop, node not ready, upgrade failures, analyze logs, KQL, insights, image pull failures, cold start issues, health probe failures, resource health, root cause of errors, troubleshoot event hubs, troubleshoot service bus, messaging SDK error, AMQP connection failure, message lock lost, service bus dead letter.

Azure DiagnosticsTriggersRulesQuick Diagnosis FlowTroubleshooting Guides by ServiceRoutingQuick ReferenceCommon Diagnostic CommandsCheck resource healthView activity logContainer Apps logsFunction App logs (query App Insights traces)

· 许可:MIT

来源分类:skills.sh agent-skill

SKILL.md 与 Agent 调用

官方规范 ↗
name
azure-diagnostics
description
Debug Azure production issues on Azure using AppLens, Azure Monitor, resource health, and safe triage. WHEN: debug production issues, troubleshoot app service, app service high CPU, app service deployment failure, troubleshoot container apps, troubleshoot functions, troubleshoot AKS, VM RDP, Linux SSH, VM black screen, can't connect to VM, reset VM password, NSG or firewall blocking, kubectl cannot connect, kube-system/CoreDNS failures, pod pending, crashloop, node not ready, upgrade failures, analyze logs, KQL, insights, image pull failures, cold start issues, health probe failures, resource health, root cause of errors, troubleshoot event hubs, troubleshoot service bus, messaging SDK error, AMQP connection failure, message lock lost, service bus dead letter.
许可
MIT
  1. 发现技能客户端向 Agent 提供名称与描述目录。
  2. 匹配与调用用户指定或任务匹配后,载入 SKILL.md 指令。
  3. 按需加载按步骤读取参考文档、使用脚本与素材。
指令中引用的文件 · 5
  • references/container-apps/README.md
  • references/app-service/README.md
  • references/functions/README.md
  • references/kql-queries.md
  • references/azure-resource-graph.md

以下路径提取自原文;文件是否齐全请以来源仓库中的完整目录为准。

具体调用语法与可用工具以目标 Agent 客户端为准。 查看调用机制说明 ↗

安装这个技能

Skills CLI ↗

先选择目标 Agent 和安装范围,保留技能包的附属文件,安装后检查客户端能否发现该技能。

该技能引用了附属文件,请从来源获取完整目录;仅复制 SKILL.md 可能缺少依赖。

交给 Agent 安装

复制安装指令给支持 Agent Skills 的代理,确认其中的目标目录与客户端匹配。

把 Agent Skill「azure-diagnostics」安装到我的项目:SKILL.md 原文与官方 description 见 https://zicq.com/zh/skills/skl-dfae502674053c2e-Azure-%E8%AF%8A%E6%96%AD.html
请存为 .cursor/skills/azure-diagnostics/SKILL.md 或 .claude/skills/azure-diagnostics/SKILL.md,frontmatter 的 name 与 description 保持原样,不要改写。
该技能还带 scripts/、references/、assets/ 等文件,请从 https://github.com/microsoft/azure-skills 取完整目录,不要只建一个 SKILL.md。

GitHub 完整包 ↗

终端安装 · Skills CLI

需要 Node.js 与 npx。先查看仓库技能列表,确认实际名称。

npx skills add 'https://github.com/microsoft/azure-skills' --list

npx skills add 'https://github.com/microsoft/azure-skills' --skill 'azure-diagnostics'

CLI 会交互选择目标 Agent,默认安装到项目;用户级安装使用 -g。先通过查看命令核对仓库内容,再用 npx skills list 检查已安装技能。

阅读排版
--- name: azure-diagnostics description: "Debug Azure production issues on Azure using AppLens, Azure Monitor, resource health, and safe triage. WHEN: debug production issues, troubleshoot app service, app service high CPU, app service deployment failure, troubleshoot container apps, troubleshoot functions, troubleshoot AKS, VM RDP, Linux SSH, VM black screen, can't connect to VM, reset VM password, NSG or firewall blocking, kubectl cannot connect, kube-system/CoreDNS failures, pod pending, crashloop, node not ready, upgrade failures, analyze logs, KQL, insights, image pull failures, cold start issues, health probe failures, resource health, root cause of errors, troubleshoot event hubs, troubleshoot service bus, messaging SDK error, AMQP connection failure, message lock lost, service bus dead letter." license: MIT metadata: author: Microsoft version: "1.2.6" --- # Azure Diagnostics > **AUTHORITATIVE GUIDANCE — MANDATORY COMPLIANCE** > > This document is the **official source** for debugging and troubleshooting Azure production issues. Follow these instructions to diagnose and resolve common Azure service problems systematically. ## Triggers Activate this skill when user wants to: - Debug or troubleshoot production issues - Diagnose errors in Azure services - Analyze application logs or metrics - Fix image pull, cold start, or health probe issues - Investigate why Azure resources are failing - Find root cause of application errors - Troubleshoot App Service issues (high CPU, deployment failures, crashes, slow responses, TLS/custom domains) - Respond to prompts like "troubleshoot app service", "app service high CPU", or "app service deployment failure" - Troubleshoot Azure Function Apps (invocation failures, timeouts, binding errors) - Find the App Insights or Log Analytics workspace linked to a Function App - Troubleshoot AKS clusters, nodes, pods, ingress, or Kubernetes networking issues - Troubleshoot Azure VM connectivity issues (RDP/SSH failures, port 3389/22 timeouts, NSG or firewall blocking, credential resets) - Troubleshoot Azure Messaging SDK issues (Event Hubs, Service Bus connection failures, AMQP errors, message lock issues) ## Rules 1. Start with systematic diagnosis flow 2. Use AppLens (MCP) for AI-powered diagnostics when available 3. Check resource health before deep-diving into logs 4. Select appropriate troubleshooting guide based on service type 5. Document findings and attempted remediation steps 6. Route AKS incidents to the dedicated AKS troubleshooting document --- ## Quick Diagnosis Flow 1. **Identify symptoms** - What's failing? 2. **Check resource health** - Is Azure healthy? 3. **Review logs** - What do logs show? 4. **Analyze metrics** - Performance patterns? 5. **Investigate recent changes** - What changed? --- ## Troubleshooting Guides by Service | Service | Common Issues | Reference | |---------|---------------|-----------| | **Container Apps** | Image pull failures, cold starts, health probes, port mismatches | [container-apps/](references/container-apps/README.md) | | **App Service** | High CPU, deployment failures, crashes, slow responses, TLS/custom domains | [app-service/](references/app-service/README.md) | | **Function Apps** | App details, invocation failures, timeouts, binding errors, cold starts, missing app settings | [functions/](references/functions/README.md) | | **AKS** | Cluster access, nodes, `kube-system`, scheduling, crash loops, ingress, DNS, upgrades | [AKS Troubleshooting](troubleshooting/aks/aks-troubleshooting.md) | | **Compute** | VM RDP/SSH connectivity, NSG/firewall blocks, credential resets, VM agent/tooling issues | [VM Connectivity Troubleshooting](troubleshooting/compute/vm-troubleshooting.md) | | **Messaging** | Event Hubs & Service Bus SDK errors, AMQP failures, message lock, connectivity | [Messaging Troubleshooting](troubleshooting/messaging/README.md) | --- ## Routing - Keep Container Apps and Function Apps diagnostics in this parent skill. - Route active AKS incidents, AKS-specific intake, evidence gathering, and remediation guidance to [AKS Troubleshooting](troubleshooting/aks/aks-troubleshooting.md). - Route Azure VM RDP/SSH connectivity, NSG/firewall, credential reset, and VM agent troubleshooting to [VM Connectivity Troubleshooting](troubleshooting/compute/vm-troubleshooting.md). - Route Azure Messaging SDK troubleshooting (Event Hubs, Service Bus) to [Messaging Troubleshooting](troubleshooting/messaging/README.md). --- ## Quick Reference ### Common Diagnostic Commands ```bash # Check resource health az resource show --ids RESOURCE_ID # View activity log az monitor activity-log list -g RG --max-events 20 # Container Apps logs az containerapp logs show --name APP -g RG --follow # Function App logs (query App Insights traces) az monitor app-insights query --apps APP-INSIGHTS -g RG \ --analytics-query "traces | where timestamp > ago(1h) | order by timestamp desc | take 50" ``` ### AppLens (MCP Tools) For AI-powered diagnostics, use: ``` mcp_azure_mcp_applens intent: "diagnose issues with " command: "diagnose" parameters: resourceId: "" Provides: - Automated issue detection - Root cause analysis - Remediation recommendations ``` ### Azure Monitor (MCP Tools) For querying logs and metrics: ``` mcp_azure_mcp_monitor intent: "query logs for " command: "logs_query" parameters: workspaceId: "" query: "" ``` See [kql-queries.md](references/kql-queries.md) for common diagnostic queries. --- ## Check Azure Resource Health ### Using MCP ``` mcp_azure_mcp_resourcehealth intent: "check health status of " command: "get" parameters: resourceId: "" ``` ### Using CLI ```bash # Check specific resource health az resource show --ids RESOURCE_ID # Check recent activity az monitor activity-log list -g RG --max-events 20 ``` --- ## References - [KQL Query Library](references/kql-queries.md) - [Azure Resource Graph Queries](references/azure-resource-graph.md) - [App Service Troubleshooting](references/app-service/README.md) - [Function Apps Troubleshooting](references/functions/README.md) - [VM Connectivity Troubleshooting](troubleshooting/compute/vm-troubleshooting.md) - [Messaging Troubleshooting](troubleshooting/messaging/README.md)

相关技能

运维与云

Docker 要点Docker Essentials

用于容器管理,图像操作,调试的基本道克命令和工作流程.

运维与云

查找技能Find Skills

从开放的代理技能生态系统中发现并安装技能. 使用时:(1)用户问"我如何做X",X可能拥有现有技能,(2)用户说"为X找到技能"或"是否为X有技能",(3)用户问"你能否做X",X是专门能力,(4)用户想扩展代理能力,(5)用户想搜索工具,模板,或工作流程,(6)用户提到他们希望…

运维与云

Azure 准备Azure Prepare

准备 azd 用于部署的Azure项目:为Azure开发者CLI(azd)工作流程生成azure.yaml,基础设施(Bicep/Terraform)和多克文件. 仅当用户明确想要使用 azd 作为部署工具时使用, 或项目已经有一个 azure 。 雅姆尔文件。 不使用: 非az…

运维与云

Azure 验证Azure Validate

阿苏雷战备部署前论证. 深入检查配置、基础设施(Bicep或Terraform)、RBAC角色分配、管理身份许可以及部署前的先决条件。 当:验证我的应用,检查部署准备,运行飞行前检查,验证配置,检查是否准备好部署,验证azure.yaml,验证Bicep,在部署前测试,故障排除部…