You are not logged in.

Dear visitor, welcome to If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.


Friday, February 16th 2007, 1:40am

routing sound to multiple soundcards

I have two soundcards in my FC4 box: a basic two-channel card connected to small PC speakers, and a more sophisticated multi-channel card for multitrack recording (M-Audio 1010LT), which is connected to a better monitoring system. My hope, when I installed the second card, was that system sounds (notifications, alarms, etc.) would be routed to the basic card, and I could still do serious audio work on the second card, using JACK.

I was pleasantly surprised when I installed the second card, to find that it worked exactly as I'd hoped it would, i.e. KDE sent all its sounds to the basic card, so I would be able to use the second card with JACK for more complex audio work. Even better was that when I started up amarok to listen to some music, the sound was automatically routed to the better card, and I could listen on the better monitors. I did not have JACK running, and had done nothing intentional to accomplish this. The magic of KDE on Fedora Linux!

That was until I recently moved the PC to a different location, and after hooking it back up and rebooting, the function of the cards is now reversed: now KDE's system sounds come out of the second card, and amarok's output is sent to the basic card with its cheap little speakers! Just the opposite of what I want.

So, now I'm forced to figure out how I got lucky the first time around, and what has changed now.

Can anyone give me a clue about how sounds get directed to multiple soundcards (without JACK, that is - this is all about routing sound while JACK is not running)?



Friday, February 16th 2007, 3:15pm

Re: routing sound to multiple soundcards

The sound card numbers are assigned pretty much at random on init, this is unfortunately due to the way init works these days. The good news is, with ALSA you can reference sound cards by name rather than number.

First, run

cat /proc/asound/cards

you will get something like

0 [AudioPCI ]: ENS1371 - Ensoniq AudioPCI
Ensoniq AudioPCI ENS1371 at 0xd400, irq 225
1 [U0x46d0x8d9 ]: USB-Audio - USB Device 0x46d:0x8d9
USB Device 0x46d:0x8d9 at usb-0000:00:10.0-1, full speed
2 [V8237 ]: VIA8237 - VIA 8237
VIA 8237 with AD1888 at 0xe000, irq 217

the names in square brackets is what you need. Say you want V8237 to be your default card, for notification sounds and all other junk. Then you can put this into /etc/asound.conf or ~/.asoundrc:

type hw
card V8237
type hw
card V8237

This is the simplest case, without dmixing or anything. See

Then you would configure the programs that you want to send sound to the other card, say the AudioPCI. For example in KPlayer you would go to the Audio section in the Configure KPlayer dialog, and put hw:AudioPCI into the Device field after making sure ALSA is selected as the audio output.


Saturday, February 17th 2007, 2:59am

Thanks! That was a big help.

I decided to create the ~/.asoundrc file (there wasn't one previously) and to set the pcm and ctl defaults to my "basic" card, following your suggestion. I didn't want to change the /etc/asound.conf file, since it has a warning at the top not to edit it by hand, since it's generated by Fedora's system-config-soundcard utility.

Now my sounds all come out of the PC speakers connected to the basic card, as I'd wanted, but the sound from the applications that used to go to the better card and monitors is now also going to the basic card.

Do you have any idea why some applications' sound output was previously going to the non-default card?


Monday, February 19th 2007, 2:48pm

I really don't know about other programs, since I use KPlayer for all my media playing needs. In any case each program should allow you to configure your sound output, we are talking about KDE after all...


Tuesday, February 20th 2007, 3:20am


Originally posted by ipspeB
I really don't know about other programs, since I use KPlayer for all my media playing needs. In any case each program should allow you to configure your sound output, we are talking about KDE after all...

Well, I guess that's what I'm asking ... how do you configure output? Should it be in the application's configure menu somewhere? I haven't found anything like that.


Tuesday, February 20th 2007, 2:28pm

Yes, it should be on the Settings menu normally. What program are you trying to configure? In KPlayer it's Settings - Configure KPlayer - Audio section - Driver and Device settings.