You are not logged in.

#1 2015-07-24 15:02:39

MightyPork
Member
From: Prague, Czech Republic
Registered: 2014-06-16
Posts: 93
Website

[SOLVED] Sound stops working: No space left on device (ALSA)

tl;dr solution:
Seems to be a regression in openjdk that causes this.

Restarting all your Java apps temporarily fixes the problem.
Workaround: downgrade java-7-openjdk to u79, or use java-8-openjdk as default.

---

After a suspend or even just randomly (I'm not sure of the trigger), sound sometimes stops working. Before that happens, sound works perfectly.

More relevant logs here (post #4)

* I'm using Alsa.
* PulseAudio is not installed at all
* jack and jack2 are installed as dependencies, but I'm not using them
* all gstreamer0.10* and gstreamer* packages are installed (plugins etc)

This issue started quite recently, must be some bad update.

When it happens, Clementine says it can' connect to a server. No other apps I tried can play sound, either.

16:39:44.461 WARN  unknown                          libpng warning: iCCP: known incorrect sRGB profile 
16:39:44.875 WARN  unknown                          libpng warning: iCCP: known incorrect sRGB profile 
Cannot connect to server socket err = No such file or directory
Cannot connect to server request channel
jack server is not running or cannot be started
16:39:48.370 WARN  unknown                          QTimeLine::start: already running 
Cannot connect to server socket err = No such file or directory
Cannot connect to server request channel
jack server is not running or cannot be started
16:48:37.106 WARN  unknown                          QTimeLine::start: already running 

This is a log from Clementine. I believe it first fails to connect to the default sound server (gstreamer -> alsa ?) and then tries the jack server, which is not running.

Any idea what is wrong? Misconfigured gstreamer somehow?

Last edited by MightyPork (2015-07-28 10:13:28)


If it ain't broke, pacman -Syyu and it will be

Offline

#2 2015-07-24 19:50:27

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 23,249

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

something is probably hogging your card, output of

# fuser -v /dev/snd/*

should shed some light

Offline

#3 2015-07-24 19:59:22

MightyPork
Member
From: Prague, Czech Republic
Registered: 2014-06-16
Posts: 93
Website

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

V1del wrote:

something is probably hogging your card, output of

# fuser -v /dev/snd/*

should shed some light

Thanks, will try when the glitch kicks in next time and post the output.


If it ain't broke, pacman -Syyu and it will be

Offline

#4 2015-07-25 13:19:26

MightyPork
Member
From: Prague, Czech Republic
Registered: 2014-06-16
Posts: 93
Website

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

Okay so it happened again - after a suspend.

Clementine can't play anything, saying "Can't connect to server":

$ clementine 01\ -\ A\ day\ without\ rain.MP3 
15:09:29.897 WARN  unknown                          libpng warning: iCCP: known incorrect sRGB profile 
15:09:30.316 WARN  unknown                          libpng warning: iCCP: known incorrect sRGB profile 
Cannot connect to server socket err = No such file or directory
Cannot connect to server request channel
jack server is not running or cannot be started
15:09:30.656 WARN  unknown                          QTimeLine::start: already running 

VLC can't play either - with the following messages:

vlc 01\ -\ A\ day\ without\ rain.MP3 
VLC media player 2.2.1 Terry Pratchett (Weatherwax) (revision 2.2.1-0-ga425c42)
[0000000000e13738] pulse audio output error: PulseAudio server connection failure: Connection refused
[0000000000d08028] core libvlc: Running vlc with the default interface. Use 'cvlc' to use vlc without interface.
ALSA lib pcm_dmix.c:1006:(snd_pcm_dmix_open) unable to create IPC shm instance
[0000000000e13738] alsa audio output error: cannot open ALSA device "default": No space left on device
[0000000000e13738] core audio output error: module not functional
[00007f2aecc05188] core decoder error: failed to create audio output

I've run out of audio players, so I tried Audacity, and it CAN play all right.

There are some errors in the output, nonetheless it plays.

$ audacity
Warning: Mismatch between the program and library build versions detected.
The library used 2.8 (no debug,Unicode,compiler with C++ ABI 1008,wx containers,compatible with 2.6),
and your program used 2.8 (no debug,Unicode,compiler with C++ ABI 1002,wx containers,compatible with 2.6).
ALSA lib pcm_dmix.c:1095:(snd_pcm_dmix_open) unable to initialize sum ring buffer
ALSA lib pcm.c:2267:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear
ALSA lib pcm.c:2267:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe
ALSA lib pcm.c:2267:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side
ALSA lib pcm_route.c:867:(find_matching_chmap) Found no matching channel map
ALSA lib pcm_route.c:867:(find_matching_chmap) Found no matching channel map
ALSA lib pulse.c:243:(pulse_connect) PulseAudio: Unable to connect: Connection refused

ALSA lib pulse.c:243:(pulse_connect) PulseAudio: Unable to connect: Connection refused

ALSA lib pcm_dmix.c:1095:(snd_pcm_dmix_open) unable to initialize sum ring buffer
ALSA lib pcm_dmix.c:1095:(snd_pcm_dmix_open) unable to initialize sum ring buffer
ALSA lib pcm_dmix.c:1095:(snd_pcm_dmix_open) unable to initialize sum ring buffer
Cannot connect to server socket err = No such file or directory
Cannot connect to server request channel
jack server is not running or cannot be started
Expression 'stream->playback.pcm' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 4607
ALSA lib pcm_dsnoop.c:596:(snd_pcm_dsnoop_open) unable to create IPC shm instance
Expression 'ret' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1733
Expression 'AlsaOpen( &alsaApi->baseHostApiRep, params, streamDir, &self->pcm )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1900
Expression 'PaAlsaStreamComponent_Initialize( &self->capture, alsaApi, inParams, StreamDirection_In, NULL != callback )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2167
Expression 'PaAlsaStream_Initialize( stream, alsaHostApi, inputParameters, outputParameters, sampleRate, framesPerBuffer, callback, streamFlags, userData )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2836
ALSA lib pcm_dsnoop.c:596:(snd_pcm_dsnoop_open) unable to create IPC shm instance
Expression 'ret' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1733
Expression 'AlsaOpen( &alsaApi->baseHostApiRep, params, streamDir, &self->pcm )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1900
Expression 'PaAlsaStreamComponent_Initialize( &self->capture, alsaApi, inParams, StreamDirection_In, NULL != callback )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2167
Expression 'PaAlsaStream_Initialize( stream, alsaHostApi, inputParameters, outputParameters, sampleRate, framesPerBuffer, callback, streamFlags, userData )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2836
ALSA lib pcm_dsnoop.c:596:(snd_pcm_dsnoop_open) unable to create IPC shm instance
Expression 'ret' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1733
Expression 'AlsaOpen( &alsaApi->baseHostApiRep, params, streamDir, &self->pcm )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1900
Expression 'PaAlsaStreamComponent_Initialize( &self->capture, alsaApi, inParams, StreamDirection_In, NULL != callback )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2167
Expression 'PaAlsaStream_Initialize( stream, alsaHostApi, inputParameters, outputParameters, sampleRate, framesPerBuffer, callback, streamFlags, userData )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 2836

(Audacity:27552): Gdk-WARNING **: shmget failed: error 28 (No space left on device)

I also tried Banshee and although it shows no error in the GUI, there's this error in terminal - and it does NOT play.

[Info  15:17:22.088] nereid Client Started
AL lib: (EE) ALCplaybackAlsa_open: Could not open playback device 'default': No space left on device
[Info  15:17:22.225] GStreamer version 1.4.5.0, gapless: True, replaygain: True

The error is "No space left on device" in all cases, not sure what it means.

The shm tmpfs is almost empty:

$ df
Filesystem     1K-blocks     Used Available Use% Mounted on
dev              1919184        0   1919184   0% /dev
run              1922556      768   1921788   1% /run
/dev/sda2      112370400 90682192  15957088  86% /
tmpfs            1922556    19292   1903264   2% /dev/shm
tmpfs            1922556        0   1922556   0% /sys/fs/cgroup
tmpfs            2097152    95068   2002084   5% /tmp
overlaid         2097152    95068   2002084   5% /tmp/ondra-google-chrome
tmpfs             384512       40    384472   1% /run/user/1000

Last edited by MightyPork (2015-07-25 13:22:34)


If it ain't broke, pacman -Syyu and it will be

Offline

#5 2015-07-26 16:54:10

MightyPork
Member
From: Prague, Czech Republic
Registered: 2014-06-16
Posts: 93
Website

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

Update: I've used the "pachist" and "downgrade" utilities and reverted many suspicious packages that were updated in the last few days, and the glitch seems to be gone.

I don't want to make any premature conclusions though.

Here's my list of downgraded packages:

package                     local       latest
--------------------------------------------------
alsa-lib                    1.0.28-1    1.0.29-1
alsa-plugins                1.0.28-2    1.0.29-2
gst-plugins-bad             1.4.5-1     1.4.5-4
gst-plugins-good            1.4.5-1     1.4.5-3
gstreamer0.10-bad           0.10.23-8   0.10.23-10
gstreamer0.10-bad-plugins   0.10.23-8   0.10.23-10
gstreamer0.10-good          0.10.31-6   0.10.31-8
gstreamer0.10-good-plugins  0.10.31-6   0.10.31-8
gstreamer0.10-ugly          0.10.19-13  0.10.19-15
gstreamer0.10-ugly-plugins  0.10.19-13  0.10.19-15
gtk2                        2.24.27-2   2.24.28-1
gtk3                        3.16.5-1    3.16.6-1
lib32-alsa-lib              1.0.28-1    1.0.29-1
lib32-alsa-plugins          1.0.28-1    1.0.29-2
lib32-soundtouch            1.8.0-1     1.9.0-1
phonon-qt4-gstreamer        4.8.1-1     4.8.2-1
phonon-qt5-gstreamer        4.8.1-1     4.8.2-1
qt4                         4.8.6-4     4.8.7-2
qt5-base                    5.4.1-9     5.5.0-1
soundtouch                  1.8.0-1     1.9.0-1

Not sure how to go about finding the real culprit, but it seems to be fixed for now. Can't keep them in IngorePkg forever, though.

Last edited by MightyPork (2015-07-26 17:16:32)


If it ain't broke, pacman -Syyu and it will be

Offline

#6 2015-07-27 11:56:41

MightyPork
Member
From: Prague, Czech Republic
Registered: 2014-06-16
Posts: 93
Website

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

So I've updated soundtouch and lib32-soundtouch and the glitch occured again.

1) either this is the culprit
2) or I still haven't found a solution and all the packages can be red herrings

This is so annoying sad


If it ain't broke, pacman -Syyu and it will be

Offline

#7 2015-07-27 12:34:38

ooo
Member
Registered: 2013-04-10
Posts: 1,638

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

Did you try this suggestion? It should tell you which process (if any) is keeping your sound card hanging.

V1del wrote:

something is probably hogging your card, output of

# fuser -v /dev/snd/*

should shed some light

Offline

#8 2015-07-27 12:40:12

MightyPork
Member
From: Prague, Czech Republic
Registered: 2014-06-16
Posts: 93
Website

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

ooo wrote:

Did you try this suggestion? It should tell you which process (if any) is keeping your sound card hanging.

V1del wrote:

something is probably hogging your card, output of

# fuser -v /dev/snd/*

should shed some light

Of course, there was nothing - just the audio mixer that's there always.


If it ain't broke, pacman -Syyu and it will be

Offline

#9 2015-07-27 14:16:35

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 23,249

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

That list of packages is pretty random I don't think anything in there really applies... and there would be a lot more reports if there was something broken in soundtouch I assume. Have you tried ruling out a kernel regression? try using linux-lts for example

Offline

#10 2015-07-27 14:28:35

MightyPork
Member
From: Prague, Czech Republic
Registered: 2014-06-16
Posts: 93
Website

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

