-
Notifications
You must be signed in to change notification settings - Fork 2.2k
[TRTLLM-8952][feat] Support Multi-Node Disagg Perf Test in CI #9138
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
chenfeiz0326
merged 3 commits into
NVIDIA:main
from
chenfeiz0326:chenfeiz/support-disagg-perf-test
Dec 26, 2025
Merged
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,76 @@ | ||
|
|
||
| cleanup_on_failure() { | ||
| echo "Error: $1" | ||
| scancel ${SLURM_JOB_ID} | ||
| exit 1 | ||
| } | ||
|
|
||
| mkdir -p $jobWorkspace | ||
| chmod +x $runScript | ||
| chmod +x $installScript | ||
|
|
||
| # Run installation on all nodes | ||
| echo "Running installation on all nodes..." | ||
| if ! srun "${srunArgs[@]}" $installScript &> $jobWorkspace/install.log; then | ||
| cleanup_on_failure "Failed to run installation. Check $jobWorkspace/install.log" | ||
| fi | ||
| echo "Installation completed on all nodes" | ||
|
|
||
| # Start gen servers | ||
| echo "Starting gen servers..." | ||
| for i in $(seq 0 $((numGenServers - 1))); do | ||
| gen_world_size=$((nodesPerGenServer * gpusPerNode)) | ||
| export DISAGG_SERVING_TYPE="GEN_$i" | ||
| export pytestCommand="$pytestCommandWorker" | ||
| srun "${srunArgs[@]}" --kill-on-bad-exit=1 \ | ||
| -N $nodesPerGenServer \ | ||
| --ntasks=$gen_world_size \ | ||
| --ntasks-per-node=$gpusPerNode \ | ||
| $runScript &> $jobWorkspace/gen_server_$i.log & | ||
| echo "Started gen server $i" | ||
| done | ||
|
|
||
| # Start ctx servers (skip if gen_only mode) | ||
| if [ "${TRTLLM_DISAGG_BENCHMARK_GEN_ONLY:-0}" != "1" ]; then | ||
| echo "Starting ctx servers..." | ||
| for i in $(seq 0 $((numCtxServers - 1))); do | ||
| ctx_world_size=$((nodesPerCtxServer * gpusPerNode)) | ||
| export DISAGG_SERVING_TYPE="CTX_$i" | ||
| export pytestCommand="$pytestCommandWorker" | ||
| srun "${srunArgs[@]}" --kill-on-bad-exit=1 \ | ||
| -N $nodesPerCtxServer \ | ||
| --ntasks=$ctx_world_size \ | ||
| --ntasks-per-node=$gpusPerNode \ | ||
| $runScript &> $jobWorkspace/ctx_server_$i.log & | ||
| echo "Started ctx server $i" | ||
| done | ||
| else | ||
| echo "Skipping ctx servers (gen_only mode)" | ||
| fi | ||
|
|
||
|
|
||
| # Start disagg server | ||
| echo "Starting disagg server..." | ||
| export DISAGG_SERVING_TYPE="DISAGG_SERVER" | ||
| export pytestCommand="$pytestCommandDisaggServer" | ||
| srun "${srunArgs[@]}" --kill-on-bad-exit=1 --overlap \ | ||
| -N 1 \ | ||
| --ntasks=1 \ | ||
| --ntasks-per-node=1 \ | ||
| $runScript &> $jobWorkspace/disagg_server.log & | ||
| echo "Started disagg server" | ||
|
|
||
| # Start benchmark | ||
| echo "Starting benchmark..." | ||
| export DISAGG_SERVING_TYPE="BENCHMARK" | ||
| export pytestCommand="$pytestCommandBenchmark" | ||
| if ! srun "${srunArgs[@]}" --kill-on-bad-exit=1 --overlap \ | ||
| -N 1 \ | ||
| --ntasks=1 \ | ||
| --ntasks-per-node=1 \ | ||
| $runScript; then | ||
| cleanup_on_failure "Benchmark failed. Check logs in ${jobWorkspace} for details" | ||
| fi | ||
|
|
||
| echo "Disagg server and benchmark completed successfully" | ||
| echo "Total runtime: $SECONDS seconds" |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.