1

I am running a script on Ubuntu 20.04.6 which has a lot of the same output like

ALSA lib pcm.c:8526:(snd_pcm_recover) underrun occurred

is there a way to just suppress these messages? I know it has to do with audio, and the script plays a video with moviepy, but I am not interested in the audio at all. Maybe I can fix ALSA, install something, uninstall something? I just want these messages go away...

matanox
  • 2,293
Alex
  • 801
  • I get the same message by just letting q4vl2 record video with audio: ALSA lib pcm.c:8568:(snd_pcm_recover) underrun occurred. Slightly different line of code emitting the message in my 22.04 which was upgraded from 20.04. Audio is working fine elsewhere, i.e. in the browser and through some python audio libraries. But I wonder what to make out of this ALSA message which I get from qv4l2 at an alarming rate while it is presumably recording audio. – matanox Feb 08 '24 at 17:43
  • lower the rate as in ''arecord -f cd -d 10 -r 8000 --device="hw:1,0" /tmp/a.wav'' – petep Feb 08 '24 at 18:55
  • really much appreciated @petep. does this mean that you believe the consuming side is expecting a rate of data transfer which ALSA through the underlying audio driver/s is unable to provide? or is the rationale totally different? – matanox Feb 08 '24 at 19:28
  • Increasing q4vl2's audio buffer from 33ms to 100ms and more, these messages no longer emit. I can only guess that the original audio buffer size was not a fit for the read and write strategies of both ends of the data transfer, as those interact with the particular hardware speeds, and that the current size probably is a good fit (?). thanks again. – matanox Feb 08 '24 at 19:32

0 Answers0