[GH-ISSUE #3877] [Engine] --vram-reserve-mib 4096 reserves 8192 GB and wastes 4 GB on dual GPU #1651

Closed
opened 2026-11-04 01:52:55 +07:00 by bsakaguchi · 5 comments
Owner

Originally created by @MarkSwanson on GitHub (Oct 23, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/3877

$ ./strata --version
strata 0.1.44.1

I appreciate what --vram-reserve-mib is doing - it leaves 4 GB free so Ubuntu / Wayland / Firefox / Blender / etc. can still run. Great!
But on a dual GPU system it also reserves 4 GB on the second card -> and this is just wasted.

Perhaps you could use that 4 GB to hold another layer or parts of the n-gram table or ...?

Originally created by @MarkSwanson on GitHub (Oct 23, 2026). Original GitHub issue: https://github.com/Niko1221/Strata/issues/3877 $ ./strata --version strata 0.1.44.1 I appreciate what --vram-reserve-mib is doing - it leaves 4 GB free so Ubuntu / Wayland / Firefox / Blender / etc. can still run. Great! But on a dual GPU system it also reserves 4 GB on the second card -> and this is just wasted. Perhaps you could use that 4 GB to hold another layer or parts of the n-gram table or ...?
Author
Owner

@github-actions[bot] commented on GitHub (Oct 23, 2026):

Thanks for the issue. To keep the tracker readable, every item needs an area prefix in the title and the parts of the issue form filled in. This one is missing:

  • Start the title with its area: [Engine], [GUI], [TUI], [Benchmark], [Docs] or [Other], then a short description. Example: "[Engine] decode stops after 2 minutes".
  • Add the Strata version (Settings > About, or strata --version).

Edit the issue (title and description) and this note goes away on its own. If it is still missing parts in 5 days it will be closed, which is not a rejection: fix it and comment /reopen.

Details: CONTRIBUTING.md

<!-- gh-comment-id:6371603559 --> @github-actions[bot] commented on GitHub (Oct 23, 2026): Thanks for the issue. To keep the tracker readable, every item needs an area prefix in the title and the parts of the issue form filled in. This one is missing: - [ ] Start the title with its area: [Engine], [GUI], [TUI], [Benchmark], [Docs] or [Other], then a short description. Example: "[Engine] decode stops after 2 minutes". - [ ] Add the Strata version (Settings > About, or `strata --version`). Edit the issue (title and description) and this note goes away on its own. If it is still missing parts in 5 days it will be closed, which is not a rejection: fix it and comment `/reopen`. Details: [CONTRIBUTING.md](https://github.com/Niko1221/Strata/blob/main/CONTRIBUTING.md)
Author
Owner

@github-actions[bot] commented on GitHub (Oct 23, 2026):

Thanks, this follows the format now.

<!-- gh-comment-id:6371744302 --> @github-actions[bot] commented on GitHub (Oct 23, 2026): Thanks, this follows the format now.
Author
Owner

@ravensergio commented on GitHub (Oct 23, 2026):

Hi. Have You tried this?:
"A separate VRAM reserve for the later cards: --vram-reserve-later-mib N (default: --vram-reserve-mib's value). The card that drives the monitors needs more headroom than one that drives none; with the display on the last card, --vram-reserve-mib 300 --vram-reserve-later-mib 1800 gives the first card's cache that VRAM." - taken from https://github.com/Niko1221/Strata/blob/main/docs/MULTI_GPU.md

<!-- gh-comment-id:6376103851 --> @ravensergio commented on GitHub (Oct 23, 2026): Hi. Have You tried this?: "A separate VRAM reserve for the later cards: --vram-reserve-later-mib N (default: --vram-reserve-mib's value). The card that drives the monitors needs more headroom than one that drives none; with the display on the last card, --vram-reserve-mib 300 --vram-reserve-later-mib 1800 gives the first card's cache that VRAM." - taken from https://github.com/Niko1221/Strata/blob/main/docs/MULTI_GPU.md
Author
Owner

@MarkSwanson commented on GitHub (Oct 24, 2026):

No, but I just spent some time with it and found a way to make it work for me. Here's my relevant options:
"--vram-reserve-mib",
"5120",
"--vram-reserve-later-mib",
"256"
"layer_split": "20" <-- I had to use "20" here instead of "auto"

GPU0: uses 30.2 GiB / 31.9 GiB
GPU1: uses 31.6 GiB / 31.9 GiB <-- SUCCESS!

What I noticed:
When using layer_split "auto" the strata startup process looks like this:

  • strata allocates 28 GB on GPU 0
  • strata allocates 31.6 GiB on GPU 1
  • FAIL -> then after strata auto-loads its UI in Firefox strata bumps GPU 0 to use 31.6 GiB !!! FAIL

Guess: it's as if "auto" then puts MTP and other data into free VRAM. The math used to calculate 5120 MB left over doesn't account for this.

So my workaround is to specify 20 layers on GPU0. This way when the MTP etc. data is loaded it leaves enough for me to run Blender, FreeCAD, full screen firefox youtube videos, etc.

"20" worked for me, but I can see others adjusting that number based on the apps they have running.

Thanks for letting me know about --vram-reserve-later-mib ! :-D

<!-- gh-comment-id:6387142692 --> @MarkSwanson commented on GitHub (Oct 24, 2026): No, but I just spent some time with it and found a way to make it work for me. Here's my relevant options: "--vram-reserve-mib", "5120", "--vram-reserve-later-mib", "256" "layer_split": "20" <-- I had to use "20" here instead of "auto" GPU0: uses 30.2 GiB / 31.9 GiB GPU1: uses 31.6 GiB / 31.9 GiB <-- SUCCESS! What I noticed: When using layer_split "auto" the strata startup process looks like this: * strata allocates 28 GB on GPU 0 * strata allocates 31.6 GiB on GPU 1 * FAIL -> then after strata auto-loads its UI in Firefox strata bumps GPU 0 to use 31.6 GiB !!! FAIL Guess: it's as if "auto" then puts MTP and other data into free VRAM. The math used to calculate 5120 MB left over doesn't account for this. So my workaround is to specify 20 layers on GPU0. This way when the MTP etc. data is loaded it leaves enough for me to run Blender, FreeCAD, full screen firefox youtube videos, etc. "20" worked for me, but I can see others adjusting that number based on the apps they have running. Thanks for letting me know about --vram-reserve-later-mib ! :-D
Author
Owner

@ravensergio commented on GitHub (Oct 24, 2026):

Nice. Sorry I forgot about that . I noticed this also Strata on auto doesn't fill the second gpu in my case. Coming from a fork strata-DualGPU which made auto work, I had also to do layer split 22 (cause both my cards are headless so i had all the vram free)
Here are my params, just to share maybe something you can compare (Windows- using Gyro M here on 5070 ti + 5060 ti (32 VRAM + 32 gb ram).
I get 100-150 tps with this model (5060 ti makes it slower).
For detecting :
"--pcie-frac",
"0.75",
"--spec-min-p",
"0.50",
"--pool-workers",
"5"
, I ran the CALIBRATE module from strata so it measured the best settings for me.

Params:

{
 "exe": "xx\\engine\\strata.exe",
 "args": [
.....................
  "--expert-cache",
  "auto",
  "--prefill",
  "auto",
  "--spec",
  "4",
  "--mtp",
  "xx\\Strata-data\\mtp\\rt",
  "--max-context",
  "211072",
  "--kv",
  "k8v4",
  "--resident-experts",
  "--vision",
  "--vram-reserve-mib",
  "280",
  "--vram-reserve-later-mib",
  "580",
  "--resident-budget-gib",
  "16",
  "--trim-stage-weights",
  "--pipeline-windows",
  "2",
  "--pcie-frac",
  "0.75",
  "--spec-min-p",
  "0.50",
  "--pool-workers",
  "5"
 ],
 ......................
 "port": 7123,
 "gpu": [
  1,
  0
 ],
 "gpus_asked": true,
 "layer_split": "22",
 "gpu_order": "as_given",
 "fit_max_tokens": true,
 "vision": {
  .....................
  "max_tokens": 1024
 },
 "env": {
  "STRATA_ROUTE_TAIL_SKIP": "0"
 }
}
<!-- gh-comment-id:6390652290 --> @ravensergio commented on GitHub (Oct 24, 2026): Nice. Sorry I forgot about that . I noticed this also Strata on auto doesn't fill the second gpu in my case. Coming from a fork strata-DualGPU which made auto work, I had also to do layer split 22 (cause both my cards are headless so i had all the vram free) Here are my params, just to share maybe something you can compare (Windows- using Gyro M here on 5070 ti + 5060 ti (32 VRAM + 32 gb ram). I get 100-150 tps with this model (5060 ti makes it slower). For detecting : "--pcie-frac", "0.75", "--spec-min-p", "0.50", "--pool-workers", "5" , I ran the CALIBRATE module from strata so it measured the best settings for me. Params: ``` { "exe": "xx\\engine\\strata.exe", "args": [ ..................... "--expert-cache", "auto", "--prefill", "auto", "--spec", "4", "--mtp", "xx\\Strata-data\\mtp\\rt", "--max-context", "211072", "--kv", "k8v4", "--resident-experts", "--vision", "--vram-reserve-mib", "280", "--vram-reserve-later-mib", "580", "--resident-budget-gib", "16", "--trim-stage-weights", "--pipeline-windows", "2", "--pcie-frac", "0.75", "--spec-min-p", "0.50", "--pool-workers", "5" ], ...................... "port": 7123, "gpu": [ 1, 0 ], "gpus_asked": true, "layer_split": "22", "gpu_order": "as_given", "fit_max_tokens": true, "vision": { ..................... "max_tokens": 1024 }, "env": { "STRATA_ROUTE_TAIL_SKIP": "0" } } ```
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#1651
No description provided.