aicr-analyzing-snapshots

โดย nvidia

ใช้เมื่อวิเคราะห์ไฟล์ YAML สแนปช็อต AICR ตรวจสอบสถานะคลัสเตอร์ เปรียบเทียบคุณลักษณะของผู้ให้บริการ ดึงข้อมูลเชิงลึกเกี่ยวกับโทโพโลยี GPU/เครือข่าย หรือ…

npx skills add https://github.com/nvidia/aicr --skill aicr-analyzing-snapshots

Analyzing AICR Snapshots

Systematic analysis of AICR snapshot YAML files to extract cluster identity, provider characteristics, GPU topology, node health, software stack, and operational signals. Produces a structured Markdown report.

When to Use

  • User provides a snapshot YAML file for review
  • User asks about cluster characteristics or provider differentiation
  • User wants to compare snapshots or extract specific insights
  • User asks to generate a cluster assessment report

Analysis Procedure

Snapshot files are large (50K-80K+ tokens). Never read the whole file. Use mcp__plugin_context-mode_context-mode__execute_file with Python/YAML parsing to extract sections, or use targeted Read with offset/limit on specific line ranges found via Grep.

Step 1: Extract Metadata and Structure

import yaml
data = yaml.safe_load(FILE_CONTENT)
meta = data.get('metadata', {})
measurements = data.get('measurements', [])
print("=== METADATA ===")
for k, v in meta.items():
    print(f"  {k}: {v}")
print("\n=== MEASUREMENTS ===")
for m in measurements:
    subtypes = [s.get('subtype', s.get('name', '?')) for s in m.get('subtypes', [])]
    print(f"  {m['type']}: {subtypes}")

Step 2: Extract K8s Server and Node Info

Key fields for provider identification:

Field PathWhat It Reveals
K8s.server.versionK8s version + vendor suffix (-eks-, -gke, -aks, +lke)
K8s.node.providerMapped provider: eks, gke, aks, oke, lke, metal3, kind
K8s.node.provider-idRaw provider URI (aws://, gce://, azure://, oci://, linode://, metal3://)
K8s.node.kernel-versionKernel + arch indicator (e.g., -64k = ARM 64K pages)
K8s.node.container-runtime-*Runtime name and version
K8s.node.kubelet-versionKubelet version
K8s.node.os-imageOS description string

Provider detection logic:

provider-id prefixServiceNotes
aws://eksAmazon EKS
gce://gkeGoogle GKE
azure://aksAzure AKS
oci://okeOracle OKE
linode://lkeAkamai Cloud / Linode LKE
metal3://bare-metalMetal3/Ironic, self-managed
kind://kindLocal dev cluster
(none/other)anySelf-managed, check version string

If provider-id is absent, check K8s.server.version for vendor substrings.

Step 3: Extract GPU Info

Key fields from GPU.smi:

FieldExampleSignificance
gpu.modelNVIDIA GB300Maps to accelerator criteria
gpu.product-architectureBlackwellGPU generation
gpu-count4GPUs per node
driver580.126.16NVIDIA driver version
cuda-version13.0CUDA toolkit version
gpu.addressing-modeATSATS = unified CPU-GPU memory (Grace)
gpu.persistence-modeDisabled/EnabledShould be Enabled for production
gpu.vbios-version97.10.4A.00.1AFirmware version
gpu.gsp-firmware-version580.126.16GSP firmware

Accelerator mapping (checked in order, case-insensitive):

gpu.model containsAccelerator
gb200gb200 (check before b200)
gb300gb200 class (Blackwell NVL family)
b200b200
h100h100
gh200unresolved — Grace Hopper Superchip, not the discrete H200 GPU (check before h200)
h200h200 (discrete H200 GPU)
a100a100
l40sl40s
l40l40
rtx pro 6000rtx-pro-6000

Step 4: Extract OS Info

From OS.release: ID, VERSION_ID, PRETTY_NAME

From OS.grub: Boot parameters (check for iommu, console, init_on_free)

From OS.kmod: Loaded kernel modules (look for nvidia*, nv_peer_mem, gdrdrv, ib_*, mlx5_* for RDMA/InfiniBand)

From OS.sysctl (key tuning parameters):

SysctlGood Value for GPUWhy
vm.swappiness<= 10Minimize swapping for GPU workloads
vm.overcommit_memory1Allow overcommit for training
vm.nr_hugepages> 0 (ideal)Large page performance
fs.file-maxHigh (9223372036854775807)Sufficient file descriptors
kernel.threads-max> 1MSufficient threads
vm.min_free_kbytes> 1MMemory reserve

Step 5: Extract Node Topology

From NodeTopology.summary: node-count, taint-count, label-count

From NodeTopology.taint and NodeTopology.label, read the items list — one entry per distinct reading, sorted by key/value (taints: key/effect/value):

Item FieldWhat It Holds
context.keyTaint or label key, verbatim
context.valueTaint or label value (may be empty)
context.effectTaints only: NoSchedule, PreferNoSchedule, NoExecute
data.node-countTrue node total, including nodes dropped by truncation
data.node-listComma-separated node names (one of node-list / node-list-ref)
data.node-list-refKey into the subtype's data map whose entry holds the names (one of node-list / node-list-ref)
data.truncatedtrue when the node list is capped and ends with (+N more)

Current snapshots also carry the older data map on both subtypes; items is authoritative. Take counts from data.node-count rather than splitting node-list, and read data.truncated rather than probing for a (+N more) suffix. Use topology.LabelReadings / TaintReadings to resolve items into hydrated readings — they expand node-list-ref automatically, so callers do not need to implement the reference logic themselves.

Older snapshots (no items): fall back to the folded data map — effect|value|node1,node2,... for taints, value|node1,node2,... for labels. That encoding is lossy, so qualify anything derived from it:

  • A map key is ambiguous: when a key carries more than one value the value is folded into the key as <key>.<value>, indistinguishable from a label literally named that, and one of the colliding readings is dropped. Report such a key verbatim instead of asserting a key/value split.
  • A taint key disambiguated the same way ends in .<effect> and its value has only two fields (value|nodes); two taints sharing key and effect collapse into one entry.
  • summary.taint-count / label-count count map entries there, so they under-report wherever a collapse occurred, and node counts reflect only what survived truncation.

High-value labels to extract (skip feature.node.kubernetes.io/cpu-cpuid.*):

Label PrefixWhat It Reveals
kubernetes.io/arch.*CPU architecture (amd64 vs arm64 = heterogeneous)
nvidia.com/gpu.*GPU product, family, memory, compute, count, MIG state
nvidia.com/cuda.*CUDA driver/runtime versions
nvidia.com/mig.*MIG capable/config/strategy
nvidia.com/gpu.clique.*NVLink GPU cliques (multi-node NVLink domains)
resource.nvidia.com/computeDomainUnified compute domain
network.topology.nvidia.com/accelerator.*NVLink fabric blocks
node-type.*Hardware type (gb300, standard)
node-pool.*Pool assignment (gpu-pool, cpu-pool)
node.dgxc.nvidia.com/*DGX Cloud node classification
k8saas.nvidia.com/*K8SaaS management (NVSentinel cordon/uncordon)
dgxc.nvidia.com/nvsentinel-stateHealth state (remediation-failed, healthy)
nvsentinel.dgxc.nvidia.com/*NVSentinel component versions, driver state
network.nvidia.com/operator.*Network operator MOFED/NIC config state
metal3.io/uuid.*Metal3 bare-metal node UUIDs
workload.*Workload type (gpu, general)
feature.node.kubernetes.io/rdma.*RDMA available/capable
feature.node.kubernetes.io/network-sriov.*SR-IOV capability
feature.node.kubernetes.io/pci-15b3.*Mellanox ConnectX presence
feature.node.kubernetes.io/pci-10de.*NVIDIA GPU PCI presence
nvidia.com/dra-kubelet-pluginDRA (Dynamic Resource Allocation)

Step 6: Extract K8s Images and Policies

From K8s.image: All deployed container images and versions.

From K8s.policy: Flattened GPU Operator ClusterPolicy spec (dot-notation).

Key policy fields:

Policy FieldWhat to Check
driver.enabledGPU driver managed by operator
driver.versionDriver version in policy
driver.rdma.enabledRDMA support
toolkit.enabledContainer toolkit
devicePlugin.enabledDevice plugin active
dcgm.enabled / dcgmExporter.enabledGPU monitoring
migManager.enabledMIG management
ccManager.enabled / ccManager.defaultModeConfidential Computing
sandboxWorkloads.enabledSandbox/KubeVirt workloads
psa.enabledPod Security Admission
vfioManager.enabledVFIO passthrough

Step 7: Extract Slinky and MariaDB Conflict Signals

From K8s.slinky-slurm, report:

  • collection-state: absent, detected, unsupported-multicluster, or unknown
  • Controller count and projected NodeSet/LoginSet/RestApi/Accounting counts
  • Item identities and Controller associations; include only the allowlisted item data already present in the snapshot

detected means a Controller declaration exists, not that Slurm or its operator is healthy. Child items and counts are emitted only after all required APIs and references are collected conclusively; their absence is otherwise not confirmed absence. Never infer platform: slurm from this subtype.

From K8s.mariadb-operator, report collection-state as official MariaDB-operator API conflict evidence:

  • absent: official API group conclusively absent
  • api-detected: official API footprint present without observed MariaDB CRs
  • crs-detected: one or more official MariaDB CRs observed
  • unknown: discovery or List was inconclusive

These states do not prove database availability, operator health, or the existence of an external database such as RDS. Never infer accounting.databaseSource.

Step 8: Check SystemD Services

From SystemD.containerd.service, SystemD.kubelet.service, SystemD.docker.service:

FieldWhat to Check
ActiveStateShould be active
SubStateShould be running
LimitNOFILEFile descriptor limits
LimitMEMLOCKMemory lock limits (important for RDMA)
KillModeprocess for containerd (graceful)
Delegatetrue for containerd (cgroup delegation)
CPUAccountingResource accounting

Report Template

Structure the output as:

# Snapshot Analysis: {name}
> Source: {file} | Captured: {timestamp} | AICR: {version}

## Cluster Identity
Table: source-node, provider, K8s version, node count, GPU model, total GPUs

## Provider-Differentiating Insights
### 1. Provider Type (cloud vs bare-metal, managed vs self-managed)
### 2. CPU Architecture (homogeneous vs heterogeneous, ARM vs x86)
### 3. GPU Hardware (model, architecture, memory, driver, CUDA, MIG, persistence)
### 4. Network Topology (NVLink blocks, cliques, compute domains, RDMA, SR-IOV)
### 5. Management Layer (K8SaaS, NVSentinel health, cordon state)
### 6. Job Scheduling (Slurm/Slinky presence, HPC vs cloud-native)
### 7. Networking Stack (CNI, RDMA, SR-IOV, DOCA/MOFED)
### 8. Security (Confidential Computing, PSA, DRA)
### 9. Operational Signals (sysctl tuning, hugepages, persistence mode)

## Software Stack
### Key Container Images (table)
### OS and Kernel (table)

## Node Inventory
List nodes by rack/block/pool

## Operational Flags
Anything unusual: GPU health issues, disabled persistence mode,
missing hugepages, NVSentinel remediation failures, etc.

What Makes Each Provider Unique

Cloud Providers (EKS, GKE, AKS, OKE)

  • Provider-id with cloud prefix
  • Cloud-specific K8s version suffixes
  • Managed node groups / auto-scaling
  • No bare-metal labels (metal3.io)
  • Typically x86_64 homogeneous
  • No NVLink fabric topology labels
  • No Slurm/Slinky stack

Bare-Metal / DGX Cloud (Metal3, K8SaaS)

  • metal3:// provider-id with per-node UUIDs
  • k8saas.nvidia.com/* management labels
  • NVSentinel health monitoring (cordon/uncordon lifecycle)
  • NVLink accelerator blocks and GPU cliques
  • Compute domains spanning racks
  • ARM64 Grace CPUs (heterogeneous with x86 head node)
  • Slurm/Slinky HPC scheduling
  • RDMA + SR-IOV networking with DOCA drivers
  • ATS GPU addressing mode (unified memory)
  • Liquid-cooled chassis machine types (LCC in machine name)

Self-Managed / Kind

  • Missing or generic provider-id
  • No cloud or bare-metal management labels
  • Simpler topology (single node or small cluster)
  • Standard x86_64

AICR Criteria Mapping

After analysis, map the snapshot to AICR recipe criteria:

aicr recipe \
  --service {detected_service} \
  --accelerator {detected_accelerator} \
  --os {detected_os} \
  --intent {training|inference} \
  --snapshot {snapshot_file}
CriteriaExtracted FromValid Values
serviceK8s.node.provider / K8s.server.versioneks, gke, aks, oke, kind, lke
acceleratorGPU.smi.gpu.modelh100, h200, gb200, b200, a100, l40s, l40, rtx-pro-6000
osOS.release.IDubuntu, rhel, cos, amazonlinux, talos, ol
intentUser-specifiedtraining, inference
platformUser-specifieddynamo, kubeflow, nim, runai, slurm

Skills เพิ่มเติมจาก nvidia

compileiq-debug
nvidia
ใช้เมื่อมีบางอย่างผิดปกติ: Search() ค้าง, การประเมินทั้งหมดคืนค่า INVALID_SCORE, คะแนนไม่ดีขึ้น, ทุกคอนฟิกคืนค่าเลขเดียวกัน, ข้อผิดพลาด ptxas…
create-github-pr
nvidia
สร้างคำขอดึงข้อมูล GitHub โดยใช้ gh CLI ใช้เมื่อผู้ใช้ต้องการสร้าง PR ใหม่ ส่งโค้ดเพื่อตรวจสอบ หรือเปิดคำขอดึงข้อมูล คำหลักที่ใช้เรียก -…
nemoclaw-maintainer-cross-issue-sweep
nvidia
สแกน issue อื่นๆ ที่เปิดอยู่เพื่อค้นหาว่า PR ที่กำหนดอาจแก้ไขหรือทำให้เสียโดยไม่ได้ตั้งใจ แสดงผลโอกาสในการแก้ไขที่เกี่ยวข้องและความเสี่ยงที่ขัดแย้งกันพร้อมไฟล์:บรรทัด…
fhir-basics
nvidia
สอนให้เอเจนต์เข้าใจการทำงานของ FHIR R4 API ทรัพยากรที่มีให้ วิธีค้นหาด้วยพารามิเตอร์ค้นหา และวิธีแยกวิเคราะห์รูปแบบการตอบกลับทั้งหมดอย่างถูกต้อง…
compileiq-validate-result
nvidia
ใช้หลังจากที่การค้นหาเสร็จสิ้น และก่อนที่จะอ้างสิทธิ์การเร่งความเร็วหรือจัดส่ง ACF โหลดไฟล์ CSV dump_results แยกผู้สมัคร K อันดับแรก (วัตถุประสงค์เดียว)…
changelog-audit
nvidia
ตรวจสอบ Warp CHANGELOG.md ก่อนปล่อย: กู้คืนรายการที่สูญหาย จัดเรียงตามผลกระทบต่อผู้ใช้ ปรับปรุงภาษาในรายการ จัดบรรทัด และ (ในโหมดสาขาปล่อย) เปรียบเทียบการเพิ่มเวอร์ชัน…
maintain-dynamic-plugins
nvidia
ดูแล NeMo Relay dynamic plugin loaders, manifests, Rust native SDKs, gRPC worker protocol, Python worker SDK, เอกสาร, การทดสอบ และความครอบคลุมของเวิร์กโฟลว์การเผยแพร่
dgx-diagnose
nvidia
วินิจฉัยปัญหาทั่วไปของ DGX Station GB300 — CUDA ล่ม, การกำหนดเป้าหมาย GPU ผิด, บั๊กคอนเทนเนอร์ vLLM/SGLang, ปัญหาสถานะ MIG, ข้อผิดพลาด NVLink/Fabric Manager,…