Skip to content

Commit cb3c19f

Browse files
committed
docs/guides: add tips about enabling KVM support for random number generation
Signed-off-by: Yang Hu <[email protected]>
1 parent a0fbcdb commit cb3c19f

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

content/guides/internals.mdx

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,11 +164,20 @@ Notice that each line in `make`'s output consists of an operation in the build p
164164
Now that the unikernel image has been sucessfully generated, we can finally run it using the QEMU Virtual Machine Monitor:
165165

166166
```console
167-
$ qemu-system-x86_64 -kernel build/helloworld_qemu-x86_64 -nographic
167+
$ qemu-system-x86_64 -kernel workdir/build/helloworld_qemu-x86_64 -nographic -enable-kvm -cpu host
168168
```
169169

170170
The `-kernel` option is used for indicating the image to be booted by the machine, while the `-nographic` option is simply for using QEMU as a command-line program by redirecting all output to the terminal.
171171

172+
Since [Unikraft v0.17.0 Calypso](https://github.com/unikraft/unikraft/releases/tag/RELEASE-0.17.0), random number generation is reliant on CPU support.
173+
This means that, when using QEMU, one of two options must be enabled:
174+
175+
- You are using QEMU >= 8.0
176+
- You are using hardware acceleration, with KVM
177+
178+
This is why we use `-enable-kvm` and `-cpu host` flags to explictly enable them.
179+
If you are running on other platforms, please remove them.
180+
172181
```console
173182
SeaBIOS (version Arch Linux 1.16.2-1-1)
174183

0 commit comments

Comments
 (0)