external-gitcode-ascend-debug
Installation
Review the source and dependencies with a prompt. A package is available to download.
Install with an AI assistant
Copy the prompt so your assistant can review the pinned revision and dependencies first.
View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "external-gitcode-ascend-debug" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-cec978fdab6651f022f85c4ee7ab113c6a94bd145ab58b82559adbe71a001092. Verify the upstream source and version against https://github.com/ascend-ai-coding/awesome-ascend-skills before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.
Source and setup
github.com
Setup guidance pending
See the original source for supported tools, dependencies, and permissions.
Installation test pending
Provide a structured remote server troubleshooting workflow that supports context-aware environment checks and in-container debugging steps to locate and diagnose server-side issues.
Introduction source: third_party · ascend-ai-coding · 0.0.1 Reference
SkillPi interpretation
- Tasks
- Translation pending; see source documentation.
- Audience
- Translation pending; see source documentation.
- Software, accounts and paid services
- Translation pending; see source documentation.
- Testing
- Not tested
Browse files
Frontmatter
name: external-gitcode-ascend-debug
description: 结构化远程服务器问题排查流程,支持上下文感知的环境检查和容器内调试
original-name: ssh-dev-suite/debug
synced-from: https://gitcode.com/Ascend/agent-skills
synced-date: '2026-05-26'
synced-commit: 1f7666e7768a0ceb21bb1d40ce4b5179fcb6f1d6
license: UNKNOWNssh-debug
概述
引导agent按结构化流程排查远程服务器问题,避免盲目执行命令。所有远程命令通过connect/scripts/ssh-exec.sh执行。
适用场景
- 服务异常(进程崩溃、服务不可用)
- 性能问题(CPU/内存/磁盘/GPU)
- 部署失败排查
- 容器内应用调试
流程步骤
1. 确认目标
- 获取问题描述,确认profile和排查方向
- 产出:profile名称 + 问题分类
2. 上下文感知环境检查
- 读取本地工程文件推断依赖,动态生成检查项
- 基础检查:
uptime,df -h,free -m,top -bn1 | head -20 - 按规则表执行额外检查
- 产出:环境状态概览
3. 日志分析
- 定位日志:
journalctl -u <service> --since "1h ago",/var/log/ - 搜索关键词:
grep -i "error\|fatal\|exception" <log> | tail -50 - 容器:
docker logs <container> --tail 200
Token优化策略:
-
日志分析:先用grep搜索错误关键词,找到问题再扩展上下文
-
大日志文件:只读tail -50,不读全文
-
环境检查:输出摘要,不粘贴完整命令结果
-
产出:错误信息摘要
4. 深入排查
- 根据线索执行针对性命令,每次验证一个假设
- 检查配置文件、环境变量、依赖版本
- 产出:根因或最可能原因
5. 总结报告
- 输出发现(现象、根因、影响)和修复建议
- 产出:结构化排查报告
上下文感知规则表
| 检测到的依赖 | 额外检查命令 |
|---|---|
| PyTorch / TensorFlow | nvidia-smi, GPU显存占用 |
| 华为 CANN / MindSpore | npu-smi info, NPU状态 |
| Docker / docker-compose | docker ps -a, docker stats --no-stream |
| 数据库连接配置 | 连通性测试、活跃连接数 |
常用排查命令速查
| 场景 | 命令 |
|---|---|
| 进程 | ps aux \| grep <app>, systemctl status <svc> |
| 资源 | df -h, free -m, top -bn1 \| head -20 |
| 日志 | tail -100 <log>, journalctl -u <svc> --since "1h ago" |
| 网络 | ss -tlnp, curl -sv localhost:<port> |
| 容器 | docker logs <c> --tail 100, docker stats --no-stream |
| GPU | nvidia-smi, npu-smi info |
容器内调试
profile配置container字段时,ssh-exec.sh自动路由命令到容器内。注意:
- 容器内工具可能缺失,优先用基础命令(
cat,ls,env) - 需宿主机信息时,用不带container的profile
Token约束
- 日志分析:先grep错误关键词,再按需扩展上下文
- 环境检查:输出摘要而非完整命令结果
- 深入排查:每次验证一个假设,不批量执行命令
- 重复信息:不复述已知内容
Current listing version
0.0.1
Quality assessment
Out of 100 · Assessment report from SkillPi LAB.
Highlights
- 提供结构化远程服务器排查流程,覆盖服务异常、性能问题、部署失败等高频运维场景
- 支持上下文感知环境检查与容器内调试,显著提升运维效率
Highlights
- 触发描述精准完整,涵盖多种排查变体,边界清晰
Highlights
- Phase划分清晰,每步有明确产出物,包含端到端命令示例
- frontmatter完整,文档结构良好
Highlights
- 工具来源明确(ssh-exec.sh),参数正确
- 覆盖主要异常场景,Token优化策略有效控制输出
The arithmetic mean of the first four original scores, rounded to a whole number.
Static text checks
100 / 100 · skillpi-20261123-no-r3-v1
No current rules matched the text.
This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.
Permissions and checks before use
Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.
These common operations were not identified in the main document. This does not mean no permissions or risks exist.
Domains or addresses referenced in the document
These addresses may be documentation links or examples, not an approved network allowlist. Verify actual destinations and outgoing data before use.
- gitcode.com
Security rating and access scope
safe · Static evidence review; not a runtime safety guarantee.
Translation pending; see source documentation.
Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.
User discussion
No verified reviews yet.