[SOLVED] Owncast, SELinux, Podman, Hardware Accelaration
from Nico_198X@europe.pub to selfhosted@lemmy.world on 09 Jul 09:25
https://europe.pub/post/2339510

SOLVED: turns out mesa is not enough for this. i also had to install:

mesa-va-gallium mesa-dri-gallium

now we’re good!


hi all!

i’ve hit a wall here and could use your input if you have any thoughts!

i’m running Owncast latest via rootful Podman on a distro with SELinux.

i’m trying to implement hardware acceleration via the server’s AMD GPU, but it is not working.

AMD Radeon RX 7600

Kernel: 6.15.4-1-default

i’ve turned VAAPI on in the web admin settings.

the container comes with ffmpeg 6 and libva.

For SELinux, i’ve run:

setsebool -P container_use_devices true

In my quadlet i’ve added:

[Container]

AddDevice=/dev/dri

Exec=apk add mesa

the devices appear rw in the container:

/app # ls -l /dev/dri

total 0

crw-rw---- 1 root 486 226, 0 Jul 9 15:58 card0

crw-rw---- 1 root 489 226, 128 Jul 9 15:58 renderD128

here is the error i’m getting:

time=“2025-07-09T15:58:46Z” level=error msg=“[AVHWDeviceContext @ 0x7f96891c7cc0] Failed to initialise VAAPI connection: -1 (unknown libva error).”

time=“2025-07-09T15:58:46Z” level=error msg=“Failed to set value ‘/dev/dri/renderD128’ for option ‘vaapi_device’: I/O error”

time=“2025-07-09T15:58:46Z” level=error msg=“transcoding error. look at data/logs/transcoder.log to help debug. your copy of ffmpeg may not support your selected codec of h264_vaapi https://owncast.online/docs/codecs/”

time=“2025-07-09T16:04:25Z” level=info msg=“Inbound stream connected from 192.168.0.235:42698”

time=“2025-07-09T16:04:25Z” level=info msg=“Processing video using codec VA-API with 3 output qualities configured.”

time=“2025-07-09T16:04:25Z” level=error msg=“[AVHWDeviceContext @ 0x7f8a2a047cc0] Failed to initialise VAAPI connection: -1 (unknown libva error).”

time=“2025-07-09T16:04:25Z” level=error msg=“Failed to set value ‘/dev/dri/renderD128’ for option ‘vaapi_device’: I/O error”

time=“2025-07-09T16:04:25Z” level=info msg=“Inbound stream disconnected.”

time=“2025-07-09T16:04:25Z” level=error msg=“unable to write rtmp packet io: read/write on closed pipe”

time=“2025-07-09T16:04:25Z” level=error msg=“transcoding error. look at data/logs/transcoder.log to help debug. your copy of ffmpeg may not support your selected codec of h264_vaapi https://owncast.online/docs/codecs/”

any help to troubleshoot this would be most appreciated! thank you!

#selfhosted

threaded - newest

malwieder@feddit.org on 09 Jul 10:07 collapse

What exact GPU model? Kernel version? Have you tried it with SELinux disabled temporarily?

Nico_198X@europe.pub on 09 Jul 10:10 next collapse

AMD Radeon RX 7600

6.15.4-1-default

i have not tried that. i’ll give that a go. i ASSUME it’s a selinux permissions issue, but i thought i had that all cleared.

Nico_198X@europe.pub on 09 Jul 10:17 next collapse

so, actually no change even with setting SELinux to Permissive. so i guees it isn’t SELinux after all…

Nico_198X@europe.pub on 09 Jul 10:26 collapse

thank you, i figured it out!

malwieder@feddit.org on 09 Jul 12:19 collapse

Would be awesome if you’d share your solution for the next person encountering the same issue :)

Nico_198X@europe.pub on 09 Jul 23:20 collapse

it’s all in the edited op!