Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Bug#853132: pulseaudio-module-jack: modules fail to load due to real-time scheduling

122 views
Skip to first unread message

Vít Novotný

unread,
Jan 29, 2017, 8:30:02 PM1/29/17
to
Package: pulseaudio-module-jack
Version: 9.0-5
Severity: grave
Justification: renders package unusable

Dear Maintainer,

After installing pulseaudio-module-jack, running jackd via

$ jackd -d alsa

and executing

$ pactl load-module module-jack-sink
$ pactl load-module module-jack-source

the following messages are written out to `/var/log/syslog`:

Jan 30 01:19:36 inspiron pulseaudio[1198]: [pulseaudio] sink.c: Default and alternate sample rates are the same.
Jan 30 01:19:36 inspiron pulseaudio[1198]: [pulseaudio] module-jack-sink.c: JACK error >Cannot use real-time scheduling (RR/5)(1: Operation not permitted)<
Jan 30 01:19:36 inspiron pulseaudio[1198]: [pulseaudio] module-jack-sink.c: JACK error >JackClient::AcquireSelfRealTime error<
Jan 30 01:19:48 inspiron pulseaudio[1198]: [pulseaudio] source.c: Default and alternate sample rates are the same.
Jan 30 01:19:48 inspiron pulseaudio[1198]: [pulseaudio] module-jack-source.c: JACK error >Cannot use real-time scheduling (RR/5)(1: Operation not permitted)<
Jan 30 01:19:48 inspiron pulseaudio[1198]: [pulseaudio] module-jack-source.c: JACK error >JackClient::AcquireSelfRealTime error<

Note that the debian installer correctly produced the file
`/etc/security/limits.d/audio.conf` with the following contents:

# Provided by the jackd package.
#
# Changes to this file will be preserved.
#
# If you want to enable/disable realtime permissions, run
#
# dpkg-reconfigure -p high jackd

@audio - rtprio 95
@audio - memlock unlimited
#@audio - nice -19

and both my user account and pulse are in the unix group `audio`. Since
`jackd` (package `jackd2`, 1.9.10+20150825git1ed50c92~dfsg-4) alone has
no issue setting its real-time priority to 20 and above, this seems to
be an issue with `libjack`.

If I run

$ pactl set-default-sink jack_out
$ pactl set-default-source jack_in

afterwards, the pulseaudio default sink and source are redirected, but
no sound results (userland applications such as mpv claim that the
,,stream is suspended``). If I run `jackd` outside real-time mode:

$ jackd --no-realtime -d alsa

then only the following logs are produced:

Jan 30 01:19:36 inspiron pulseaudio[1198]: [pulseaudio] sink.c: Default and alternate sample rates are the same.
Jan 30 01:19:48 inspiron pulseaudio[1198]: [pulseaudio] source.c: Default and alternate sample rates are the same.

but after running

$ pactl set-default-sink jack_out
$ pactl set-default-source jack_in

there is no sound nevertheless.

Note that both pulseaudio and jack work flawlessly separately. The
issue is in making pulseaudio work as a jack client.

