[GH-ISSUE #2049] Deterministic deadlock at the completion handshake after the last block: host at layer step 48 with the GPU already rang - 5/5 stalls identical, on 0.1.41 and 0.1.43 (RTX 4080 / Windows / IQ3_XXS native pack / 256K) #818

Closed
opened 2026-11-04 01:46:11 +07:00 by bsakaguchi · 6 comments
Owner

Originally created by @gaoyonghui123 on GitHub (Oct 12, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/2049

Summary

The STRATA_WATCHDOG_S watchdog (#29) fires every time, because the request makes no host-side progress for the full 60 s. But the stall is not slow I/O, not memory pressure and not a version regression. All five occurrences freeze at exactly the same point - the handshake after the model's last block:

verify window (last window, not the current stage): 6 tokens at position 88089,
    host at layer step 48; the GPU rang 48; flags: served 48, plan (A) 48, copies (B) 48
  expert pool: epoch 439406, batch epoch 439406: 18 of 18 jobs claimed, 18 done; 5 of 5 workers parked, 5 sleeping; mode 0
  expert pool threads: w0=sleeping w1=sleeping w2=sleeping w3=sleeping w4=sleeping; host idle for 61509 ms

This model has 48 blocks (blk.0 .. blk.47 in the pack's index.txt), so layer step 48 is one past the last layer. At that moment:

  • the GPU has already rung 48 (served 48, plan (A) 48, copies (B) 48)
  • the expert pool has nothing in flight (18 jobs claimed, 18 done, epoch == batch epoch)
  • all 5 pool workers are parked / sleeping
  • yet the host stays blocked for 61 s and never returns

The whole forward pass has completed on the device and the host simply never gets past step 48.

Not a 0.1.43 regression

# engine engine started context position host idle
1 0.1.41 2026-10-10 08:43:08 183,045 61,657 ms
2 0.1.41 2026-10-10 14:43:49 107,264 61,478 ms
3 0.1.41 2026-10-10 14:51:44 121,757 61,306 ms
4 0.1.43 2026-10-12 12:21:31 88,089 61,491 ms
5 0.1.43 2026-10-12 12:48:42 106,983 61,509 ms

Identical signature in all five, across two releases. Downgrading does not help - 0.1.41 shows it three times.

On Windows the manifestation is Application Error 1000 on strata.exe, exception 0xc0000409 (the report code for abort() / __fastfail), same faulting offset 0x52f519 in both 0.1.43 occurrences.

Ruled out

  • Slow I/O (#1407): the no step finished for %d s, but the file tier is still being read branch never fired - grep -c "no step finished" is 0 across the whole log, so STRATA_WATCHDOG_IO_S is not involved.
  • Memory pressure: committed is 56,158-57,912 MiB against a 63.2 GiB guard with 16,150-19,527 MiB still available; resident actually fell from 30.3 GiB (occurrence 4) to 16.8 GiB (occurrence 5).
  • The NaN guard (#879) added in 0.1.43: non-finite logits never appears in the log.
  • A single unlucky run: 5/5 identical, and occurrences 4 and 5 were 8 minutes apart within one session.

Environment

Engine   : 0.1.43 (also reproduced on 0.1.41)
OS       : Windows 11
GPU      : NVIDIA RTX 4080 (sm_89, 16 GB; display on iGPU)
CPU      : AMD Ryzen 7 7800X3D
RAM      : 64 GB
Model    : Swift-Qwen3.8-Flash-Next-GSQ-RCO-IQ3_XXS (native IQ3_XXS pack), 48 blocks
Launch   : --max-context 262144 --kv int8 --mmap-experts --spec 6 --mtp <path> --spec-min-p 0.7
           --pool-workers 5 --resident-budget-gib 40 --pcie-frac 0.5 --vram-reserve-mib 768
           --kv-resident 20480 --conversation-cache-mib 8192 --conversation-cache-slots 4
           --conversation-cache-min-free-mib 1024

No non-default value the watchdog could be sensitive to; this is the documented 256K configuration.

Reproducibility

Every occurrence needs a long session. Short A/B segments (a few minutes each) never hit it. On 0.1.43 the first appeared ~25 min into a session and the second 8 min after the automatic restart. The trigger therefore looks tied to long sessions at large context positions (88K-183K) rather than to any single request shape.

  • #1234 - same stall class reported on 0.1.39 / RTX 4090 (stage "decode -1"). Ours freezes at stage "request -1", and the new information here is that the site is deterministic and identical across versions.
  • #29 - the watchdog itself. Its design is working as intended here (it turns a permanent hang into a 60 s hiccup plus an automatic restart), so this report is about what it is catching, not a request to turn it off.
  • DETAILS.md ("Generation stops mid-answer...") asks for the thread stacks and says "attach both". Both parts are attached: five strata-stall-<pid>.dmp files, and one text file with all five stall reports.

Attachments

  • E:\AI\Strata\strata-stall-13600.dmp (359,712 B)
  • E:\AI\Strata\strata-stall-22336.dmp (355,289 B)
  • E:\AI\Strata\strata-stall-23088.dmp (355,289 B)
  • E:\AI\Strata\strata-stall-27724.dmp (357,605 B)
  • E:\AI\Strata\strata-stall-30728.dmp (362,028 B)
  • _issue_strata_stall_excerpt.txt - all five stall reports in one file

strata-stall-13600.dmp
strata-stall-22336.dmp
strata-stall-23088.dmp
strata-stall-27724.dmp
strata-stall-30728.dmp

_issue_strata_stall_excerpt.txt

Originally created by @gaoyonghui123 on GitHub (Oct 12, 2026). Original GitHub issue: https://github.com/Niko1221/Strata/issues/2049 ## Summary The `STRATA_WATCHDOG_S` watchdog (#29) fires every time, because the request makes **no host-side progress for the full 60 s**. But the stall is **not** slow I/O, **not** memory pressure and **not** a version regression. All five occurrences freeze at **exactly the same point** - the handshake after the model's last block: ``` verify window (last window, not the current stage): 6 tokens at position 88089, host at layer step 48; the GPU rang 48; flags: served 48, plan (A) 48, copies (B) 48 expert pool: epoch 439406, batch epoch 439406: 18 of 18 jobs claimed, 18 done; 5 of 5 workers parked, 5 sleeping; mode 0 expert pool threads: w0=sleeping w1=sleeping w2=sleeping w3=sleeping w4=sleeping; host idle for 61509 ms ``` This model has **48 blocks** (`blk.0` .. `blk.47` in the pack's `index.txt`), so **`layer step 48` is one past the last layer**. At that moment: - the GPU has already rung 48 (`served 48, plan (A) 48, copies (B) 48`) - the expert pool has **nothing in flight** (18 jobs claimed, 18 done, `epoch == batch epoch`) - all 5 pool workers are `parked` / `sleeping` - yet the host stays blocked for 61 s and never returns The whole forward pass has completed on the device and the host simply never gets past step 48. ## Not a 0.1.43 regression | # | engine | engine started | context position | host idle | |---|---|---|---:|---| | 1 | 0.1.41 | 2026-10-10 08:43:08 | 183,045 | 61,657 ms | | 2 | 0.1.41 | 2026-10-10 14:43:49 | 107,264 | 61,478 ms | | 3 | 0.1.41 | 2026-10-10 14:51:44 | 121,757 | 61,306 ms | | 4 | 0.1.43 | 2026-10-12 12:21:31 | 88,089 | 61,491 ms | | 5 | 0.1.43 | 2026-10-12 12:48:42 | 106,983 | 61,509 ms | Identical signature in all five, across two releases. **Downgrading does not help** - 0.1.41 shows it three times. On Windows the manifestation is Application Error 1000 on `strata.exe`, exception `0xc0000409` (the report code for `abort()` / `__fastfail`), same faulting offset `0x52f519` in both 0.1.43 occurrences. ## Ruled out - **Slow I/O (#1407)**: the `no step finished for %d s, but the file tier is still being read` branch never fired - `grep -c "no step finished"` is **0** across the whole log, so `STRATA_WATCHDOG_IO_S` is not involved. - **Memory pressure**: `committed` is 56,158-57,912 MiB against a 63.2 GiB guard with 16,150-19,527 MiB still available; `resident` actually **fell** from 30.3 GiB (occurrence 4) to 16.8 GiB (occurrence 5). - **The NaN guard (#879) added in 0.1.43**: `non-finite logits` never appears in the log. - **A single unlucky run**: 5/5 identical, and occurrences 4 and 5 were 8 minutes apart within one session. ## Environment ``` Engine : 0.1.43 (also reproduced on 0.1.41) OS : Windows 11 GPU : NVIDIA RTX 4080 (sm_89, 16 GB; display on iGPU) CPU : AMD Ryzen 7 7800X3D RAM : 64 GB Model : Swift-Qwen3.8-Flash-Next-GSQ-RCO-IQ3_XXS (native IQ3_XXS pack), 48 blocks Launch : --max-context 262144 --kv int8 --mmap-experts --spec 6 --mtp <path> --spec-min-p 0.7 --pool-workers 5 --resident-budget-gib 40 --pcie-frac 0.5 --vram-reserve-mib 768 --kv-resident 20480 --conversation-cache-mib 8192 --conversation-cache-slots 4 --conversation-cache-min-free-mib 1024 ``` No non-default value the watchdog could be sensitive to; this is the documented 256K configuration. ## Reproducibility Every occurrence needs a **long** session. Short A/B segments (a few minutes each) never hit it. On 0.1.43 the first appeared ~25 min into a session and the second 8 min after the automatic restart. The trigger therefore looks tied to long sessions at large context positions (88K-183K) rather than to any single request shape. ## Related - **#1234** - same stall class reported on 0.1.39 / RTX 4090 (`stage "decode -1"`). Ours freezes at `stage "request -1"`, and the new information here is that the site is **deterministic and identical across versions**. - **#29** - the watchdog itself. Its design is working as intended here (it turns a permanent hang into a 60 s hiccup plus an automatic restart), so this report is about **what it is catching**, not a request to turn it off. - **DETAILS.md** ("Generation stops mid-answer...") asks for the thread stacks and says *"attach both"*. Both parts are attached: five `strata-stall-<pid>.dmp` files, and one text file with all five stall reports. ## Attachments - `E:\AI\Strata\strata-stall-13600.dmp` (359,712 B) - `E:\AI\Strata\strata-stall-22336.dmp` (355,289 B) - `E:\AI\Strata\strata-stall-23088.dmp` (355,289 B) - `E:\AI\Strata\strata-stall-27724.dmp` (357,605 B) - `E:\AI\Strata\strata-stall-30728.dmp` (362,028 B) - `_issue_strata_stall_excerpt.txt` - all five stall reports in one file [strata-stall-13600.dmp](https://github.com/user-attachments/files/33320964/strata-stall-13600.dmp) [strata-stall-22336.dmp](https://github.com/user-attachments/files/33320961/strata-stall-22336.dmp) [strata-stall-23088.dmp](https://github.com/user-attachments/files/33320962/strata-stall-23088.dmp) [strata-stall-27724.dmp](https://github.com/user-attachments/files/33320965/strata-stall-27724.dmp) [strata-stall-30728.dmp](https://github.com/user-attachments/files/33320963/strata-stall-30728.dmp) [_issue_strata_stall_excerpt.txt](https://github.com/user-attachments/files/33320967/_issue_strata_stall_excerpt.txt)
Author
Owner

@tangdaibin commented on GitHub (Oct 12, 2026):

Same signature, but on AMD/ROCm — and it takes the whole host down

Adding a data point from a different vendor, since every other occurrence in #2049 and
#2065 that I could find is NVIDIA. Here the stall is reproduced on gfx1100 (RX 7900
XTX) / ROCm 10.0 / HIP 7.15
, and the consequence is worse: the machine hard-freezes.

My stall report is structurally identical to the ones in #2049:

strata serve: no progress for 60 s during a request (request -1) - stopping the engine
  so the server starts it again (issue #29)

strata serve: stall report (engine 0.1.41): stage "request -1" for 59 s;
  0 layers served since the last finished step (0 = stopped, more = slow)
  expert pool: epoch 2460762, batch epoch 2460762: 36 of 36 jobs claimed, 36 done;
    11 of 11 workers parked, 11 sleeping; mode 0
  expert pool threads: w0=sleeping w1=sleeping ... w10=sleeping; host idle for 75792 ms
  verify window (last window, not the current stage): 4 tokens at position 64173,
    host at layer step 48; the GPU rang 48; flags: served 48, plan (A) 48, copies (B) 48
  threads waiting on the disk (state D): 0 of 37
  memory: 51898 MiB resident, 0 MiB in swap, 64333 MiB RAM available;
    2076 major page faults so far

36 of 36 jobs claimed, 36 done with 11 workers parked and host at layer step 48
is the same shape as the 18 of 18 jobs claimed, 18 done / 5 workers parked case
here. Same "the forward pass finished on the device and the host never gets past the
last block" reading. The model here is Qwen3.8-Flash-Next IQ3_S, engine 0.1.41.

Three things that differ from the reports above

1. It is not specific to NVIDIA. ROCm 10.0, HIP 7.15, gfx1100, same stall, same
layer step 48 completion handshake. If the fix lands in the host/driver interaction,
it should cover this path too — which is also a useful test that the fix is in the right
place.

2. The host then hard-freezes; it does not recover. After the watchdog aborts the
engine, the server auto-restarts it (ensure_loaded()), which issues a large amount of
GPU work against a device that never came back. The kernel then loses the SMU:

14:46:42  amdgpu 0000:c6:00.0: SMU: No response msg_reg: 12 resp_reg: 0   (x24, ~4.5 s apart)
          amdgpu: Failed to export SMU metrics table!
          amdgpu: Failed to retrieve enabled ppfeatures!
14:47:49  MES failed to respond to msg=REMOVE_QUEUE / SUSPEND / RESET / RESUME
          amdgpu: Failed to disable gfxoff!   (x4)
          amdgpu: Failed to set workload mask
          KFD worker stuck in D state

amdgpu's reset path cannot recover it and the machine needs a power cycle — no SSH, no
console. This happened twice on this box. I have now armed a hardware watchdog
(sp5100_tco, 60 s) so it resets itself, but that only limits the damage, it does not
stop the failure.

The engine's automatic restart looks like an aggravator here: it keeps driving a dead
device. Would it be reasonable for the stall path to probe whether the GPU is still
responsive before letting the server restart the engine onto it?
On Linux that could be
a small hipMemcpy/rocm-smi poll. Failing that, at least not auto-restarting after a
host-side stall would keep the failure at "engine unavailable" instead of "machine
gone".

3. It triggers at a lower context position. Your five occurrences are at 88K-183K.
Mine fired at position 64,173, and roughly 1 in 15 requests in the 60K-70K band hit
it; requests below ~30K never have on this machine. So on this card/vend combination it
is both easier to reach and more frequent than the NVIDIA reports suggest.

VRAM headroom

For what it is worth, this lands very close to the ~500 MiB threshold in #2065. My startup
left 592 MiB of VRAM free with everything loaded (this was before I fixed a bug in my
own wrapper that had been silently dropping --vram-reserve-mib; it is confirmed in the
command line now). I have not captured per-window VRAM lines during the stall itself, so
I cannot say whether it was declining the way yours did.

Config

Engine   : 0.1.41
GPU      : AMD Radeon RX 7900 XTX (gfx1100), 24 GB
CPU      : AMD Ryzen AI Max (Strix Halo), 128 GB
Model    : Qwen3.8-Flash-Next-GSQ-RCO-IQ3_S
Launch   : --max-context 131072 --kv int8 --kv-resident 32768 --vram-reserve-mib 3072
           --kv-grow --prefill auto:16384 --expert-cache auto --spec 4 --spec-min-p 0.5

Not ruling anything out on my side beyond the obvious: 0 of 37 threads in D state,
0 MiB in swap, 64 GB RAM available, no disk stall. Reproduced twice, on two different
days, both times after a long session.

Happy to collect a thread dump or extra counters if that would help — I can run
strata under gdb if needed.

<!-- gh-comment-id:6128866709 --> @tangdaibin commented on GitHub (Oct 12, 2026): ## Same signature, but on AMD/ROCm — and it takes the whole host down Adding a data point from a different vendor, since every other occurrence in #2049 and #2065 that I could find is NVIDIA. Here the stall is reproduced on **gfx1100 (RX 7900 XTX) / ROCm 10.0 / HIP 7.15**, and the consequence is worse: the machine hard-freezes. My stall report is structurally identical to the ones in #2049: ``` strata serve: no progress for 60 s during a request (request -1) - stopping the engine so the server starts it again (issue #29) strata serve: stall report (engine 0.1.41): stage "request -1" for 59 s; 0 layers served since the last finished step (0 = stopped, more = slow) expert pool: epoch 2460762, batch epoch 2460762: 36 of 36 jobs claimed, 36 done; 11 of 11 workers parked, 11 sleeping; mode 0 expert pool threads: w0=sleeping w1=sleeping ... w10=sleeping; host idle for 75792 ms verify window (last window, not the current stage): 4 tokens at position 64173, host at layer step 48; the GPU rang 48; flags: served 48, plan (A) 48, copies (B) 48 threads waiting on the disk (state D): 0 of 37 memory: 51898 MiB resident, 0 MiB in swap, 64333 MiB RAM available; 2076 major page faults so far ``` `36 of 36 jobs claimed, 36 done` with `11 workers parked` and `host at layer step 48` is the same shape as the `18 of 18 jobs claimed, 18 done` / `5 workers parked` case here. Same "the forward pass finished on the device and the host never gets past the last block" reading. The model here is Qwen3.8-Flash-Next IQ3_S, engine 0.1.41. ### Three things that differ from the reports above **1. It is not specific to NVIDIA.** ROCm 10.0, HIP 7.15, gfx1100, same stall, same `layer step 48` completion handshake. If the fix lands in the host/driver interaction, it should cover this path too — which is also a useful test that the fix is in the right place. **2. The host then hard-freezes; it does not recover.** After the watchdog aborts the engine, the server auto-restarts it (`ensure_loaded()`), which issues a large amount of GPU work against a device that never came back. The kernel then loses the SMU: ``` 14:46:42 amdgpu 0000:c6:00.0: SMU: No response msg_reg: 12 resp_reg: 0 (x24, ~4.5 s apart) amdgpu: Failed to export SMU metrics table! amdgpu: Failed to retrieve enabled ppfeatures! 14:47:49 MES failed to respond to msg=REMOVE_QUEUE / SUSPEND / RESET / RESUME amdgpu: Failed to disable gfxoff! (x4) amdgpu: Failed to set workload mask KFD worker stuck in D state ``` amdgpu's reset path cannot recover it and the machine needs a power cycle — no SSH, no console. This happened twice on this box. I have now armed a hardware watchdog (`sp5100_tco`, 60 s) so it resets itself, but that only limits the damage, it does not stop the failure. The engine's automatic restart looks like an aggravator here: it keeps driving a dead device. **Would it be reasonable for the stall path to probe whether the GPU is still responsive before letting the server restart the engine onto it?** On Linux that could be a small `hipMemcpy`/`rocm-smi` poll. Failing that, at least not auto-restarting after a *host-side* stall would keep the failure at "engine unavailable" instead of "machine gone". **3. It triggers at a lower context position.** Your five occurrences are at 88K-183K. Mine fired at position **64,173**, and roughly 1 in 15 requests in the 60K-70K band hit it; requests below ~30K never have on this machine. So on this card/vend combination it is both easier to reach and more frequent than the NVIDIA reports suggest. ### VRAM headroom For what it is worth, this lands very close to the ~500 MiB threshold in #2065. My startup left `592 MiB of VRAM free with everything loaded` (this was before I fixed a bug in my own wrapper that had been silently dropping `--vram-reserve-mib`; it is confirmed in the command line now). I have not captured per-window VRAM lines during the stall itself, so I cannot say whether it was declining the way yours did. ### Config ``` Engine : 0.1.41 GPU : AMD Radeon RX 7900 XTX (gfx1100), 24 GB CPU : AMD Ryzen AI Max (Strix Halo), 128 GB Model : Qwen3.8-Flash-Next-GSQ-RCO-IQ3_S Launch : --max-context 131072 --kv int8 --kv-resident 32768 --vram-reserve-mib 3072 --kv-grow --prefill auto:16384 --expert-cache auto --spec 4 --spec-min-p 0.5 ``` Not ruling anything out on my side beyond the obvious: `0 of 37` threads in D state, `0 MiB in swap`, 64 GB RAM available, no disk stall. Reproduced twice, on two different days, both times after a long session. Happy to collect a thread dump or extra counters if that would help — I can run `strata` under `gdb` if needed.
Author
Owner

@Niko1221 commented on GitHub (Oct 12, 2026):

Thank you for the five dumps and the table: they made this readable. The short version: it is not a deadlock after layer 48, and the cause is on the host side, in the memory the engine parks between conversations.

What the report line really says. verify window (last window, not the current stage): ... host at layer step 48; the GPU rang 48 is the previous request's last window, which finished normally (48 is just its end state). The stage that stalled is request -1, so nothing was waiting for a GPU handshake. I read your dumps against the v0.1.41 and v0.1.43 release strata.exe (same instruction in all five): the main thread is inside a host memcpy, called from the copy of the parked conversation's running checkpoints (conversation_snapshot_save, run when a request switches conversation). The expert pool and the GPU are idle because nothing is asking them for anything.

Why it takes more than 60 s. Your reports show 8-30 GB resident against 56-58 GB committed, and about 190 page faults a second between the two samples. Those checkpoints were written tens of minutes earlier; with 64 GB, --resident-budget-gib 40, mmap-experts and an 8 GiB conversation cache, Windows has trimmed them out of the working set, and copying them back is one pagefile read per 4 KiB page, under 1 MB/s. The I/O allowance of the watchdog (#1407) missed it because it counted page faults / 64 (3 a second here, it needs 16). That is why no step finished never printed and why 0.1.41 and 0.1.43 behave the same. I could not reproduce the paging itself (no Windows box with that pressure), but I could reproduce the watchdog part on Linux: with the parked copy made slow, the old code stops the engine at the limit with request -1 and the same report, and the fixed code finishes the park.

What changed on the fix branch (not released yet): the park is named in the stage (request: parking the previous conversation), its copies tell the watchdog they are moving, and on Windows page faults count 8x more as file-tier activity. So a slow park finishes instead of being aborted. The park itself is still as slow as your pagefile, so the real cure is memory: could you try a smaller --resident-budget-gib (30 instead of 40) and/or --conversation-cache-mib 4096, and check that the pagefile is on an SSD? It would help to see the conversation cache: parked N tokens in X ms lines of a run (from the log), and the pagefile size/location. If the park lines say several minutes, that confirms it.

<!-- gh-comment-id:6129336743 --> @Niko1221 commented on GitHub (Oct 12, 2026): Thank you for the five dumps and the table: they made this readable. The short version: it is not a deadlock after layer 48, and the cause is on the host side, in the memory the engine parks between conversations. What the report line really says. `verify window (last window, not the current stage): ... host at layer step 48; the GPU rang 48` is the previous request's last window, which finished normally (48 is just its end state). The stage that stalled is `request -1`, so nothing was waiting for a GPU handshake. I read your dumps against the v0.1.41 and v0.1.43 release strata.exe (same instruction in all five): the main thread is inside a host memcpy, called from the copy of the parked conversation's running checkpoints (`conversation_snapshot_save`, run when a request switches conversation). The expert pool and the GPU are idle because nothing is asking them for anything. Why it takes more than 60 s. Your reports show 8-30 GB resident against 56-58 GB committed, and about 190 page faults a second between the two samples. Those checkpoints were written tens of minutes earlier; with 64 GB, `--resident-budget-gib 40`, mmap-experts and an 8 GiB conversation cache, Windows has trimmed them out of the working set, and copying them back is one pagefile read per 4 KiB page, under 1 MB/s. The I/O allowance of the watchdog (#1407) missed it because it counted page faults / 64 (3 a second here, it needs 16). That is why `no step finished` never printed and why 0.1.41 and 0.1.43 behave the same. I could not reproduce the paging itself (no Windows box with that pressure), but I could reproduce the watchdog part on Linux: with the parked copy made slow, the old code stops the engine at the limit with `request -1` and the same report, and the fixed code finishes the park. What changed on the fix branch (not released yet): the park is named in the stage (`request: parking the previous conversation`), its copies tell the watchdog they are moving, and on Windows page faults count 8x more as file-tier activity. So a slow park finishes instead of being aborted. The park itself is still as slow as your pagefile, so the real cure is memory: could you try a smaller `--resident-budget-gib` (30 instead of 40) and/or `--conversation-cache-mib 4096`, and check that the pagefile is on an SSD? It would help to see the `conversation cache: parked N tokens in X ms` lines of a run (from the log), and the pagefile size/location. If the park lines say several minutes, that confirms it.
Author
Owner

@hejm2000 commented on GitHub (Oct 13, 2026):

Same signature on our side — single-GPU Linux/Docker, and the host-side conversation-snapshot mechanism fits our setup unusually well. Data point:

Environment

  • Strata 0.1.41 in Docker on a Linux host, single RTX 5060 Ti 16 GB, 62.6 GiB host RAM, Qwen3.8-Flash-Next IQ3_XXS native pack, --max-context 131072 --kv int8, spec/MTP on (live /metrics: spec=6, spec_min_p=0.50, mtp_max=4), expert-cache auto. No --pipeline-windows (single card, so presumably the serial reader path — i.e. this is #1341's symptom without #1341's mechanism).
  • Client: an agent framework (Hermes) that multiplexes several live chat sessions onto this one engine (serving: 1), so requests switch between conversations frequently, and the deep ones carry ~100k-token histories.

Symptom
Three engine aborts on 2026-10-12 at 14:30:43 / 16:50:04 / 17:06:19 CST (UTC+8), each logged client-side as the engine stopped unexpectedly (exit code -6) — consistent with the #29 watchdog self-stop. Each time the server reloaded the model (~1.5–2 min), the KV/prefix cache was gone, so the next request re-read the same large prompt entirely from cold and stalled again — the 16:50 and 17:06 aborts are that cascade, 16 minutes apart.

Prompt-depth correlation

  • last successful call before abort 1: prompt = 97,403 tokens; a request that day carried prompt = 102,714
  • a 92,794-token fully-cold prompt passed fine at 16:06 the same day
  • so on our box the stall band sits around ~95–100k tokens against a 131,072 window — below #1341's >100k band

Host-side pressure (points at your conversation_snapshot_save reading)

  • host RAM is the tightest resource in the house: currently 59.8/62.6 GiB used (~96%), and it was similarly loaded during the aborts
  • vram_free_mib = 405 right now — under the ~500 MiB floor from #2065 as well
  • several parked conversations at 60–100k token depth switching on one slot; a snapshot memcpy that scales with parked-conversation state would grow exactly as our sessions grow, and with RAM at 96% a 60 s stall is easy to reach

Questions

  1. Does the parked-conversation copy scale with the parked conversation's KV/checkpoint size (i.e. is a 100k-token parked session ~5x the copy of a 20k one)?
  2. Is there any knob to cap or skip the snapshot (depth limit, park-discard, snapshot to file instead of memcpy), or is lowering --max-context the practical way to bound it?
  3. Anything in serve mode we could enable to capture the stall dump for this path (our engine logs live inside the container and the stall dumps weren't reachable from the client side)?

We can run a controlled reproduction (fixed multi-conversation pattern driving prompt depth through the 90k–105k band) and attach whatever captures you want.

<!-- gh-comment-id:6136047966 --> @hejm2000 commented on GitHub (Oct 13, 2026): Same signature on our side — single-GPU Linux/Docker, and the host-side conversation-snapshot mechanism fits our setup unusually well. Data point: **Environment** - Strata 0.1.41 in Docker on a Linux host, single RTX 5060 Ti 16 GB, 62.6 GiB host RAM, Qwen3.8-Flash-Next IQ3_XXS native pack, `--max-context 131072 --kv int8`, spec/MTP on (live `/metrics`: `spec=6, spec_min_p=0.50, mtp_max=4`), expert-cache auto. No `--pipeline-windows` (single card, so presumably the serial reader path — i.e. this is #1341's symptom without #1341's mechanism). - Client: an agent framework (Hermes) that multiplexes **several live chat sessions onto this one engine** (`serving: 1`), so requests switch between conversations frequently, and the deep ones carry ~100k-token histories. **Symptom** Three engine aborts on 2026-10-12 at 14:30:43 / 16:50:04 / 17:06:19 CST (UTC+8), each logged client-side as `the engine stopped unexpectedly (exit code -6)` — consistent with the #29 watchdog self-stop. Each time the server reloaded the model (~1.5–2 min), the KV/prefix cache was gone, so the *next* request re-read the same large prompt entirely from cold and stalled again — the 16:50 and 17:06 aborts are that cascade, 16 minutes apart. **Prompt-depth correlation** - last successful call before abort 1: `prompt = 97,403` tokens; a request that day carried `prompt = 102,714` - a 92,794-token fully-cold prompt *passed* fine at 16:06 the same day - so on our box the stall band sits around ~95–100k tokens against a 131,072 window — below #1341's >100k band **Host-side pressure (points at your `conversation_snapshot_save` reading)** - host RAM is the tightest resource in the house: currently 59.8/62.6 GiB used (~96%), and it was similarly loaded during the aborts - `vram_free_mib = 405` right now — under the ~500 MiB floor from #2065 as well - several parked conversations at 60–100k token depth switching on one slot; a snapshot memcpy that scales with parked-conversation state would grow exactly as our sessions grow, and with RAM at 96% a 60 s stall is easy to reach **Questions** 1. Does the parked-conversation copy scale with the parked conversation's KV/checkpoint size (i.e. is a 100k-token parked session ~5x the copy of a 20k one)? 2. Is there any knob to cap or skip the snapshot (depth limit, park-discard, snapshot to file instead of memcpy), or is lowering `--max-context` the practical way to bound it? 3. Anything in serve mode we could enable to capture the stall dump for this path (our engine logs live inside the container and the stall dumps weren't reachable from the client side)? We can run a controlled reproduction (fixed multi-conversation pattern driving prompt depth through the 90k–105k band) and attach whatever captures you want.
Author
Owner

@beastrobin commented on GitHub (Oct 13, 2026):

Same watchdog family on an RTX PRO 6000 Blackwell — but every hang here sat in the prompt-read stage, and none recurred after 0.1.41. Attaching what we still have (log text only, see caveat at the end).

Machine / build: Windows 11 build 26200 · RTX PRO 6000 Blackwell Workstation Edition 96 GB (sm_120) · Flash-Next IQ3_S native pack, all experts VRAM-resident (expert_slots 24576, hit 100%, zero-doorbell graph) · engine flags of the era: --max-context 262144 --kv int8 --spec 4 --mtp rt --lookup-chain 4 --batch-mtp --pool-workers 15 --batch 2.

The retained server log covers 2026-10-07 → 2026-10-13 (the upgrades through it): 36 stall reports, all emitted by engine 0.1.40. Every one is identical in shape and differs from this issue's signature:

  • stage line: reading the prompt (batched), done up to token N for 60 s — i.e. mid-prefill, right after a line strata verify: captured the batch window over slots 0;
  • expert pool fully parked with no work outstanding: epoch 0: 0 of 0 jobs claimed, 0 done; 15 of 15 workers sleeping;
  • the last verify window (flagged as "last window, not the current stage") shows host/GPU in lockstep and small - on this box always a low count (host at layer step 1; the GPU rang 1), never the step-48 value of your decode-handshake signature.
  • blocked position concentrates on chunk boundaries of the big-prompt reader — distinct tokens seen: 50188×17, 49998×6, 39357×5, 49986/50933/37886×2 each, 37891×1, 82956×1 (all ≈ 32768+remainder or its second block); prompts were long single requests (~38k–83k tokens) on a busy dev box, temp varies;
  • resolution every time was the watchdog itself: no progress for 60 s ... - stopping the engine so the server starts it again (issue #29) → engine restart, next request re-reads the prompt.

Verbatim first cluster (line ~1984):

strata serve: no progress for 60 s during a request (reading the prompt (batched), done up to token 49986) - stopping the engine so the server starts it again (issue #29)
strata serve: stall report (engine 0.1.40): stage "reading the prompt (batched), done up to token 49986" for 60 s; 0 layers served since the last finished step (0 = stopped, more = slow)
  expert pool: epoch 0, batch epoch 0: 0 of 0 jobs claimed, 0 done; 15 of 15 workers parked, 15 sleeping; mode 0
  verify window (last window, not the current stage): 1 tokens at position 134820, host at layer step 1; the GPU rang 1; flags: served 1, plan (A) 0, copies (B) 0
  memory: 19729 MiB resident, 125346 MiB committed, 149043 MiB RAM available; 86738208 page faults so far

Regression observation from this box: after upgrading past 0.1.40 (now 0.1.43.1), zero stall reports — across Oct 8 → today, including ~10 restarts and several full strata_bench --long suites today plus concurrent multi-slot use. So if this is one bug family, something between .40 and .41 may already have closed this variant on Blackwell; the decode-handshake variant you document on the 4080 still reproduces there on 0.1.43, per your report. Happy to run a targeted repro (fixed seed prompt >50k tokens, --batch-mtp, batched prefill with parallel slot activity) against whatever build you want probed next.

Caveat on attachments: the engine did write D:\AI\Strata\strata-stall-<pid>.dmp for each event at the time, but those files were deleted during later disk cleanup before I saw this issue — nothing left to attach. If thread-stack dumps are strictly needed I can try to reproduce on 0.1.40 binaries kept here (engine/ archives), though they may not be installed anymore.

<!-- gh-comment-id:6149027188 --> @beastrobin commented on GitHub (Oct 13, 2026): Same watchdog family on an RTX PRO 6000 Blackwell — but every hang here sat in the **prompt-read** stage, and none recurred after 0.1.41. Attaching what we still have (log text only, see caveat at the end). Machine / build: Windows 11 build 26200 · RTX PRO 6000 Blackwell Workstation Edition 96 GB (sm_120) · Flash-Next IQ3_S native pack, all experts VRAM-resident (`expert_slots 24576`, hit 100%, zero-doorbell graph) · engine flags of the era: `--max-context 262144 --kv int8 --spec 4 --mtp rt --lookup-chain 4 --batch-mtp --pool-workers 15 --batch 2`. The retained server log covers 2026-10-07 → 2026-10-13 (the upgrades through it): **36 stall reports, all emitted by engine 0.1.40**. Every one is identical in shape and *differs from this issue's signature*: - stage line: `reading the prompt (batched), done up to token N` for 60 s — i.e. mid-prefill, right after a line `strata verify: captured the batch window over slots 0`; - expert pool fully parked with **no work outstanding**: `epoch 0: 0 of 0 jobs claimed, 0 done; 15 of 15 workers sleeping`; - the last verify window (flagged as "last window, not the current stage") shows host/GPU in lockstep and small - on this box always a low count (`host at layer step 1; the GPU rang 1`), never the step-48 value of your decode-handshake signature. - blocked position concentrates on chunk boundaries of the big-prompt reader — distinct tokens seen: 50188×17, 49998×6, 39357×5, 49986/50933/37886×2 each, 37891×1, 82956×1 (all ≈ 32768+remainder or its second block); prompts were long single requests (~38k–83k tokens) on a busy dev box, temp varies; - resolution every time was the watchdog itself: `no progress for 60 s ... - stopping the engine so the server starts it again (issue #29)` → engine restart, next request re-reads the prompt. Verbatim first cluster (line ~1984): ```text strata serve: no progress for 60 s during a request (reading the prompt (batched), done up to token 49986) - stopping the engine so the server starts it again (issue #29) strata serve: stall report (engine 0.1.40): stage "reading the prompt (batched), done up to token 49986" for 60 s; 0 layers served since the last finished step (0 = stopped, more = slow) expert pool: epoch 0, batch epoch 0: 0 of 0 jobs claimed, 0 done; 15 of 15 workers parked, 15 sleeping; mode 0 verify window (last window, not the current stage): 1 tokens at position 134820, host at layer step 1; the GPU rang 1; flags: served 1, plan (A) 0, copies (B) 0 memory: 19729 MiB resident, 125346 MiB committed, 149043 MiB RAM available; 86738208 page faults so far ``` Regression observation from this box: after upgrading past 0.1.40 (now 0.1.43.1), **zero stall reports** — across Oct 8 → today, including ~10 restarts and several full `strata_bench --long` suites today plus concurrent multi-slot use. So if this is one bug family, something between .40 and .41 may already have closed *this* variant on Blackwell; the decode-handshake variant you document on the 4080 still reproduces there on 0.1.43, per your report. Happy to run a targeted repro (fixed seed prompt >50k tokens, `--batch-mtp`, batched prefill with parallel slot activity) against whatever build you want probed next. Caveat on attachments: the engine did write `D:\AI\Strata\strata-stall-<pid>.dmp` for each event at the time, but those files were deleted during later disk cleanup before I saw this issue — nothing left to attach. If thread-stack dumps are strictly needed I can try to reproduce on 0.1.40 binaries kept here (`engine/` archives), though they may not be installed anymore.
Author
Owner

@Niko1221 commented on GitHub (Oct 13, 2026):

Thanks @hejm2000, that fits the park reading, and you are on 0.1.41. The fix for this path is in 0.1.43.1 (released 2026-10-12). Parking a conversation names its stage ("request: parking the previous conversation"), its copies report progress to the watchdog, and the stall report says how little VRAM is free. So a slow park finishes instead of being stopped at 60 s.

Your questions:

  1. Yes. A park copies the conversation's running checkpoints and its K/V, so a 100K-token conversation costs about 5x a 20K one.
  2. Knobs: a smaller --conversation-cache-mib (fewer parked bytes; 0 turns parking off, and a switch then reads the prompt again), --conversation-cache-min-free-mib (it stops parking below that much free RAM; default 2560), and --prompt-cache N (fewer checkpoints per conversation). With RAM at 96% the first two matter most.
  3. On Linux the stall report goes to the engine log (strata-<model>.log, inside the container). Mounting that folder out of the container is enough. The thread-stack dump is a Windows-only extra.

Please retry on 0.1.43.1 (or 0.1.44) with the same multi-conversation pattern. If it still stops, the stall report's stage line will now say whether it is the park.

<!-- gh-comment-id:6153463540 --> @Niko1221 commented on GitHub (Oct 13, 2026): Thanks @hejm2000, that fits the park reading, and you are on 0.1.41. The fix for this path is in 0.1.43.1 (released 2026-10-12). Parking a conversation names its stage ("request: parking the previous conversation"), its copies report progress to the watchdog, and the stall report says how little VRAM is free. So a slow park finishes instead of being stopped at 60 s. Your questions: 1. Yes. A park copies the conversation's running checkpoints and its K/V, so a 100K-token conversation costs about 5x a 20K one. 2. Knobs: a smaller `--conversation-cache-mib` (fewer parked bytes; 0 turns parking off, and a switch then reads the prompt again), `--conversation-cache-min-free-mib` (it stops parking below that much free RAM; default 2560), and `--prompt-cache N` (fewer checkpoints per conversation). With RAM at 96% the first two matter most. 3. On Linux the stall report goes to the engine log (`strata-<model>.log`, inside the container). Mounting that folder out of the container is enough. The thread-stack dump is a Windows-only extra. Please retry on 0.1.43.1 (or 0.1.44) with the same multi-conversation pattern. If it still stops, the stall report's stage line will now say whether it is the park.
Author
Owner

@gaoyonghui123 commented on GitHub (Oct 14, 2026):

Thanks @hejm2000 — and thanks @Niko1221 for the park explanation. We are the original five-dump report at the top of this thread; here is what our raw logs add to the two answers already given.

1. On "a 100K conversation costs about 5x a 20K one" — on snapshot bytes we measure about 2.3x, and the worst park is not the largest conversation.

We have 416 parked N tokens in X ms records across all our runs:

tokens n median park max park
0 – 20K 132 37 ms 94 ms
20 – 50K 19 288 ms 517 ms
50 – 100K 90 341 ms 14,216 ms
100 – 150K 56 592 ms 2,016 ms
150 – 210K 84 755 ms 1,748 ms
210 – 300K 35 764 ms 1,238 ms

Two readings:

  • The median grows and then saturates: 37 → ~340 → ~760 ms, and it barely moves from 150K to 300K (755 → 764 ms). The ordinary copy is not proportional over the whole range.
  • The 14.2 s outlier is a 67,353-token conversation, not a big one. 200K-token sessions (3.6 GiB snapshot) parked in ~1.5 s.

Pearson r between tokens and park time is only +0.360 (n=416) — size explains ~13% of the variance. On snapshot_bytes (n=292) a linear fit gives ≈654 MiB + 15.9 KiB × tokens (median residual 74 MiB, worst 691 MiB), i.e. 2.1 GiB at 100K vs 0.94 GiB at 20K — about 2.3x, because of a large fixed floor. That matches the paging reading: the cost is whether those pages are still resident, not how many bytes the snapshot holds.

2. Two checkpoint knobs the reply did not list (from --help on 0.1.43.1; both left at default on our box):

--prompt-cache N         keep N conversation checkpoints between requests (default 6)
--prompt-cache-every N   also checkpoint every N fresh prompt tokens (default 16384, 0 = off)
--prompt-cache-tail      one extra checkpoint near the prompt's end (default off)

@hejm2000: the default 6 is visible in our request tail as the recurring ..., 6 checkpoints, so if you want to cut park volume, --prompt-cache is a second lever next to --conversation-cache-mib. Note ours are unset — this is a reading of the defaults, not an A/B.

3. Worth separating from this issue: the prefix-cache miss is a different problem. With several live sessions multiplexed onto one engine, switching away and back changes the prompt shape, so the prefix misses and the whole history is re-read cold — we measured cached_tokens dropping from 101,877 / 102,132 (99.8%) to 17,408 / 107,101 (16.3%) across one switch, i.e. 89,693 tokens re-read in 51.4 s. In our case that was the client re-injecting a context block at the front of messages[1]. The #2049 park path is what 0.1.43.1 fixed; this one is not the same thing.

4. Status on our side: we went 0.1.41 → 0.1.43.1 → 0.1.44.1 (today). On 0.1.43.1 the engine log shows 2,690 lines / 3 sessions / 5 conversation switches with zero stall reports, versus 5 stalls (0.1.41 ×3, 0.1.43 ×2) before, and the worst park dropped from 14,216 ms to 1,437 ms in that window. We are not calling that "park got faster" — as you said, the park itself is still as slow as the pagefile — we are calling it "it no longer gets killed at 60 s". A longer soak is still pending on our side.

Happy to paste the raw parked ... in ... ms lines if useful.

<!-- gh-comment-id:6159060781 --> @gaoyonghui123 commented on GitHub (Oct 14, 2026): Thanks @hejm2000 — and thanks @Niko1221 for the park explanation. We are the original five-dump report at the top of this thread; here is what our raw logs add to the two answers already given. **1. On "a 100K conversation costs about 5x a 20K one" — on snapshot bytes we measure about 2.3x, and the *worst* park is not the largest conversation.** We have **416** `parked N tokens in X ms` records across all our runs: | tokens | n | median park | max park | | ---------- | --: | ----------: | ------------: | | 0 – 20K | 132 | 37 ms | 94 ms | | 20 – 50K | 19 | 288 ms | 517 ms | | 50 – 100K | 90 | 341 ms | **14,216 ms** | | 100 – 150K | 56 | 592 ms | 2,016 ms | | 150 – 210K | 84 | 755 ms | 1,748 ms | | 210 – 300K | 35 | **764 ms** | 1,238 ms | Two readings: - The median grows and then **saturates**: 37 → ~340 → ~760 ms, and it barely moves from 150K to 300K (755 → 764 ms). The ordinary copy is not proportional over the whole range. - **The 14.2 s outlier is a 67,353-token conversation, not a big one.** 200K-token sessions (3.6 GiB snapshot) parked in ~1.5 s. Pearson r between tokens and park time is only **+0.360** (n=416) — size explains ~13% of the variance. On `snapshot_bytes` (n=292) a linear fit gives **≈654 MiB + 15.9 KiB × tokens** (median residual 74 MiB, worst 691 MiB), i.e. **2.1 GiB at 100K vs 0.94 GiB at 20K — about 2.3x**, because of a large fixed floor. That matches the paging reading: the cost is whether those pages are still resident, not how many bytes the snapshot holds. **2. Two checkpoint knobs the reply did not list** (from `--help` on 0.1.43.1; both left at default on our box): ``` --prompt-cache N keep N conversation checkpoints between requests (default 6) --prompt-cache-every N also checkpoint every N fresh prompt tokens (default 16384, 0 = off) --prompt-cache-tail one extra checkpoint near the prompt's end (default off) ``` @hejm2000: the default `6` is visible in our request tail as the recurring `..., 6 checkpoints`, so if you want to cut park volume, `--prompt-cache` is a second lever next to `--conversation-cache-mib`. Note ours are unset — this is a reading of the defaults, not an A/B. **3. Worth separating from this issue: the prefix-cache miss is a different problem.** With several live sessions multiplexed onto one engine, switching away and back changes the prompt shape, so the prefix misses and the whole history is re-read cold — we measured `cached_tokens` dropping from **101,877 / 102,132 (99.8%)** to **17,408 / 107,101 (16.3%)** across one switch, i.e. **89,693 tokens re-read in 51.4 s**. In our case that was the client re-injecting a context block at the front of `messages[1]`. The #2049 park path is what 0.1.43.1 fixed; this one is not the same thing. **4. Status on our side:** we went 0.1.41 → 0.1.43.1 → **0.1.44.1** (today). On 0.1.43.1 the engine log shows **2,690 lines / 3 sessions / 5 conversation switches with zero stall reports**, versus **5 stalls (0.1.41 ×3, 0.1.43 ×2)** before, and the worst park dropped from **14,216 ms to 1,437 ms** in that window. We are not calling that "park got faster" — as you said, the park itself is still as slow as the pagefile — we are calling it "it no longer gets killed at 60 s". A longer soak is still pending on our side. Happy to paste the raw `parked ... in ... ms` lines if useful.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Niko1221/Strata#818
No description provided.