V1del wrote:

That list of packages is pretty random I don't think anything in there really applies... and there would be a lot more reports if there was something broken in soundtouch I assume. Have you tried ruling out a kernel regression? try using linux-lts for example

No, I'll try that next. I'd be surprised if it's the cause, but why not.


If it ain't broke, pacman -Syyu and it will be

Offline

#11 2015-07-27 15:51:25

ooo
Member
Registered: 2013-04-10
Posts: 1,638

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

I thinking errors regarding /dev/shm being out of space might be the key issue here, and could result to other weird issues.

Are you running out of RAM by any chance when this happens? Do you have any swap or use zswap or something?

Offline

#12 2015-07-27 16:05:11

MightyPork
Member
From: Prague, Czech Republic
Registered: 2014-06-16
Posts: 93
Website

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

ooo wrote:

I thinking errors regarding /dev/shm being out of space might be the key issue here, and could result to other weird issues.

Are you running out of RAM by any chance when this happens? Do you have any swap or use zswap or something?

I have plenty swap, and 4 GB of RAM. I have a memory and swap meter on the panel so I keep an eye on that .

There's also a 3GB swap, half of ram is allocated for tmp and shm. There's no way it is full, so the messages must just be wrong.
I tried "df" when the glitch was active and shm was almost empty.

