azure-diagnostics
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseAzure Diagnostics
Azure 诊断
AUTHORITATIVE GUIDANCE — MANDATORY COMPLIANCEThis document is the official source for debugging and troubleshooting Azure production issues. Follow these instructions to diagnose and resolve common Azure service problems systematically.
权威指南 — 强制合规本文档是调试和排查Azure生产环境问题的官方参考资料。请按照以下说明系统性地诊断和解决常见Azure服务问题。
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
当用户有以下需求时,启用此技能:
- 调试或排查生产环境问题
- 诊断Azure服务中的错误
- 分析应用日志或指标
- 修复镜像拉取、冷启动或健康探针问题
- 调查Azure资源故障原因
- 查找应用错误的根本原因
Rules
规则
- Start with systematic diagnosis flow
- Use AppLens (MCP) for AI-powered diagnostics when available
- Check resource health before deep-diving into logs
- Select appropriate troubleshooting guide based on service type
- Document findings and attempted remediation steps
- 从系统性诊断流程开始
- 若可用,使用AppLens (MCP)进行AI驱动的诊断
- 在深入分析日志前先检查资源健康状态
- 根据服务类型选择合适的故障排除指南
- 记录诊断结果和已尝试的修复步骤
Quick Diagnosis Flow
快速诊断流程
- Identify symptoms - What's failing?
- Check resource health - Is Azure healthy?
- Review logs - What do logs show?
- Analyze metrics - Performance patterns?
- Investigate recent changes - What changed?
- 识别症状 - 哪些功能出现故障?
- 检查资源健康状态 - Azure服务是否正常?
- 查看日志 - 日志中显示了什么信息?
- 分析指标 - 性能模式是否有异常?
- 调查近期变更 - 最近有哪些变更操作?
Troubleshooting Guides by Service
按服务分类的故障排除指南
| Service | Common Issues | Reference |
|---|---|---|
| Container Apps | Image pull failures, cold starts, health probes, port mismatches | container-apps/ |
| 服务 | 常见问题 | 参考链接 |
|---|---|---|
| Container Apps | 镜像拉取失败、冷启动、健康探针故障、端口不匹配 | container-apps/ |
Quick Reference
快速参考
Common Diagnostic Commands
常用诊断命令
bash
undefinedbash
undefinedCheck resource health
检查资源健康状态
az resource show --ids RESOURCE_ID
az resource show --ids RESOURCE_ID
View activity log
查看活动日志
az monitor activity-log list -g RG --max-events 20
az monitor activity-log list -g RG --max-events 20
Container Apps logs
Container Apps 日志
az containerapp logs show --name APP -g RG --follow
undefinedaz containerapp logs show --name APP -g RG --follow
undefinedAppLens (MCP Tools)
AppLens (MCP 工具)
For AI-powered diagnostics, use:
mcp_azure_mcp_applens
intent: "diagnose issues with <resource-name>"
command: "diagnose"
parameters:
resourceId: "<resource-id>"
Provides:
- Automated issue detection
- Root cause analysis
- Remediation recommendations如需AI驱动的诊断,请使用:
mcp_azure_mcp_applens
intent: "diagnose issues with <resource-name>"
command: "diagnose"
parameters:
resourceId: "<resource-id>"功能包括:
- 自动检测问题
- 根本原因分析
- 修复建议
Azure Monitor (MCP Tools)
Azure Monitor (MCP 工具)
For querying logs and metrics:
mcp_azure_mcp_monitor
intent: "query logs for <resource-name>"
command: "logs_query"
parameters:
workspaceId: "<workspace-id>"
query: "<KQL-query>"See kql-queries.md for common diagnostic queries.
如需查询日志和指标,请使用:
mcp_azure_mcp_monitor
intent: "query logs for <resource-name>"
command: "logs_query"
parameters:
workspaceId: "<workspace-id>"
query: "<KQL-query>"常见诊断查询请参考 kql-queries.md。
Check Azure Resource Health
检查Azure资源健康状态
Using MCP
使用MCP
mcp_azure_mcp_resourcehealth
intent: "check health status of <resource-name>"
command: "get"
parameters:
resourceId: "<resource-id>"mcp_azure_mcp_resourcehealth
intent: "check health status of <resource-name>"
command: "get"
parameters:
resourceId: "<resource-id>"Using CLI
使用CLI
bash
undefinedbash
undefinedCheck specific resource health
检查特定资源健康状态
az resource show --ids RESOURCE_ID
az resource show --ids RESOURCE_ID
Check recent activity
查看近期活动
az monitor activity-log list -g RG --max-events 20
---az monitor activity-log list -g RG --max-events 20
---References
参考资料
- KQL Query Library
- KQL 查询库