[Bug]: MoRIIO WRITE: after the producer dies, decode requests hang until client timeout and KV usage stays elevated
Your current environment
- Stock
vllm/vllm-openai-rocm:v0.29.0(image IDsha256:e5e47f6aaab675c252c381f0dac237b31b10d87bb74d092b07fb4065efd7f5a1), no code changes;amd_mori 1.0.0. - 1 prefill + 1 decode node, each 8× AMD Instinct MI308X (gfx942), TP8. KV transfer over one ConnectX-7 NDR400 InfiniBand port (
mlx5_0, FW 28.43.8002). - Hosts: kernel 6.8.0-138-generic, amdgpu 6.16.13, ROCm 7.2.4.
- Model: GLM-5.3 FP8 (
glm_moe_dsa), local checkpoint. SHA256 ofconfig.json:3ac72612…572e69,tokenizer.json:19e77364…333a82d.
Collecting environment information...
==============================
System Info
==============================
OS : Ubuntu 22.04.5 LTS (x86_64)
GCC version : (Ubuntu 11.4.0-1ubuntu1~22.04.3) 11.4.0
Clang version : 22.0.0git (https://github.com/RadeonOpenCompute/llvm-project roc-7.2.3 26084 f58b06dce1f9c15707c5f808fd002e18c2accf7e)
CMake version : version 3.31.10
Libc version : glibc-2.35
==============================
PyTorch Info
==============================
PyTorch version : 2.12.0+git6bbd260
Is debug build : False
CUDA used to build PyTorch : N/A
ROCM used to build PyTorch : 7.2.53211
XPU used to build PyTorch : N/A
==============================
Python Environment
==============================
Python version : 3.12.13 (main, Mar 4 2026, 09:23:07) [GCC 11.4.0] (64-bit runtime)
Python platform : Linux-6.8.0-138-generic-x86_64-with-glibc2.35
==============================
CPU Info
==============================
Architecture: x86_64
CPU op-mode(s): 32-bit, 64-bit
Address sizes: 52 bits physical, 57 bits virtual
Byte Order: Little Endian
CPU(s): 192
On-line CPU(s) list: 0-191
Vendor ID: GenuineIntel
Model name: Intel(R) Xeon(R) Platinum 8469C
CPU family: 6
Model: 143
Thread(s) per core: 2
Core(s) per socket: 48
Socket(s): 2
Stepping: 8
CPU max MHz: 3800.0000
CPU min MHz: 800.0000
BogoMIPS: 5200.00
Flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc art arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf tsc_known_freq pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid dca sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch cpuid_fault epb cat_l3 cat_l2 cdp_l3 intel_ppin cdp_l2 ssbd mba ibrs ibpb stibp ibrs_enhanced tpr_shadow flexpriority ept vpid ept_ad fsgsbase tsc_adjust bmi1 avx2 smep bmi2 erms invpcid cqm rdt_a avx512f avx512dq rdseed adx smap avx512ifma clflushopt clwb intel_pt avx512cd sha_ni avx512bw avx512vl xsaveopt xsavec xgetbv1 xsaves cqm_llc cqm_occup_llc cqm_mbm_total cqm_mbm_local split_lock_detect user_shstk avx_vnni avx512_bf16 wbnoinvd dtherm ida arat pln pts hwp hwp_notify hwp_act_window hwp_epp hwp_pkg_req hfi vnmi avx512vbmi umip pku ospke waitpkg avx512_vbmi2 gfni vaes vpclmulqdq avx512_vnni avx512_bitalg tme avx512_vpopcntdq la57 rdpid bus_lock_detect cldemote movdiri movdir64b enqcmd fsrm md_clear serialize tsxldtrk pconfig arch_lbr ibt amx_bf16 avx512_fp16 amx_tile amx_int8 flush_l1d arch_capabilities ibpb_exit_to_user
Virtualization: VT-x
L1d cache: 4.5 MiB (96 instances)
L1i cache: 3 MiB (96 instances)
L2 cache: 192 MiB (96 instances)
L3 cache: 195 MiB (2 instances)
NUMA node(s): 2
NUMA node0 CPU(s): 0-47,96-143
NUMA node1 CPU(s): 48-95,144-191
Vulnerability Gather data sampling: Not affected
Vulnerability Indirect target selection: Not affected
Vulnerability Itlb multihit: Not affected
Vulnerability L1tf: Not affected
Vulnerability Mds: Not affected
Vulnerability Meltdown: Not affected
Vulnerability Mmio stale data: Not affected
Vulnerability Reg file data sampling: Not affected
Vulnerability Retbleed: Not affected
Vulnerability Spec rstack overflow: Not affected
Vulnerability Spec store bypass: Mitigation; Speculative Store Bypass disabled via prctl
Vulnerability Spectre v1: Mitigation; usercopy/swapgs barriers and __user pointer sanitization
Vulnerability Spectre v2: Mitigation; Enhanced / Automatic IBRS; IBPB conditional; PBRSB-eIBRS SW sequence; BHI BHI_DIS_S
Vulnerability Srbds: Not affected
Vulnerability Tsa: Not affected
Vulnerability Tsx async abort: Not affected
Vulnerability Vmscape: Mitigation; IBPB before exit to userspace
==============================
Versions of relevant libraries
==============================
[pip3] conch-triton-kernels==1.2.1
[pip3] numpy==2.3.5
[pip3] onnx==1.22.0
[pip3] onnx-ir==1.0.0
[pip3] onnxscript==0.7.1
[pip3] onnxslim==0.1.96
[pip3] pyzmq==27.2.0
[pip3] torch==2.12.0+git6bbd260
[pip3] torch_c_dlpack_ext==0.1.5
[pip3] torchaudio==2.11.0+34c52a6
[pip3] torchvision==0.27.1+df56172
[pip3] transformers==5.16.1
[pip3] triton==3.7.1+gitf0b55c07
[conda] Could not collect
==============================
vLLM Info
==============================
ROCM Version : 7.2.53211-c2d9476115
vLLM Version : 0.29.0
vLLM Build Flags:
CUDA Archs: Not Set; ROCm: Disabled; XPU: Disabled
GPU Topology:
============================ ROCm System Management Interface ============================
================================ Weight between two GPUs =================================
================================= Hops between two GPUs ==================================
=============================== Link Type between two GPUs ===============================
======================================= Numa Nodes =======================================
================================== End of ROCm SMI Log ===================================
==============================
Environment Variables
==============================
LD_LIBRARY_PATH=/opt/rocm/lib:/usr/local/lib:
PYTORCH_ROCM_ARCH=gfx90a;gfx942;gfx950;gfx1100;gfx1101;gfx1200;gfx1201;gfx1150;gfx1151
MAX_JOBS=16
PYTORCH_NVML_BASED_CUDA_CHECK=1
TORCHINDUCTOR_COMPILE_THREADS=1
TORCHINDUCTOR_CACHE_DIR=/tmp/torchinductor_rootDescribe the bug
With MoRIIO in WRITE mode, if the prefill (producer) instance dies while decode requests are waiting for KV, decode never fails those requests. They wait until the client gives up. After that, decode KV usage does not return to its idle level.
We reproduced this 3 times: once on Sep 28 and twice on Sep 29, each time after a fresh restart:
- Just before the kill, D reported
running=0,waiting=4(reason="deferred"), and KV usage went from 0 to 11.0998%. - We ran
docker killon the P container. All 4 clients got HTTP 200 stream headers but no tokens, then hit our 400 s client timeout. - D's
waitingthen dropped to 0, but KV usage stayed at 11.0998% for the rest of the observation (at least 295 s, no traffic). - D logged no MoRIIO error, and
/healthstayed 200. - Before each kill, a no-fault run of the same 4 requests completed 4/4 and KV usage returned to 0.
VLLM_MORIIO_TRANSFER_TIMEOUT_S=180 was set on D but had no effect. As far as we can tell, it is only used on the READ path.
| Run (UTC) | P killed | Clients timed out after | D waiting → 0 |
KV usage afterwards, no traffic |
|---|---|---|---|---|
| Sep 28 | 04:16:48 (fixed delay) | 400.1–400.2 s | ~04:23:16 | 11.0998% for 295 s |
| Sep 29 #1 | 17:31:40 (after 4 deferred) | 400.11–400.18 s | 17:38:20 | 11.0998% for 300 s |
| Sep 29 #2 | 17:56:06 (after 4 deferred) | 400.08–400.19 s | 18:02:47 | 11.0998% for 388 s |
Reproduction
- Start 1P1D with
MoRIIOConnectorin WRITE mode (config below) behind a P/D proxy. - Send 4 concurrent streaming
/v1/completionsrequests, each with 32768 prompt token IDs,max_tokens=512,ignore_eos=true,temperature=0. Confirm they complete and D'svllm:kv_cache_usage_percreturns to its baseline. - Send the same 4 requests with a 400 s client timeout. When D shows
vllm:num_requests_waiting_by_reason{reason="deferred"} == 4,docker killthe P container. - With no other traffic, poll D's
/metricsevery 5 s and watchvllm:num_requests_waitingandvllm:kv_cache_usage_perc.
Both nodes:
vllm serve <GLM-5.3 path> --served-model-name GLM5.2-FP8 --port 8100 \
--tensor-parallel-size 8 --kv-cache-dtype fp8_e4m3 --gpu-memory-utilization 0.80 \
--max-model-len 262144 --max-num-seqs 4 --max-num-batched-tokens 8192 \
--enable-chunked-prefill --no-enable-prefix-caching \
--linear-backend aiter --moe-backend aiter --seed 17 --enforce-eager \
--kv-transfer-config '<json below>'
MORI_RDMA_DEVICES=mlx5_0
MORI_IO_SQ_BACKOFF_TIMEOUT_US=60000000
VLLM_ROCM_USE_AITER=1
VLLM_ROCM_USE_AITER_FUSION_SHARED_EXPERTS=1
# decode only:
VLLM_MORIIO_TRANSFER_TIMEOUT_S=180kv_role is kv_producer on P and kv_consumer on D:
{
"kv_connector": "MoRIIOConnector",
"kv_role": "kv_producer",
"kv_connector_extra_config": {
"proxy_ip": "PROXY_HOST",
"proxy_ping_port": "36367",
"http_port": "8100",
"handshake_port": "6301",
"notify_port": "61005",
"host_ip": "HOST_IP",
"backend": "rdma",
"transfer_timeout": 120
}
}Prompts are a fixed sentence tokenized and repeated to 32768 IDs.
Questions
- When the producer dies, should D fail the waiting requests itself instead of relying on the client timeout?
- After P dies, how can D know the blocks are safe to reuse, i.e. that no late RDMA write will land? A timeout alone does not guarantee this.
- #58962 (by @amirakb89) adds a WRITE consumer watchdog with a 540 s default. In our case the client disconnected at ~400 s, and
request_finishedclears the watchdog. Would #58962 cover this case? We can test it on this setup.
Not measured
We only have the aggregate KV usage gauge. We did not trace block ownership, so we cannot say whether the blocks are leaked for good or freed later. We also did not capture whether an RDMA write was in flight at kill time, or any server-side terminal status. The timeout was on the client side.
Source: vllm-project/vllm