vllm-project/vllm · error · ValueError
enable_expert_parallel must be True to use EPLB.
Error message
enable_expert_parallel must be True to use EPLB.
What it means
EPLB rebalances experts across the expert-parallel (EP) group, so it presupposes expert parallelism. ParallelConfig raises when enable_eplb=True while enable_expert_parallel=False, since there is no EP group to balance over.
Source
Thrown at vllm/config/parallel.py:500
raise ValueError(
"data_parallel_external_lb can only be set when data_parallel_size > 1"
)
if not self.numa_bind and (
self.numa_bind_nodes is not None or self.numa_bind_cpus is not None
):
raise ValueError(
"numa_bind_nodes and numa_bind_cpus require numa_bind=True."
)
if self.enable_eplb:
if not current_platform.is_cuda_alike():
raise ValueError(
"Expert parallelism load balancing is only supported on "
"CUDA devices or ROCm devices now."
)
if not self.enable_expert_parallel:
raise ValueError("enable_expert_parallel must be True to use EPLB.")
# The EP group spans the TP x PCP x DP ranks. EPLB therefore needs
# TP, PCP, or DP > 1.
if (
self.tensor_parallel_size
* self.prefill_context_parallel_size
* self.data_parallel_size
<= 1
):
raise ValueError(
"EPLB requires tensor, prefill-context, or data parallelism, "
f"but got TP={self.tensor_parallel_size}, "
f"PCP={self.prefill_context_parallel_size}, "
f"DP={self.data_parallel_size}."
)
else:
if self.eplb_config.num_redundant_experts != 0:
raise ValueError(
"num_redundant_experts is set to "View on GitHub (pinned to c794754062)
Solutions
- Add --enable-expert-parallel together with --enable-eplb.
- If expert parallelism is not wanted, remove --enable-eplb and any eplb_config.
Example fix
# before vllm serve Mixtral-8x7B --enable-eplb # after vllm serve Mixtral-8x7B --enable-expert-parallel --enable-eplb
Defensive patterns
Strategy: validation
Validate before calling
def eplb_flags_valid(enable_eplb: bool, enable_expert_parallel: bool) -> bool:
return not enable_eplb or enable_expert_parallel
assert eplb_flags_valid(True, True) Prevention
- Treat --enable-expert-parallel as a prerequisite token: any script containing --enable-eplb must contain it too.
- Add a pre-launch grep assertion over the assembled arg list.
When it happens
Trigger: Launching a MoE model with --enable-eplb but without --enable-expert-parallel.
Common situations: Assuming EPLB turns on expert parallelism implicitly; enabling EPLB for its redundant-expert feature while forgetting the base EP flag in a long CLI invocation.
Related errors
- EPLB requires tensor, prefill-context, or data parallelism,
- Expert parallelism load balancing is only supported on CUDA
- num_redundant_experts is set to {self.eplb_config.num_redund
- Elastic EP is only supported with enable_eplb=True.
- multimodal preprocessing error: {0}
AI-assisted analysis of vllm-project/vllm@c794754062 (2026-08-14).
Data as JSON: /api/errors/42e377012128a0d6.
Report an issue: GitHub.