帮助排查 Microsoft Fabric 中 Spark 作业失败、会话异常与性能瓶颈
复制安装指令,让 AI 自动完成配置 · 推荐新手
请帮我安装 askskill 上的 "spark-operations-cli" 技能: 1. 下载 https://raw.githubusercontent.com/microsoft/skills-for-fabric/main/skills/spark-operations-cli/SKILL.md 2. 保存为 ~/.claude/skills/spark-operations-cli/SKILL.md 3. 装好后重载技能,告诉我可以用了
请帮我诊断 Microsoft Fabric 中失败的 Spark 笔记本运行,检查失败原因、驱动与执行器日志,并总结可执行的修复建议。
返回失败根因、关键日志线索,以及对应的修复建议清单。
请排查 Fabric 中一个一直停留在 starting 状态的 Livy 会话,判断是资源不足、初始化失败还是依赖问题,并给出下一步建议。
输出会话异常原因判断、相关状态与日志依据,以及建议的处理步骤。
请分析这个 Spark 作业是否存在执行器 OOM、shuffle spill 或数据倾斜问题,并结合 Spark Advisor 结果给出优化方向。
给出性能瓶颈定位结果、可能成因,以及可落地的优化建议。
Update Check — ONCE PER SESSION (mandatory) The first time this skill is used in a session, run the check-updates skill before proceeding.
- GitHub Copilot CLI / VS Code: invoke the
check-updatesskill.- Claude Code / Cowork / Cursor / Windsurf / Codex: compare local vs remote package.json version.
- Skip if the check was already performed earlier in this session.
CRITICAL NOTES
- To find the workspace details (including its ID) from workspace name: list all workspaces and, then, use JMESPath filtering
- To find the item details (including its ID) from workspace ID, item type, and item name: list all items of that type in that workspace and, then, use JMESPath filtering
- Skill disambiguation:
spark-operations-cliis for read-only triage and diagnosis of existing jobs and sessions. For creating notebooks, running new jobs, or Spark development, usespark-authoring-cli. For interactive PySpark analysis and Livy session creation, usespark-consumption-cli.
This skill provides diagnostics for Microsoft Fabric Spark job failures, Livy session health, and performance bottlenecks using Fabric REST APIs and CLI tools (az rest). All diagnostic operations are read-only; session cleanup (e.g., stopping zombie sessions) requires explicit user confirmation. For Spark development and notebook authoring, use spark-authoring-cli. For interactive PySpark analysis, use spark-consumption-cli.
The TOC is grouped by purpose. Start at Diagnostic Workflows when triaging an active failure; the earlier sections are foundational references.
| Task | Reference | Notes |
|---|---|---|
| Fabric Topology & Key Concepts | COMMON-CORE.md § Fabric Topology & Key Concepts | |
| Environment URLs | COMMON-CORE.md § Environment URLs | |
| Authentication & Token Acquisition | COMMON-CORE.md § Authentication & Token Acquisition | Wrong audience = 401; read before any auth issue |
| Core Control-Plane REST APIs | COMMON-CORE.md § Core Control-Plane REST APIs | |
| Pagination | COMMON-CORE.md § Pagination | |
| Long-Running Operations (LRO) | COMMON-CORE.md § Long-Running Operations (LRO) | |
| Rate Limiting & Throttling | COMMON-CORE.md § Rate Limiting & Throttling | |
| Job Execution | COMMON-CORE.md § Job Execution | |
| Capacity Management | COMMON-CORE.md § Capacity Management | |
| Gotchas & Troubleshooting | COMMON-CORE.md § Gotchas & Troubleshooting | |
| Best Practices | COMMON-CORE.md § Best Practices |
| Task | Reference | Notes |
|---|---|---|
| Tool Selection Rationale | COMMON-CLI.md § Tool Selection Rationale | |
| Finding Workspaces and Items in Fabric | COMMON-CLI.md § Finding Workspaces and Items in Fabric | Mandatory — READ link first [needed for finding workspace id by its name or item id by its name, item type, and workspace id] |
| Authentication Recipes | COMMON-CLI.md § Authentication Recipes | az login flows and token acquisition |
…
帮助你查询 Fabric Eventhouse 数据、分析时序趋势并监控摄取状态。
通过 REST API 创建、更新并发布 Microsoft Fabric Eventstream 实时流拓扑。
帮助你列出、解析并检查 Microsoft Fabric Eventstream 的拓扑与配置状态。
用自然语言查询 Power BI 报表与仪表板,快速获得业务数据答案。
通过命令行对 Fabric 仓库与湖仓数据执行只读 T-SQL 查询、探查与导出。
帮助将 Azure Synapse Spark 工作负载迁移到 Microsoft Fabric 并完成代码替换。
通过 PySpark 与 Livy 会话交互分析 Lakehouse 数据,支持高级计算与跨仓查询。
帮助你开发 Microsoft Fabric Spark 工作流、编写调试 Notebook 代码并管理湖仓与资源。
提供本地有状态 Spark 会话,便于用 PySpark 与 SQL 探索和验证数据。
通过命令行分析 Fabric 数据仓库性能瓶颈并给出优化建议。
用自然语言查询 Spark 历史服务中的应用、作业、阶段与性能指标。
通过自然语言查询 Microsoft Fabric 工作区、表、作业和依赖关系