Skip to content

Commit 83f424e

Browse files
authored
Merge branch 'main' into xrfxlp/1597
2 parents e798696 + 15dfae9 commit 83f424e

1 file changed

Lines changed: 52 additions & 49 deletions

File tree

README.md

Lines changed: 52 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,12 @@
66

77
**NVSentinel detects and remediates GPU faults on Kubernetes nodes**
88

9-
A single bad GPU can silently corrupt a training run or leave a node sitting idle for hours before anyone notices. NVSentinel catches these faults as they happen, cordons and drains the affected node, then fixes it with a GPU reset or a reboot, and puts it back into service, no paging required.
9+
A single bad GPU can silently corrupt a training run or leave a node sitting idle for hours before anyone notices. NVSentinel **detects** faults as they happen, **protects** jobs by cordoning and draining the affected node, and **remediates** it with a GPU reset or a reboot, returning it to service with no paging required.
10+
11+
- 🔍 **Detect**: real-time GPU, NIC, and system-level fault detection via DCGM, syslog, and cloud provider maintenance events
12+
- 🛡️ **Protect**: cordon and drain the affected node before a fault spreads to other jobs
13+
- 🔧 **Remediate**: auto-repair with a targeted GPU reset or a full reboot, then bring the node back into service
14+
- 🧩 **Extensible**: pluggable health monitors, drain strategies, and remediation actions
1015