Edit: it happened again, so here you go:

~ $ df
Filesystem     1K-blocks     Used Available Use% Mounted on
dev              1919356        0   1919356   0% /dev
run              1922872      752   1922120   1% /run
/dev/sda2      112370400 86272676  20366604  81% /
tmpfs            1922872    82716   1840156   5% /dev/shm
tmpfs            1922872        0   1922872   0% /sys/fs/cgroup
tmpfs            2097152      580   2096572   1% /tmp
tmpfs             384576       48    384528   1% /run/user/1000

Ram: 2.5G / 3.7, Swap: 0%

Isn't it possible that the "full device" is the audio stream, that is somehow "full" because whatever is supposed to read and send stuff to the speakers is not doing so? (just guessing)

Last edited by MightyPork (2015-07-27 16:43:20)


If it ain't broke, pacman -Syyu and it will be

Offline

#13 2015-07-27 16:46:57

MightyPork
Member
From: Prague, Czech Republic
Registered: 2014-06-16
Posts: 93
Website

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

V1del wrote:

That list of packages is pretty random I don't think anything in there really applies... and there would be a lot more reports if there was something broken in soundtouch I assume. Have you tried ruling out a kernel regression? try using linux-lts for example

Ok so I tried linux-lts and it stopped working all the same - didn't even need suspend or any other trigger.


If it ain't broke, pacman -Syyu and it will be

Offline

#14 2015-07-27 20:10:17

ien
Member
Registered: 2014-08-06
Posts: 16

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

Hi, I have similar problem and for me it's caused by java mud client called batclient http://www.bat.org/play/batclient
I have the client open all the time and after a while something happens and newly started programs, like mpc or mpv can't use soundcard,
audacity seems to work thought.
It doesn't affect programs that use soundcard before mud client hogs it, but if I close player and start again -> no audio.
Problem is fixed temporarily by closing or restarting mud client.

mpv:

ALSA lib pcm_dmix.c:1006:(snd_pcm_dmix_open) unable to create IPC shm instance
[ao/alsa] Playback open error: No space left on device
[ao] Failed to initialize audio driver 'alsa'
Could not open/initialize audio device -> no sound.

Problem started after 26. day updates

[2015-07-20 14:38] [ALPM] upgraded libsystemd (221-2 -> 222-1)
[2015-07-20 14:38] [ALPM] upgraded systemd (221-2 -> 222-1)
[2015-07-20 14:38] [ALPM] upgraded xorg-server-common (1.17.2-3 -> 1.17.2-4)
[2015-07-20 14:38] [ALPM] upgraded xorg-server (1.17.2-3 -> 1.17.2-4)
[2015-07-20 14:38] [ALPM] upgraded ffmpeg (1:2.7.1-2 -> 1:2.7.1-3)
[2015-07-20 14:38] [ALPM] upgraded ffmpeg-compat (1:0.10.16-1 -> 1:0.10.16-2)
[2015-07-20 14:38] [ALPM] upgraded gst-plugins-ugly (1.4.5-2 -> 1.4.5-3)
[2015-07-20 14:38] [ALPM] upgraded gtk3 (3.16.5-1 -> 3.16.5-2)
[2015-07-20 14:38] [ALPM] upgraded lib32-soundtouch (1.8.0-1 -> 1.9.0-1)
[2015-07-20 14:38] [ALPM] upgraded lib32-systemd (221-1 -> 222-1)
[2015-07-20 14:38] [ALPM] upgraded libmm-glib (1.4.10-1 -> 1.4.10-2)
[2015-07-20 14:38] [ALPM] upgraded speech-dispatcher (0.8.3-2 -> 0.8.3-4)
[2015-07-20 14:38] [ALPM] upgraded systemd-sysvcompat (221-2 -> 222-1)
[2015-07-20 14:38] [ALPM] upgraded x264 (2:144.20150223-1 -> 2:148.20150717-1)

