Initial commit (with migration template)

This commit is contained in:
JK Woo
2026-07-17 15:37:40 +00:00
commit 6cfbe6dcb5
63 changed files with 4992 additions and 0 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,594 @@
{
"annotations": {
"list": [
{
"builtIn": 1,
"datasource": {
"type": "datasource",
"uid": "grafana"
},
"enable": true,
"hide": true,
"name": "Annotations & Alerts",
"type": "dashboard"
}
]
},
"editable": true,
"fiscalYearStartMonth": 0,
"graphTooltip": 0,
"id": null,
"links": [],
"liveNow": false,
"panels": [
{
"collapsed": false,
"gridPos": {
"h": 4,
"w": 6,
"x": 0,
"y": 0
},
"id": 1,
"title": "TOTAL POWER",
"type": "stat",
"datasource": {
"type": "prometheus"
},
"targets": [
{
"datasource": {
"type": "prometheus"
},
"editorMode": "code",
"expr": "sum(DCGM_FI_DEV_POWER_USAGE)",
"legendFormat": "sum across all GPUs",
"range": true,
"refId": "A"
}
],
"fieldConfig": {
"defaults": {
"color": {
"mode": "continuous-GrYlRd"
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null },
{ "color": "yellow", "value": 500 },
{ "color": "red", "value": 1000 }
]
},
"unit": "watt"
},
"overrides": []
},
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"textMode": "value_and_name"
}
},
{
"collapsed": false,
"gridPos": {
"h": 4,
"w": 6,
"x": 6,
"y": 0
},
"id": 2,
"title": "MEAN GPU UTIL",
"type": "stat",
"datasource": {
"type": "prometheus"
},
"targets": [
{
"datasource": {
"type": "prometheus"
},
"editorMode": "code",
"expr": "avg(DCGM_FI_DEV_GPU_UTIL)",
"legendFormat": "average of all devices",
"range": true,
"refId": "A"
}
],
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null },
{ "color": "yellow", "value": 60 },
{ "color": "red", "value": 85 }
]
},
"unit": "percent"
},
"overrides": []
},
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"textMode": "value_and_name"
}
},
{
"collapsed": false,
"gridPos": {
"h": 4,
"w": 6,
"x": 12,
"y": 0
},
"id": 3,
"title": "CLUSTER MEMORY",
"type": "stat",
"datasource": {
"type": "prometheus"
},
"targets": [
{
"datasource": {
"type": "prometheus"
},
"editorMode": "code",
"expr": "sum(DCGM_FI_DEV_FB_USED)",
"legendFormat": "used / total (UMA)",
"range": true,
"refId": "A"
}
],
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null }
]
},
"unit": "megabytes"
},
"overrides": [
{
"matcher": {
"id": "byName",
"options": "Value"
},
"properties": [
{
"id": "unit",
"value": "custom: / 479 GiB"
}
]
}
]
},
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"textMode": "value_and_name"
}
},
{
"collapsed": false,
"gridPos": {
"h": 4,
"w": 6,
"x": 18,
"y": 0
},
"id": 4,
"title": "HOTTEST GPU",
"type": "stat",
"datasource": {
"type": "prometheus"
},
"targets": [
{
"datasource": {
"type": "prometheus"
},
"editorMode": "code",
"expr": "max(DCGM_FI_DEV_GPU_TEMP)",
"legendFormat": "hottest device",
"range": true,
"refId": "A"
}
],
"fieldConfig": {
"defaults": {
"color": {
"mode": "continuous-GrYlRd"
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null },
{ "color": "yellow", "value": 65 },
{ "color": "red", "value": 80 }
]
},
"unit": "celsius"
},
"overrides": []
},
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"textMode": "value_and_name"
}
},
{
"collapsed": false,
"gridPos": {
"h": 7,
"w": 12,
"x": 0,
"y": 4
},
"id": 5,
"title": "• JOCODING1 (HEAD)",
"type": "stat",
"datasource": {
"type": "prometheus"
},
"targets": [
{
"expr": "DCGM_FI_DEV_POWER_USAGE{instance=\"192.168.0.99:9400\"}",
"legendFormat": "POWER",
"refId": "A"
},
{
"expr": "DCGM_FI_DEV_GPU_UTIL{instance=\"192.168.0.99:9400\"}",
"legendFormat": "GPU",
"refId": "B"
},
{
"expr": "DCGM_FI_DEV_GPU_TEMP{instance=\"192.168.0.99:9400\"}",
"legendFormat": "TEMP",
"refId": "C"
},
{
"expr": "DCGM_FI_DEV_SM_CLOCK{instance=\"192.168.0.99:9400\"}",
"legendFormat": "SM CLK",
"refId": "D"
}
],
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null }
]
}
},
"overrides": [
{
"matcher": {
"id": "byName",
"options": "POWER"
},
"properties": [
{ "id": "unit", "value": "watt" }
]
},
{
"matcher": {
"id": "byName",
"options": "GPU"
},
"properties": [
{ "id": "unit", "value": "percent" }
]
},
{
"matcher": {
"id": "byName",
"options": "TEMP"
},
"properties": [
{ "id": "unit", "value": "celsius" }
]
},
{
"matcher": {
"id": "byName",
"options": "SM CLK"
},
"properties": [
{ "id": "unit", "value": "megahertz" }
]
}
]
},
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "horizontal",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"textMode": "value_and_name"
}
},
{
"collapsed": false,
"gridPos": {
"h": 7,
"w": 12,
"x": 12,
"y": 4
},
"id": 6,
"title": "• JOCODING2",
"type": "stat",
"datasource": {
"type": "prometheus"
},
"targets": [
{
"expr": "DCGM_FI_DEV_POWER_USAGE{instance=\"192.168.0.100:9400\"}",
"legendFormat": "POWER",
"refId": "A"
},
{
"expr": "DCGM_FI_DEV_GPU_UTIL{instance=\"192.168.0.100:9400\"}",
"legendFormat": "GPU",
"refId": "B"
},
{
"expr": "DCGM_FI_DEV_GPU_TEMP{instance=\"192.168.0.100:9400\"}",
"legendFormat": "TEMP",
"refId": "C"
},
{
"expr": "DCGM_FI_DEV_SM_CLOCK{instance=\"192.168.0.100:9400\"}",
"legendFormat": "SM CLK",
"refId": "D"
}
],
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null }
]
}
},
"overrides": [
{
"matcher": {
"id": "byName",
"options": "POWER"
},
"properties": [
{ "id": "unit", "value": "watt" }
]
},
{
"matcher": {
"id": "byName",
"options": "GPU"
},
"properties": [
{ "id": "unit", "value": "percent" }
]
},
{
"matcher": {
"id": "byName",
"options": "TEMP"
},
"properties": [
{ "id": "unit", "value": "celsius" }
]
},
{
"matcher": {
"id": "byName",
"options": "SM CLK"
},
"properties": [
{ "id": "unit", "value": "megahertz" }
]
}
]
},
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "horizontal",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"textMode": "value_and_name"
}
},
{
"collapsed": false,
"gridPos": {
"h": 7,
"w": 12,
"x": 0,
"y": 11
},
"id": 7,
"title": "• JOCODING3 (OFFLINE)",
"type": "stat",
"datasource": {
"type": "prometheus"
},
"targets": [],
"fieldConfig": {
"defaults": {
"color": {
"mode": "fixed",
"fixedColor": "dark-red"
},
"mappings": [
{
"options": {
"match": "null",
"result": {
"text": "N/A"
}
},
"type": "special"
}
]
},
"overrides": []
},
"options": {
"colorMode": "background",
"graphMode": "none",
"justifyMode": "center",
"orientation": "auto",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"textMode": "value"
}
},
{
"collapsed": false,
"gridPos": {
"h": 7,
"w": 12,
"x": 12,
"y": 11
},
"id": 8,
"title": "• JOCODING4 (OFFLINE)",
"type": "stat",
"datasource": {
"type": "prometheus"
},
"targets": [],
"fieldConfig": {
"defaults": {
"color": {
"mode": "fixed",
"fixedColor": "dark-red"
},
"mappings": [
{
"options": {
"match": "null",
"result": {
"text": "N/A"
}
},
"type": "special"
}
]
},
"overrides": []
},
"options": {
"colorMode": "background",
"graphMode": "none",
"justifyMode": "center",
"orientation": "auto",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"textMode": "value"
}
}
],
"refresh": "5s",
"schemaVersion": 38,
"style": "dark",
"tags": [],
"templating": {
"list": []
},
"time": {
"from": "now-15m",
"to": "now"
},
"timepicker": {},
"timezone": "",
"title": "GB10 CLUSTER - LIVE MONITOR",
"uid": "gb10_live_monitor",
"version": 1
}

View File

@@ -0,0 +1,36 @@
version: '3.8'
services:
prometheus:
image: prom/prometheus:latest
container_name: litellm-prometheus
volumes:
- ./prometheus/prometheus.yml:/etc/prometheus/prometheus.yml
ports:
- "9090:9090"
extra_hosts:
- "host.docker.internal:host-gateway"
command:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--web.cors.origin=.*'
restart: always
networks:
- litellm-network
grafana:
image: grafana/grafana:latest
container_name: litellm-grafana
ports:
- "3000:3000"
volumes:
- grafana-storage:/var/lib/grafana
restart: always
networks:
- litellm-network
volumes:
grafana-storage:
networks:
litellm-network:
external: true

View File

@@ -0,0 +1,5 @@
#!/bin/bash
docker rm -f node-exporter dcgm-exporter 2>/dev/null || true
docker run -d --name=node-exporter --restart=always --net="host" --pid="host" -v "/:/host:ro,rslave" quay.io/prometheus/node-exporter:latest --path.rootfs=/host
docker run -d --name=dcgm-exporter --restart=always --gpus all -p 9400:9400 nvcr.io/nvidia/k8s/dcgm-exporter:3.3.5-3.4.0-ubuntu22.04
docker ps -f name=node-exporter -f name=dcgm-exporter

View File

@@ -0,0 +1,21 @@
global:
scrape_interval: 15s
evaluation_interval: 15s
scrape_configs:
- job_name: 'litellm-proxy'
metrics_path: '/metrics'
static_configs:
- targets: ['litellm:4000']
- job_name: 'dgx-node-metrics'
static_configs:
- targets:
- '192.168.0.99:9100'
- '192.168.0.100:9100'
- job_name: 'dgx-gpu-metrics'
static_configs:
- targets:
- '192.168.0.99:9400'
- '192.168.0.100:9400'