[FFmpeg-user] Ubuntu 22.04 audio capture issue

Christof Ameye (Oscart Group) christof.ameye at oscart.eu
Mon Nov 28 18:14:55 EET 2022


Hi all,

We are using an Ubuntu 22.04 install with X (not Wayland) on an Intel NUC 11 Pro  NUC11TNKi3.
When simply launching a terminal, we can record audio easily, and with success:

      ffmpeg -f alsa -i default  alsaout.wav

However, we need to launch this as the same user as we used in X, but from a daemon. We use sudo to become that same user and launch the exact same ffmpeg command as above.

This results in ffmpeg giving the following error:

      [alsa @ 0x5560dc7f9e40] cannot open audio device default (No such file or directory)
      default: Input/output error

In both situations we can run alsamixer with success, and 'arecord -L' shows:

null
    Discard all samples (playback) or generate zero samples (capture)
default
    Playback/recording through the PulseAudio sound server
samplerate
    Rate Converter Plugin Using Samplerate Library
speexrate
    Rate Converter Plugin Using Speex Resampler
jack
    JACK Audio Connection Kit
oss
    Open Sound System
pulse
    PulseAudio Sound Server
upmix
    Plugin for channel upmix (4,6,8)
vdownmix
    Plugin for channel downmix (stereo) with a simple spacialization
usbstream:CARD=PCH
    HDA Intel PCH
    USB Stream Output

However also in both cases, 'arecord -l' only shows

      **** List of CAPTURE Hardware Devices ****

If we use ssh to that same machine, using that same user, it is also working fine.

We have tried to find any indications what is the cause (like making that user part of the audio group), but none of it worked.

In previous versions of Ubuntu (LTS), this was no problem at all.

Any hints or ideas are welcome,

Christof



Christof Ameye
CTO
T   +32 56 74 50 10
E   christof.ameye at oscart.eu
oscart.eu
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image442725.png
Type: image/png
Size: 4641 bytes
Desc: image442725.png
URL: <https://ffmpeg.org/pipermail/ffmpeg-user/attachments/20221128/d974e8f4/attachment.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001609.png
Type: image/png
Size: 444 bytes
Desc: image001609.png
URL: <https://ffmpeg.org/pipermail/ffmpeg-user/attachments/20221128/d974e8f4/attachment-0001.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image719516.png
Type: image/png
Size: 712 bytes
Desc: image719516.png
URL: <https://ffmpeg.org/pipermail/ffmpeg-user/attachments/20221128/d974e8f4/attachment-0002.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image695445.png
Type: image/png
Size: 427 bytes
Desc: image695445.png
URL: <https://ffmpeg.org/pipermail/ffmpeg-user/attachments/20221128/d974e8f4/attachment-0003.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image002752.png
Type: image/png
Size: 556 bytes
Desc: image002752.png
URL: <https://ffmpeg.org/pipermail/ffmpeg-user/attachments/20221128/d974e8f4/attachment-0004.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image316852.png
Type: image/png
Size: 452 bytes
Desc: image316852.png
URL: <https://ffmpeg.org/pipermail/ffmpeg-user/attachments/20221128/d974e8f4/attachment-0005.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image656355.png
Type: image/png
Size: 69356 bytes
Desc: image656355.png
URL: <https://ffmpeg.org/pipermail/ffmpeg-user/attachments/20221128/d974e8f4/attachment-0006.png>


More information about the ffmpeg-user mailing list