docs: update virt/vm/display

This commit is contained in:
lukas 2022-08-12 23:47:43 +00:00
parent d9b9b95817
commit 91ecf7e992

View File

@ -2,7 +2,7 @@
title: Display title: Display
description: How to access a virtual machine's display description: How to access a virtual machine's display
published: true published: true
date: 2022-08-01T10:20:00.982Z date: 2022-08-12T23:47:40.458Z
tags: tags:
editor: markdown editor: markdown
dateCreated: 2022-07-31T09:22:05.854Z dateCreated: 2022-07-31T09:22:05.854Z
@ -10,7 +10,7 @@ dateCreated: 2022-07-31T09:22:05.854Z
# Display # Display
A virtual display can be attached to a virtual machine to se the content of it. It is a must-have for in non-headless scenarios. A virtual display can be attached to a virtual machine to se the content of it. It is a must-have for non-headless scenarios.
## Summary ## Summary
@ -30,25 +30,52 @@ A virtual display can be attached to a virtual machine to se the content of it.
The Simple DirectMedia Layer is a local-only low-latency display. The Simple DirectMedia Layer is a local-only low-latency display.
> *It is currently only avalable with virtual machines created using the QEMU/KVM **User Session** mode.* > *SDL is currently only avalable with virtual machines created using the QEMU/KVM **User Session** mode*
{.is-info}
> *As of now, this method is not compatible with Wayland* {.is-info}
> *Mouse grab does not currently work in SDL*
{.is-warning} {.is-warning}
* Example of an XML configuration, with OpenGL enabled. This example requires 3D-capable graphic card, such as ``virtio-gpu``. #### SELinux configuration
By default, SELinux will block access to X Windows Server for the virtualization stack.
* Set new rule
```
sudo setsebool -P virt_use_xserver 1
```
* Do some magic trick
```
sudo ausearch -c 'qemu-system-x86' --raw | audit2allow -M my-qemusystemx86
k
```
* And another one
```
sudo semodule -X 300 -i my-qemusystemx86.pp
```
#### XML SDL
* Example of an XML SDL configuration, with OpenGL enabled. This example requires a 3D-capable graphic card to be attached to the guest computer, such as ``virtio-gpu`` or ``vfio-pci``.
``` ```
<graphics type="sdl" display=":0.0"> <graphics type="sdl" display=":0.0">
<gl enable="yes"/> <gl enable="yes"/>
</graphics> </graphics>
``` ```
The display resolution might not exceed that of your physical screen. The display resolution of your newly created should not exceed that of your physical screen.
Mouse capture doesn't work
### Xephyr ### Xephyr
* *to-be done* * *to-be done*
### WebRTC ### WebRTC
* *to-be done* * *to-be done*
@ -57,7 +84,7 @@ Mouse capture doesn't work
* *to-be done* * *to-be done*
### Virtio-wayland ### virtio-wayland
* *to-be done* * *to-be done*