1116
> [!NOTE]
1217
> **Beta / Stable**
@@ -20,6 +25,8 @@ A single bad GPU can silently corrupt a training run or leave a node sitting idl
2025
- [cert-manager](https://cert-manager.io/) v1.19+
2126
- Persistent storage support for a database
2227

28+
The commands below get you ready for NVSentinel: the first makes sure the GPU Operator exposes DCGM as its own service, since NVSentinel queries it directly instead of going through dcgm-exporter; the second installs cert-manager, which issues the TLS certificates NVSentinel's webhooks and internal services need.
29+
2330
```bash
2431
# GPU Operator: enable DCGM standalone mode (required)
2532
# By default the GPU Operator embeds DCGM inside dcgm-exporter and doesn't
@@ -31,7 +38,7 @@ helm upgrade --install gpu-operator nvidia/gpu-operator \
3138
--set dcgm.enabled=true \
3239
--wait
3340

34-
# cert-manager (required)
41+
# cert-manager (required): issues TLS certs for NVSentinel's webhooks and internal gRPC
3542
helm repo add jetstack https://charts.jetstack.io --force-update
3643
helm upgrade --install cert-manager jetstack/cert-manager \
3744
--namespace cert-manager --create-namespace \
@@ -41,25 +48,26 @@ helm upgrade --install cert-manager jetstack/cert-manager \
4148

4249
## Quick Start
4350

44-
Most teams roll NVSentinel out in stages:
45-
46-
### Stage 1: Monitor
47-
48-
This turns on health monitoring only. NVSentinel watches your GPUs and system logs and reports faults as Kubernetes node conditions. It won't cordon a node, evict a pod or reboot a machine. Nothing here can disrupt a workload, so it's safe to run anywhere while you get a feel for what it reports. The defaults below are all you need.
49-
50-
> [!NOTE]
51-
> **Host installed drivers**
52-
> If your GPU nodes get their NVIDIA driver from the host image instead of the GPU Operator's driver DaemonSet, add `--set labeler.assumeDriverInstalled=true` to every NVSentinel install/upgrade command below.
51+
One command works for both a first install and every later upgrade. By default it only turns on health monitoring: it won't cordon a node, evict a pod, or reboot a machine, so it's safe to run anywhere. The flags below the command are everything you can layer on later; see [Adoption](#adoption) for what each one does.
5352

5453
```bash
5554
NVSENTINEL_VERSION=v1.20.0
5655

57-
# Drop the --set podMonitor.enabled=false flag if prometheus is installed
58-
helm install nvsentinel oci://ghcr.io/nvidia/nvsentinel \
56+
helm upgrade --install nvsentinel oci://ghcr.io/nvidia/nvsentinel \
5957
--version "$NVSENTINEL_VERSION" \
6058
--namespace nvsentinel --create-namespace \
6159
--set podMonitor.enabled=false \
6260
--wait
61+
62+
# --set labeler.assumeDriverInstalled=true # GPU nodes use host-installed drivers
63+
# --set global.mongodbStore.enabled=true # Protect: cordon
64+
# --set global.faultQuarantine.enabled=true # Protect: cordon
65+
# --set global.nodeDrainer.enabled=true # Protect: + drain
66+
# --set global.faultRemediation.enabled=true # Remediate
67+
# --set global.janitor.enabled=true # Remediate
68+
# --set global.janitorProvider.enabled=true # Remediate
69+
# --set janitor-provider.csp.provider=generic # Remediate
70+
# --set global.preflight.enabled=true # Preflight
6371
```
6472

6573
Verify it's running:
@@ -68,61 +76,56 @@ Verify it's running:
6876
kubectl get pods -n nvsentinel
6977
```
7078

71-
### Stage 2: Remediate
79+
## Adoption
80+
81+
We recommend starting with monitoring, then enabling one step at a time as you get comfortable with how NVSentinel runs in your environment.
7282

73-
Once you trust what it's reporting, turn on remediation too. NVSentinel will now cordon a faulty node, drain its workloads, and fix it automatically:
83+
### 1. Monitor
7484

75-
- Faults that don't need a full restart get an GPU reset, so the rest of the node's GPUs stay in service.
76-
- Everything else gets a node reboot.
85+
NVSentinel watches your GPUs and system logs and reports faults as Kubernetes node conditions. Nothing here can disrupt a workload, so it's the safe default to run anywhere while you get a feel for what it reports. The command above already does this; no extra flags needed.
7786

78-
By default, both actions run as a privileged job right on the node itself, so this works on day one with no cloud credentials to set up, on any infrastructure: on-prem, or any cloud.
87+
### 2a. Protect: Cordon and drain
88+
89+
Uncomment these flags:
7990

8091
```bash
81-
# Drop the --set podMonitor.enabled=false flag if prometheus is installed
82-
helm upgrade --install nvsentinel oci://ghcr.io/nvidia/nvsentinel \
83-
--version "$NVSENTINEL_VERSION" \
84-
--namespace nvsentinel --create-namespace \
85-
-f distros/kubernetes/nvsentinel/values-remediation.yaml \
86-
--set podMonitor.enabled=false \
87-
--wait
92+
--set global.mongodbStore.enabled=true \
93+
--set global.faultQuarantine.enabled=true \
94+
--set global.nodeDrainer.enabled=true
8895
```
8996

90-
To reboot nodes through your cloud provider's API instead, see the [cloud provider configuration guide](https://docs.nvidia.com/nvsentinel/configuration/janitor-provider/#cloud-provider-selection).
97+
NVSentinel will now cordon a faulty node, so your scheduler stops placing new work on it, and drain its existing workloads. Only want to cordon, without draining yet? Drop the `nodeDrainer` line above. This is as far as NVSentinel goes unless you also enable remediation below; a cordoned (and optionally drained) node stays isolated until you (or your own tooling) repair it.
9198

92-
Verify it's running:
99+
### 2b. Protect: Remediate
100+
101+
Remediation builds on Protect, so uncomment all of Protect's flags plus these:
93102

94103
```bash
95-
kubectl get pods -n nvsentinel
104+
--set global.faultRemediation.enabled=true \
105+
--set global.janitor.enabled=true \
106+
--set global.janitorProvider.enabled=true \
107+
--set janitor-provider.csp.provider=generic
96108
```
97109

98-
### Stage 3: Preflight (optional)
110+
NVSentinel will now reboot a faulty node automatically once it's cordoned and drained. This runs as a privileged job right on the node itself, so it works on day one with no credentials to set up, regardless of whether you're running on-prem or on a CSP. To reboot through your cloud provider's API instead, see the [cloud provider configuration guide](https://docs.nvidia.com/nvsentinel/configuration/janitor-provider/#cloud-provider-selection).
99111

100-
Preflight is an active check that runs as an init container in the workload pod to confirm the node is ready to take that workload. A job never lands on bad hardware in the first place.
112+
### 3. Preflight (optional)
101113

102-
Multi-node checks also need to know which pods belong to the same distributed job, so setup depends on the scheduler you use:
114+
Preflight tries to keep a job from ever landing on bad hardware. It runs as an active check, an init container in the workload pod, that confirms the node is ready before the job starts.
103115

104-
1. **Check your scheduler.** By default, NVSentinel uses Kubernetes' native gang scheduling, covered by [values-preflight-kube.yaml](distros/kubernetes/nvsentinel/values-preflight-kube.yaml) (Note: the `GenericWorkload` and `GangScheduling` feature gates should enabled by a cluster admin). For different schedulers (KAI, Volcano, etc.), see the [gang discovery guide](https://docs.nvidia.com/nvsentinel/configuration/preflight/#gang-discovery) for configuration options.
116+
Uncomment this flag:
105117

106-
2. **Enable preflight:**
107-
108-
```bash
109-
# Drop the --set podMonitor.enabled=false flag if prometheus is installed
110-
helm upgrade --install nvsentinel oci://ghcr.io/nvidia/nvsentinel \
111-
--version "$NVSENTINEL_VERSION" \
112-
--namespace nvsentinel --create-namespace \
113-
-f distros/kubernetes/nvsentinel/values-remediation.yaml \
114-
-f distros/kubernetes/nvsentinel/values-preflight-kube.yaml \
115-
--set podMonitor.enabled=false \
116-
--wait
117-
```
118+
```bash
119+
--set global.preflight.enabled=true
120+
```
118121

119-
Swap in your scheduler's values file from step 1 if you're not on native Kubernetes gang scheduling.
122+
This uses Kubernetes' native gang scheduling (the `GenericWorkload` and `GangScheduling` feature gates need to be enabled by a cluster admin). Using a different scheduler instead? See the [gang discovery guide](https://docs.nvidia.com/nvsentinel/configuration/preflight/#gang-discovery).
120123

121-
3. **Label the namespaces that should run it.** It's opt-in per namespace, so nothing changes until you do this:
124+
**Label the namespaces that should run it.** It's opt-in per namespace, so nothing changes until you do this:
122125

123-
```bash
124-
kubectl label namespace <your-namespace> nvsentinel.nvidia.com/preflight=enabled
125-
```
126+
```bash
127+
kubectl label namespace <your-namespace> nvsentinel.nvidia.com/preflight=enabled
128+
```
126129

127130
Verify it's running: submit a GPU pod in the labeled namespace, then check that preflight added its init containers.
128131

0 commit comments

Comments
 (0)