You are not logged in.

#1 2014-06-22 13:14:50

Mr. Alex
Member
Registered: 2010-08-26
Posts: 623

The "alsa audio output error: cannot write: Broken pipe" problem

[Solved]
(No place for this word in the Subject field, so I put it here.)

Hi Arch community!

I noticed I have this problem and not sure when in started. Several months ago I bought and installed new videocard "GeForce GT 630". Right after installation I lost sound in the system. Having internal sound card (in mainboard) and SB Audigy2 (PCI), I searched for solution and found I had to disable "snd_hda_intel" module to restore sound to work through PCI sound card. Did it.

echo "blacklist snd_hda_intel" >> /etc/modprobe.d/no-nvidia-sound.conf

After that sound was working as it should. And I noticed recently that during playing of any sound file the sound interrupts. If run VLC from CLI I get "alsa audio output error: cannot write: Broken pipe" message. And my system hasn't been upgraded since I don't know when. I still ran Firefox 26. So googled again and found it's a bug in a kernel or somewhere else.

==========================================
https://bugs.freedesktop.org/show_bug.cgi?id=69942 :
2013-10-01 01:39:40 UTC
I ran a system update last night, and this issue appears to have been corrected.
==========================================

And so I thought upgrade would fix my problem since mainstream bug is fixed. After upgrade sound interrupts again, maybe even more often.

Do you guys have this issue and does anyone have a solution?

Last edited by Mr. Alex (2014-06-26 18:55:59)

Offline

#2 2014-06-22 16:56:12

emeres
Member
Registered: 2013-10-08
Posts: 1,570

Re: The "alsa audio output error: cannot write: Broken pipe" problem

Not particularly wise to blacklist the module, since it probably is also used by the integrated sound card. With vid and pid you could just disable the nvidia card alone using parameter enable=0. Unless you do not mind having both disabled.

Look through dmesg and provide some more information:

systool -v -m snd_emu10k1 #or whatever your Audigy uses

You may want to increase max_buffer_size parameter.

Offline

#3 2014-06-25 16:01:41

Mr. Alex
Member
Registered: 2010-08-26
Posts: 623

Re: The "alsa audio output error: cannot write: Broken pipe" problem

Not particularly wise to blacklist the module, since it probably is also used by the integrated sound card. With vid and pid you could just disable the nvidia card alone using parameter enable=0. Unless you do not mind having both disabled.

Where do I need to input "enable=0"? When I was searching for solution to make my Creative card work with new nVidia card I installed, the only way I found was blacklisting the module.

dmesg says:

...
[   20.448086] nvidia 0000:02:00.0: irq 42 for MSI/MSI-X
[   21.112331] NVRM: Your system is not currently configured to drive a VGA console
[   21.112340] NVRM: on the primary VGA device. The NVIDIA Linux graphics driver
[   21.112345] NVRM: requires the use of a text-mode VGA console. Use of other console
[   21.112349] NVRM: drivers including, but not limited to, vesafb, may result in
[   21.112352] NVRM: corruption and stability problems, and is not supported.

Then:

lsmod | grep 'snd' 
snd_ca0106             36242  0 
snd_ac97_codec        114896  1 snd_ca0106
ac97_bus                1270  1 snd_ac97_codec
snd_rawmidi            20278  1 snd_ca0106
snd_seq_device          5244  1 snd_rawmidi
snd_pcm                83207  2 snd_ac97_codec,snd_ca0106
snd_timer              19294  1 snd_pcm
snd                    60780  6 snd_ac97_codec,snd_timer,snd_pcm,snd_rawmidi,snd_seq_device,snd_ca0106
soundcore               5551  1 snd

I guess my card is "snd_ca0106". If yes,

# systool -v -m snd_ca0106    
Module = "snd_ca0106"

  Attributes:
    coresize            = "36242"
    initsize            = "0"
    initstate           = "live"
    refcnt              = "0"
    taint               = ""
    uevent              = <store method only>

  Parameters:
    enable              = "Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y"
    id                  = "(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null)"
    index               = "-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1"
    subsystem           = "0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0"

  Sections:
    .bss                = "0xffffffffa0814780"
    .data               = "0xffffffffa0813300"
    .exit.text          = "0xffffffffa0811a1e"
    .gnu.linkonce.this_module= "0xffffffffa0814500"
    .init.text          = "0xffffffffa0817000"
    .note.gnu.build-id  = "0xffffffffa0811a30"
    .rodata             = "0xffffffffa0811a80"
    .rodata.str1.1      = "0xffffffffa08123dc"
    .rodata.str1.8      = "0xffffffffa0812130"
    .strtab             = "0xffffffffa0818c10"
    .symtab             = "0xffffffffa0817020"
    .text               = "0xffffffffa080d000"
    __mcount_loc        = "0xffffffffa0812f98"
    __param             = "0xffffffffa0812f18"
    __verbose           = "0xffffffffa0814460"

Where would I look for "max_buffer_size" parameter?

Offline

#4 2014-06-26 12:40:00

emeres
Member
Registered: 2013-10-08
Posts: 1,570

Re: The "alsa audio output error: cannot write: Broken pipe" problem

Read the alsa wiki on how to use vid and pid. Add the parameter enable=0 to options to disable the card. Most modules should accepts that and snd_hda_intel certainly does.
As for the issue at hand, search for your vid:pid combination and module related problems. A look at the source code in linux_source/sound/pci/ca0106/* could show some quirks. This module does not have max_buffer_size parameter. Do you get the same error, when running speaker-test with different buffer and period sizes?

Offline

#5 2014-06-26 18:54:39

Mr. Alex
Member
Registered: 2010-08-26
Posts: 623

Re: The "alsa audio output error: cannot write: Broken pipe" problem

Thanks for advices. Yesterday I switced the device in VLC audio options from "Default audio device" (for some reason I had two of them there in a row) to "2.1 Surround output" and so far didn't have this issue.

Offline

Board footer

Powered by FluxBB