-- System Information:
Debian Release: 9.0
APT prefers testing
APT policy: (990, 'testing'), (500, 'unstable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.9.0-1-amd64 (SMP w/4 CPU cores)
Locale: LANG=cs_CZ.UTF-8, LC_CTYPE=cs_CZ.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages pulseaudio-module-jack depends on:
ii libc6 2.24-8
ii libcap2 1:2.25-1
ii libdbus-1-3 1.10.14-1
ii libjack-jackd2-0 [libjack-0.116] 1.9.10+20150825git1ed50c92~dfsg-4+b1
ii libpulse0 9.0-5
ii pulseaudio 9.0-5

pulseaudio-module-jack recommends no packages.

pulseaudio-module-jack suggests no packages.

-- no debconf information

Felipe Sateler

unread,
Feb 4, 2017, 8:10:02 AM2/4/17
to
On 30 January 2017 at 13:33, Vít Novotný <wit...@mail.muni.cz> wrote:
> ( 631.872| 0.000) I: [pulseaudio] module-stream-restore.c: Restoring volume for sink input sink-input-by-application-name:mpv Media Player.
> ( 631.872| 0.000) I: [pulseaudio] module-stream-restore.c: Restoring mute state for sink input sink-input-by-application-name:mpv Media Player.
> ( 631.872| 0.000) D: [pulseaudio] module-suspend-on-idle.c: Sink alsa_output.pci-0000_00_1f.3.analog-stereo becomes busy, resuming.
> ( 631.872| 0.000) D: [pulseaudio] module-suspend-on-idle.c: Sink alsa_output.pci-0000_00_1f.3.analog-stereo becomes idle, timeout in 5 seconds.
> ( 631.872| 0.000) D: [pulseaudio] memblockq.c: memblockq requested: maxlength=33554432, tlength=0, base=4, prebuf=0, minreq=1 maxrewind=0
> ( 631.872| 0.000) D: [pulseaudio] memblockq.c: memblockq sanitized: maxlength=33554432, tlength=33554432, base=4, prebuf=0, minreq=4 maxrewind=0
> ( 631.872| 0.000) I: [pulseaudio] sink-input.c: Created input 9 "audio stream" on alsa_output.pci-0000_00_1f.3.analog-stereo with sample spec s16le 2ch 44100Hz and channel map front-left,front-right

This shows mpv, in the first attempt, still tries to output to the
sound card and not to the jack sound server. You can use pavucontrol
to move the stream from the sound card to the jack server.

--

Saludos,
Felipe Sateler

Vít Novotný

unread,
Feb 5, 2017, 10:10:03 AM2/5/17
to
Which is strange, since I changed the default source / sink before I ran
mpv. Perhaps this could be the doing of the KDE Plasma component which
spawns pulseaudio, since this beavior no longer occurs if I kill and
manually run pulseaudio. I will test whether this bug persists on
pulseaudio-module-jack 10.0-1 and if so, I will give it a further look
next week.

Best,
Vít Novotný

>
> --
>
> Saludos,
> Felipe Sateler

Felipe Sateler

unread,
Feb 5, 2017, 10:40:02 AM2/5/17
to
Control: severity -1 normal

On 5 February 2017 at 12:06, Vít Novotný <wit...@mail.muni.cz> wrote:
> On Sat, Feb 04, 2017 at 09:59:50AM -0300, Felipe Sateler wrote:
>> On 30 January 2017 at 13:33, Vít Novotný <wit...@mail.muni.cz> wrote:
>> > ( 631.872| 0.000) I: [pulseaudio] module-stream-restore.c: Restoring volume for sink input sink-input-by-application-name:mpv Media Player.
>> > ( 631.872| 0.000) I: [pulseaudio] module-stream-restore.c: Restoring mute state for sink input sink-input-by-application-name:mpv Media Player.
>> > ( 631.872| 0.000) D: [pulseaudio] module-suspend-on-idle.c: Sink alsa_output.pci-0000_00_1f.3.analog-stereo becomes busy, resuming.
>> > ( 631.872| 0.000) D: [pulseaudio] module-suspend-on-idle.c: Sink alsa_output.pci-0000_00_1f.3.analog-stereo becomes idle, timeout in 5 seconds.
>> > ( 631.872| 0.000) D: [pulseaudio] memblockq.c: memblockq requested: maxlength=33554432, tlength=0, base=4, prebuf=0, minreq=1 maxrewind=0
>> > ( 631.872| 0.000) D: [pulseaudio] memblockq.c: memblockq sanitized: maxlength=33554432, tlength=33554432, base=4, prebuf=0, minreq=4 maxrewind=0
>> > ( 631.872| 0.000) I: [pulseaudio] sink-input.c: Created input 9 "audio stream" on alsa_output.pci-0000_00_1f.3.analog-stereo with sample spec s16le 2ch 44100Hz and channel map front-left,front-right
>>
>> This shows mpv, in the first attempt, still tries to output to the
>> sound card and not to the jack sound server. You can use pavucontrol
>> to move the stream from the sound card to the jack server.
>
> Which is strange, since I changed the default source / sink before I ran
> mpv.

Not really. As the name suggests, the command only sets the default
sink. But there is also the stream-restore module, that remembers
where each stream goes, and tries to restore them to the same output
they were playing to.

> Perhaps this could be the doing of the KDE Plasma component which
> spawns pulseaudio, since this beavior no longer occurs if I kill and
> manually run pulseaudio.

You can also test this by using the KDE control panel to alter the
priority of the jack output.

> I will test whether this bug persists on
> pulseaudio-module-jack 10.0-1 and if so, I will give it a further look
> next week.

OK. In the meantime, I'm downgrading the severity.


--

Saludos,
Felipe Sateler
0 new messages