Skip to content
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]: VAAPI in Container with WSL2 Windows not working #1809

Open
DeltaTango69 opened this issue May 31, 2024 · 1 comment
Open

[Bug]: VAAPI in Container with WSL2 Windows not working #1809

DeltaTango69 opened this issue May 31, 2024 · 1 comment
Assignees

Comments

@DeltaTango69
Copy link

Which component impacted?

Not sure

Is it regression? Good in old configuration?

No, this issue exist a long time

What happened?

image

docker-compose.yml

services:
frigate:
container_name: frigate
privileged: true # this may not be necessary for all setups
restart: unless-stopped
image: ghcr.io/blakeblackshear/frigate:stable
shm_size: "80mb" # update for your cameras based on calculation above
devices:
#- /dev/bus/usb:/dev/bus/usb # Passes the USB Coral, needs to be modified for other versions
#- /dev/apex_0:/dev/apex_0 # Passes a PCIe Coral, follow driver instructions here https://coral.ai/docs/m2/get-started/#2a-on-linux
#- /dev/video11:/dev/video11 # For Raspberry Pi 4B
- /dev/dri/renderD128:/dev/dri/renderD128 # For intel hwaccel, needs to be updated for your hardware
- /dev/dri/card0:/dev/dri/card0
- /dev/dri/:/dev/dri/
- /dev/dxg/:/dev/dxg
volumes:
- /etc/localtime:/etc/localtime:ro
- ./config:/config
- ./media:/media/frigate
- type: tmpfs # Optional: 1GB of memory, reduces SSD/SD Card wear
target: /tmp/cache
tmpfs:
size: 1000000000
ports:
- "5000:5000"
- "8554:8554" # RTSP feeds
- "8555:8555/tcp" # WebRTC over tcp
- "8555:8555/udp" # WebRTC over udp
environment:
- TZ=Europe/Berlin
- LIBVA_DRIVER_NAME=d3d12
- LD_LIBRARY_PATH=/usr/lib/wsl/lib
#- FRIGATE_RTSP_PASSWORD: "password"

What's the usage scenario when you are seeing the problem?

Others

What impacted?

No response

Debug Information

vainfo

error: XDG_RUNTIME_DIR is invalid or not set in the environment.
error: can't connect to X server!
libva info: VA-API version 1.17.0
libva info: Trying to open /usr/lib/x86_64-linux-gnu/dri/vgem_drv_video.so
libva info: va_openDriver() returns -1
vaInitialize failed with error code -1 (unknown libva error),exit

apt list mesa-va-drivers -a

Listing... Done
mesa-va-drivers/now 22.3.6-1+deb12u1 amd64 [installed,local]
mesa-va-drivers/oldstable 20.3.5-1 amd64

vainfo --display drm --device /dev/dri/card0

libva info: VA-API version 1.17.0
libva info: Trying to open /usr/lib/x86_64-linux-gnu/dri/vgem_drv_video.so
libva info: va_openDriver() returns -1
vaInitialize failed with error code -1 (unknown libva error),exit

^C

ls /dev/dri

card0 renderD128

^C

lspci -nn |grep -Ei 'VGA|DISPLAY'

/bin/sh: 12: lspci: not found

Do you want to contribute a patch to fix the issue?

None

@iori2333
Copy link

I found a thread which said QSV wouldn't be supported for WSL2.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants