| name | gpu-incident-triage |
| description | Triage a GPU HARDWARE incident on a K8s GPU node (Xid errors, NVLink faults, UnexpectedAdmissionError, allocatable drop, GPU fell off the bus): collect a deterministic evidence bundle (kernel NVRM/Xid via node debug pod, device-plugin and DCGM logs, driver-pod nvidia-smi, node state, admission events, GPU pod timeline), apply safe first-response (cordon), upload the bundle to Google Drive, and post a detailed issue to Slack #problem-of-thakicloud via qa-issue-dedup-poster with thread follow-ups. Use when "GPU 장애", "Xid 에러", "NVLink 오류", "GPU가 안 잡혀요", "UnexpectedAdmissionError", "allocatable 줄었다", "GPU requires reset", "노드 GPU 죽음", "gpu incident", "hardware fault triage". Do NOT use for GPU utilization/capacity questions (use h200-gpu-usage-inspector), app-level demo QA (use ai-platform-autoqa / demo-* RCA skills), or GPU purchase planning (use gpu-capacity-procurement-planner). |
GPU Incident Triage (하드웨어 사고 초동 대응)
2026-07-23 gpu-003 사고(Xid 74 NVLink fatal 3-GPU 동시 → Xid 79 bus 이탈 → 전 GPU ERR!)에서
검증된 절차를 스킬화. 수집·렌더는 코드 소유([[sonnet-format-determinism]]), 게시는 승인 게이트,
파괴적 조치(리부트·타 팀 포드 drain)는 하지 않는다 — 증거를 만들어 관리자에게 넘긴다.
절차 (순서 고정)
1. 수집 (결정론 수집기 — 무변경 read-only)
bash scripts/skills/gpu_incident_collect.sh <kube-context> <node> [tag]
산출: outputs/incidents/<date>-<node>-<tag>/ + zip. 포함: 커널 NVRM/Xid(journalctl, debug pod),
device-plugin/DCGM 로그, driver-pod nvidia-smi(-q 포함), node describe/yaml, admission 이벤트,
GPU 포드 타임라인. INCIDENT-SUMMARY.md를 손으로 추가(타임라인·판정·조치 이력 — 아래 4의 내용).
핵심 판독법:
Xid 79 = GPU fell off the bus (PCIe) — 개별 리셋 거의 불가, 리부트 표준.
Xid 74 = NVLink fatal. 여러 GPU·여러 링크 동시면 카드 불량이 아니라 브리지/패브릭 이벤트.
- device-plugin의
XidCriticalError ... marking device as unhealthy → allocatable 강등의 직접 원인.
- nvidia-smi에서
Unable to determine the device handle / ERR! / 프로세스 없는 메모리 좌초 확인.
- 사고 시각 전후 GPU 포드 타임라인으로 누가 그 시간대에 썼는지 정직하게 기록(상관≠인과 명시).
2. 안전 초동 조치 (가역만)
kubectl --context <ctx> cordon <node>
- ⛔ 타 팀 Running 포드 drain 금지(협의 사항으로 이슈에 기재). ⛔ 노드 리부트 직접 수행 금지(관리자).
- GPU 리셋은 시도 자체가 증거: NVLink 도메인은 페어 전체 리셋 요구 + off-bus GPU는 핸들 없음
→ 거부 메시지를 번들에 남기고 "리부트 필요"의 근거로 쓴다.
3. Drive 업로드 (열람 공개)
gws drive +upload "<abs>/<bundle>.zip" --format json
gws drive permissions create --params '{"fileId":"<FID>"}' --json '{"role":"reader","type":"anyone"}'
4. Slack 게시 (qa-issue-dedup-poster 경유 — 채널 오버라이드)
Skill: qa-issue-dedup-poster 워크플로를 따르되 --channel C0A9AUPQ62X(#problem-of-thakicloud):
sync → dedup → post.py 렌더(존댓말 합니다체, 확정/[추정] 구분, 테마 불릿) → --post.
--domain 인프라(박윤재 자동 태그) + 하드웨어 담당 --assignee(예: 김종원 U0A6KDMSTB5).
- 스레드 2건 필수: (1) Drive 번들 링크 + 핵심 요약(Xid 타임라인·현 상태·번들 구성),
(2) 조치 상황(수집/cordon/리셋 불가 근거/diag 보류 — 각 완료·불가·보류 명시).
- 게시는 사용자 승인 필수(Safety Gates). 렌더 드라이런을 먼저 보여준다.
5. 마무리
- 큐/노트에 사고 기록([[aps-failure-archaeology]] 인덱스 대상). 복구 확인 후
uncordon + 스레드에 종결 코멘트.
- 리부트 후 권장:
dcgmi diag -r 3, Xid 74 재발 시 NVLink 브리지 리시트/케이블 → RMA 경로.
gotchas (2026-07-23 실사고에서)
- busybox
dmesg는 권한 없음 → chroot /host journalctl -k 가 정답 (--profile=sysadmin 필수).
- 호스트 PATH에 nvidia-smi 없을 수 있음(
/run/nvidia/driver/usr/bin/) → driver daemonset 포드 exec가 안정.
- UnexpectedAdmissionError 크래시루프는 Deployment가 실패 포드를 수백 개 양산한다 →
원인 워크로드가 우리 것이면 deployment 즉시 삭제 +
delete pods --field-selector=status.phase=Failed.
- 사고 노드의 k8s상 Running 포드도 GPU 레벨에선 죽어 있을 수 있다(프로세스 없는 메모리 좌초) —
"Running이니 괜찮다"고 판단 금지, nvidia-smi가 정본.
- Slack user 토큰은 users.list/conversations.list 스코프가 없다 → 채널/유저 ID는 MCP
slack_search_channels/slack_search_users로 조회.