[2015-07-26 00:19] [ALPM] upgraded libepoxy (1.2-2 -> 1.3.1-1)
[2015-07-26 00:19] [ALPM] upgraded qt4 (4.8.7-1 -> 4.8.7-2)
[2015-07-26 00:19] [ALPM] upgraded libtool (2.4.6-2 -> 2.4.6-3)
[2015-07-26 00:19] [ALPM] upgraded speech-dispatcher (0.8.3-4 -> 0.8.3-5)
[2015-07-26 00:19] [ALPM] upgraded ffmpeg (1:2.7.1-3 -> 1:2.7.2-1)
[2015-07-26 00:19] [ALPM] upgraded gtk3 (3.16.5-2 -> 3.16.6-1)
[2015-07-26 00:19] [ALPM] upgraded jre7-openjdk-headless (7.u79_2.5.5-1 -> 7.u85_2.6.1-1)
[2015-07-26 00:19] [ALPM] upgraded jre7-openjdk (7.u79_2.5.5-1 -> 7.u85_2.6.1-1)
[2015-07-26 00:19] [ALPM] upgraded jdk7-openjdk (7.u79_2.5.5-1 -> 7.u85_2.6.1-1)
[2015-07-26 00:19] [ALPM] upgraded linux-firmware (20150527.3161bfa-1 -> 20150722.e10097a-1)

e: List only has ~relevant packages.

Last edited by ien (2015-07-27 20:22:47)

Offline

#15 2015-07-27 20:21:01

MightyPork
Member
From: Prague, Czech Republic
Registered: 2014-06-16
Posts: 93
Website

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

ien wrote:

Hi, I have similar problem and for me it's caused by java mud client called batclient http://www.bat.org/play/batclient
I have the client open all the time and after a while something happens and newly started programs, like mpc or mpv can't use soundcard,
audacity seems to work thought.
It doesn't affect programs that use soundcard before mud client hogs it, but if I close player and start again -> no audio.
Problem is fixed temporarily by closing or restarting mud client.

Are you quite sure it's caused by the mud client? Because I don't have anything like that - only java thing is PhpStorm (an IDE - with no sound effects or anything).

I'm beginning to think it could be maybe related to the systemd update, next thing I'll try.

Last edited by MightyPork (2015-07-27 20:23:27)


If it ain't broke, pacman -Syyu and it will be

Offline

#16 2015-07-27 20:24:31

ien
Member
Registered: 2014-08-06
Posts: 16

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

I tried closing programs one by one and closing mud client helps, tested few times today.

Offline

#17 2015-07-28 00:19:53

MightyPork
Member
From: Prague, Czech Republic
Registered: 2014-06-16
Posts: 93
Website

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

ien wrote:

I tried closing programs one by one and closing mud client helps, tested few times today.

Oh man you're right! Excellent observation!!

I restarted my one Java application and it's working again. So, to downgrade all java packages? Let's try.....

Last edited by MightyPork (2015-07-28 00:24:04)


If it ain't broke, pacman -Syyu and it will be

Offline

#18 2015-07-28 09:58:53

ien
Member
Registered: 2014-08-06
Posts: 16

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

Downgrading java packages seems to help, no problems so far after 5 hours.

Offline

#19 2015-08-26 11:49:36

nyddogghr
Member
Registered: 2013-05-12
Posts: 14

Re: [SOLVED] Sound stops working: No space left on device (ALSA)

Hi,

Just to mention : I have all up to date packages and it still happens. This post helped me :

fuser -v /dev/snd/*

This command gave me mpd, so I killed it. smile
And after this it worked. Another way is to reboot.

Offline

Board footer

Powered by FluxBB