Skip to content

fix(rollout): make engine port range start configurable via MILES_ROLLOUT_START_PORT#64

Open
zhihengy wants to merge 1 commit into
mainfrom
fix/rollout-start-port
Open

fix(rollout): make engine port range start configurable via MILES_ROLLOUT_START_PORT#64
zhihengy wants to merge 1 commit into
mainfrom
fix/rollout-start-port

Conversation

@zhihengy

Copy link
Copy Markdown
Collaborator

Problem

Engine port allocation scans upward from a hardcoded 15000, and the free-port probe misses servers bound to a specific interface (rather than 0.0.0.0). When two miles runs share a host, both claim the same port range: the second run's trainer connects to the first run's sglang engines and sends weight sync there, surfacing as an unrelated-looking Invalid device_uuid error mid-training.

Fix

Make the scan start configurable via MILES_ROLLOUT_START_PORT so concurrent runs on one host can use disjoint ranges (e.g. export MILES_ROLLOUT_START_PORT=16000 for the second run). Default stays 15000 — behavior is unchanged unless the variable is set.

Split out of the cosmos3 branch: this is host-level ops, orthogonal to any model adaptation.

🤖 Generated with Claude Code

zhihengy added a commit that referenced this pull request Jul 24, 2026
Host-level ops knob, orthogonal to the cosmos3 adaptation.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…LOUT_START_PORT

The engine port scan starts at a hardcoded 15000, and the free-port probe
misses servers bound to a specific interface. Two miles runs on one host
therefore claim the same port range, and the second run's weight sync
lands on the first run's engines (surfacing as "Invalid device_uuid").

Shifting the scan start per run keeps the ranges disjoint. Default is
unchanged.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@zhihengy
zhihengy force-pushed the fix/rollout-start-port branch from 4e46961 to 164429e Compare July 24, 2026 22:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant