Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
558482d
feat: initial benchmarking wrapper in-cluster work
hhzhang16 Sep 8, 2025
7cc6edb
Merge branch 'main' of github.com:ai-dynamo/dynamo into hannahz/dyn-9…
hhzhang16 Sep 18, 2025
5a09233
feat: update benchmark job for in-cluster benchmarking following late…
hhzhang16 Sep 18, 2025
8f19a4d
feat: update in-cluster benchmark job and yaml
hhzhang16 Sep 19, 2025
3ff6675
feat: enhance GPT OSS frontend with improved harmony tool calling par…
zhongdaor-nv Sep 18, 2025
9482320
feat(operator): mechanism for disabling imagePullSecrets discovery (#…
tmonty12 Sep 18, 2025
f7cc9e9
refactor: simplify Dockerfile.vllm, enable local-dev for all framewor…
keivenchang Sep 19, 2025
d5f0495
feat: Request Cancellation unary request support (#3004)
kthui Sep 19, 2025
1648836
build: update trtllm to v1.1.0rc5 to enable trtllm + KVBM integration…
richardhuo-nv Sep 19, 2025
91181f6
build: OPS-597, OPS-861 restructure TRT-LLM to follow container strat…
nv-tusharma Sep 19, 2025
89e074c
feat: Sglang canary health check (#3103)
tzulingk Sep 19, 2025
271ef47
feat: Convert message[content] from list to string. (#3067)
KrishnanPrash Sep 19, 2025
f79e57b
feat: KVBM connector : enabling vectorized copy from pinned memory to…
oandreeva-nv Sep 19, 2025
8ee077f
feat: update READMe commands
hhzhang16 Sep 19, 2025
4ac8147
feat: update READMe commands
hhzhang16 Sep 19, 2025
e7ed272
Merge branch 'main' of github.com:ai-dynamo/dynamo into hannahz/dyn-9…
hhzhang16 Sep 19, 2025
534ba19
docs: move in-cluster benchmarking doc to the overall benchmarking do…
hhzhang16 Sep 19, 2025
0235ece
feat: minor adjustments based on self look-through and coderabbit com…
hhzhang16 Sep 19, 2025
b392205
Merge branch 'main' of github.com:ai-dynamo/dynamo into hannahz/dyn-9…
hhzhang16 Sep 22, 2025
ef92388
docs: add benchmarking cross-namespace
hhzhang16 Sep 22, 2025
69bcfa8
docs: have user modify benchmark job instead of using envsubst
hhzhang16 Sep 22, 2025
e83590b
docs: add tldr
hhzhang16 Sep 22, 2025
efd16d6
docs: minor doc updates
hhzhang16 Sep 22, 2025
ae9e70e
Merge branch 'main' of github.com:ai-dynamo/dynamo into hannahz/dyn-9…
hhzhang16 Sep 22, 2025
5131348
docs: update k8s-related stuff in benchmarking.md
hhzhang16 Sep 23, 2025
38955ef
Merge branch 'main' into hannahz/dyn-973-allow-in-cluster-perf-benchm…
hhzhang16 Sep 23, 2025
a5e5b18
docs: updating client-side prereqs
hhzhang16 Sep 23, 2025
de853cf
Merge branch 'main' of github.com:ai-dynamo/dynamo into hannahz/dyn-9…
hhzhang16 Sep 23, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
feat: update in-cluster benchmark job and yaml
Signed-off-by: Hannah Zhang <[email protected]>
  • Loading branch information
hhzhang16 committed Sep 19, 2025
commit 8f19a4d7cb9bcccfd0bd359283d591da80671236
89 changes: 43 additions & 46 deletions benchmarks/incluster/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,70 +29,64 @@ The in-cluster benchmarking solution:
## Prerequisites

1. **Kubernetes cluster** with NVIDIA GPUs and Dynamo namespace setup (see [Dynamo Cloud/Platform docs](../../docs/guides/dynamo_deploy/README.md))
2. **dynamo-pvc** PersistentVolumeClaim configured (see [deploy/utils README](../../deploy/utils/README.md))
3. **Service account** (`dynamo-sa`) with appropriate permissions (see [deploy/utils README](../../deploy/utils/README.md))
4. **Docker image** containing the Dynamo benchmarking tools
2. **Storage and service account** PersistentVolumeClaim and service account configured with appropriate permissions (see [deploy/utils README](../../deploy/utils/README.md))
3. **Docker image** containing the Dynamo benchmarking tools

## Quick Start

### Step 1: Deploy Your DynamoGraphDeployment
Deploy your DynamoGraphDeployment using the [deployment documentation](../../components/backends/). Ensure it has a frontend service exposed.

### Step 2: Deploy and Run Benchmark Job

**Option A: Set environment variables (recommended for multiple commands)**
```bash
# Deploy the benchmark job with your namespace
NAMESPACE=your-namespace envsubst < benchmark_job.yaml | kubectl apply -f -
# Set environment variables for your deployment
export NAMESPACE=benchmarking
export MODEL_NAME=Qwen/Qwen3-0.6B
export INPUT_NAME=qwen-vllm-agg
export SERVICE_URL=vllm-agg-frontend:8000
export DOCKER_IMAGE=nvcr.io/nvidian/dynamo-dev/vllm-runtime:dyn-973.0

# Deploy the benchmark job
envsubst < benchmark_job.yaml | kubectl apply -f -

# Monitor the job
kubectl logs -f job/dynamo-benchmark -n your-namespace
kubectl logs -f job/dynamo-benchmark -n $NAMESPACE

# Check job status
kubectl get jobs -n your-namespace
kubectl get jobs -n $NAMESPACE
```

**Option B: One-liner deployment**
```bash
NAMESPACE=benchmarking MODEL_NAME=Qwen/Qwen3-0.6B INPUT_NAME=qwen-vllm-agg SERVICE_URL=vllm-agg-frontend:8000 DOCKER_IMAGE=nvcr.io/nvidian/dynamo-dev/vllm-runtime:dyn-973.0 envsubst < benchmark_job.yaml | kubectl apply -f -
```

### Step 3: Retrieve Results
```bash
# Download results from PVC (recommended)
python3 -m deploy.utils.download_pvc_results \
--namespace your-namespace \
--namespace $NAMESPACE \
--output-dir ./benchmark_results \
--folder /data/results \
--no-config

# Alternative: Copy results directly (requires pod name)
kubectl cp <pod-name>:/data/results ./benchmark_results -n your-namespace
kubectl cp <pod-name>:/data/results ./benchmark_results -n $NAMESPACE
```

## Configuration

The job manifest uses these default parameters:
- **Model**: `Qwen/Qwen3-0.6B`
- **Input sequence length**: 2000 tokens
- **Output sequence length**: 256 tokens
- **Input**: `dsr1=${NAMESPACE}-dsr1-frontend:8000` (internal service URL)

### Customizing the Job Manifest

Edit `benchmark_job.yaml` to modify:

```yaml
# Change model
args:
- --model
- "meta-llama/Meta-Llama-3-8B"

# Change sequence lengths
args:
- --isl
- "1500"
- --osl
- "200"

# Change input service
args:
- --input
- my-service=${NAMESPACE}-my-service:8000
```
The benchmark job is fully configurable through environment variables:

### Required Environment Variables

- **NAMESPACE**: Kubernetes namespace where the benchmark will run
- **MODEL_NAME**: Hugging Face model identifier (e.g., `Qwen/Qwen3-0.6B`)
- **INPUT_NAME**: Name identifier for the benchmark input (e.g., `qwen-agg`)
- **SERVICE_URL**: Internal service URL for the DynamoGraphDeployment frontend
- **DOCKER_IMAGE**: Docker image containing the Dynamo benchmarking tools

## Understanding Your Results

Expand All @@ -118,26 +112,26 @@ Results are stored in `/data/results` and follow the same structure as local ben

### Check Job Status
```bash
kubectl get jobs -n <namespace>
kubectl describe job dynamo-benchmark -n <namespace>
kubectl get jobs -n $NAMESPACE
kubectl describe job dynamo-benchmark -n $NAMESPACE
```

### View Logs
```bash
# Follow logs in real-time
kubectl logs -f job/dynamo-benchmark -n <namespace>
kubectl logs -f job/dynamo-benchmark -n $NAMESPACE

# Get logs from specific container
kubectl logs job/dynamo-benchmark -c benchmark-runner -n <namespace>
kubectl logs job/dynamo-benchmark -c benchmark-runner -n $NAMESPACE
```

### Debug Failed Jobs
```bash
# Check pod status
kubectl get pods -n <namespace> -l job-name=dynamo-benchmark
kubectl get pods -n $NAMESPACE -l job-name=dynamo-benchmark

# Describe failed pod
kubectl describe pod <pod-name> -n <namespace>
kubectl describe pod <pod-name> -n $NAMESPACE
```

## Comparison with Local Benchmarking
Expand Down Expand Up @@ -171,11 +165,14 @@ The in-cluster approach is recommended for:

```bash
# Check PVC status
kubectl get pvc dynamo-pvc -n <namespace>
kubectl get pvc dynamo-pvc -n $NAMESPACE

# Verify service account
kubectl get sa dynamo-sa -n <namespace>
kubectl get sa dynamo-sa -n $NAMESPACE

# Check service endpoints
kubectl get svc -n <namespace>
kubectl get svc -n $NAMESPACE

# Verify your service URL is accessible
kubectl get svc $SERVICE_URL -n $NAMESPACE
```
6 changes: 3 additions & 3 deletions benchmarks/incluster/benchmark_job.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ spec:
- name: docker-imagepullsecret
containers:
- name: benchmark-runner
image: nvcr.io/nvidia/ai-dynamo/vllm-runtime:0.5.0
image: ${DOCKER_IMAGE}
resources:
requests:
cpu: "4"
Expand All @@ -35,7 +35,7 @@ spec:
command: ["python3", "-m", "benchmarks.utils.benchmark"]
args:
- --model
- deepseek-ai/DeepSeek-R1
- ${MODEL_NAME}
- --isl
- "2000"
- --std
Expand All @@ -45,7 +45,7 @@ spec:
- --output-dir
- /data/results
- --input
- dsr1=${NAMESPACE}-sgl-dsr1-8gpu-frontend:8000
- ${INPUT_NAME}=${SERVICE_URL}
volumeMounts:
- name: data-volume
mountPath: /data
Expand Down