-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG]: Unable to start when memory exceeds 27647 #17
Comments
This is dependent on the system you're running on, no? 27GiB of RAM is no small amount. How much RAM is on the system you're running with? |
@tylerfanelli Sorry. I forgot to add my system information. System: Darwin Arm64 (M3) |
Works fine here with arbitrarily large memory sizes, even larger than the host's RAM (the memory for the guest is not preallocated). Could you please build krunkit with #18 and re-run your test with |
@slp Okay, I'll give it a try now. |
LOG:
|
I found that orbstack also encountered a similar issue, but since it is closed-source software, I am not sure how it was fixed: orbstack/orbstack#1178 |
I added some logs to libkrun/hvf/src/lib.rs#L201 and found that the return value of HV_BAD_ARGUMENT: https://developer.apple.com/documentation/hypervisor/1585168-hypervisor_errors/hv_bad_argument |
Automatically adjust VRAM so VRAM+RAM doesn't exceed the space available in a 36 bit IPA, accounting for the start address and rounding in libkrun, which sets an upper limit of ~62GiB. Also, reject a memory configuration larger than 60 GiB to ensure we leave some room for VRAM. Fixes: containers#17 Signed-off-by: Sergio Lopez <[email protected]>
Could you please give #19 a try? I think it should work with arbitrary memory configurations, even ones exceeding the memory available on the host (with the upper bound of 60 GiB). |
@slp It worked! Thanks! |
Automatically adjust VRAM so VRAM+RAM doesn't exceed the space available in a 36 bit IPA, accounting for the start address and rounding in libkrun, which sets an upper limit of ~62GiB. Also, reject a memory configuration larger than 60 GiB to ensure we leave some room for VRAM. Fixes: #17 Signed-off-by: Sergio Lopez <[email protected]>
After testing, when the
--memory
value is greater than 27647, krun will fail to start. The error is as follows:The text was updated successfully, but these errors were encountered: