LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Tags used in this thread
Popular LQ Tags , ,

Reply
 
Thread Tools
Old 01-29-2008, 07:52 PM   #1
trashbird1240
Member
 
Registered: Sep 2006
Location: Durham, NC
Distribution: Slackware, Ubuntu (yes, both)
Posts: 462
Thanked: 1
Sound problems in KDE with multiple sessions


[Log in to get rid of this advertisement]
Hello Forum,
I know this is frequently asked, but sometimes it happens and sometimes it doesn't, and none of the solutions I've found apply.

A typical scenario: I get up early in the morning to do some coding, log in to KDE, turn on emms (the Emacs multimedia system), which uses mplayer and ogg123 and mpg321 to play music. I stop emms, but stay logged in and she starts a new KDE session. The sound doesn't work, Firefox locks up on Youtube videos, etc etc.

I thought this was because:
* I was using Fvwm; when I was using Fvwm we'd get the "failure to initialize sound device" error, however I switched back to KDE and we don't get the error message, but sometimes still get the sound problems
* permissions on the audio devices; I've seen this solution on a lot of other forums and for other distros: both of us are members of the audio group, and the permissions on /dev/sound are as follows:
Code:
/home/joel: Zshell> ls -l /dev/sound
total 0
crw-rw--w- 1 root audio 14, 12 2008-01-26 20:24 adsp
crw-rw--w- 1 root audio 14,  4 2008-01-26 20:24 audio
crw-rw--w- 1 root audio 14, 20 2008-01-26 20:24 audio1
crw-rw--w- 1 root audio 14,  3 2008-01-26 20:24 dsp
crw-rw--w- 1 root audio 14, 19 2008-01-26 20:24 dsp1
crw-rw--w- 1 root audio 14,  0 2008-01-26 20:24 mixer
crw-rw--w- 1 root audio 14, 16 2008-01-26 20:24 mixer1
crw-rw--w- 1 root audio 14,  1 2008-01-26 20:24 sequencer
crw-rw--w- 1 root audio 14,  8 2008-01-26 20:24 sequencer2
* somebody (me) left a music player program open, thus locking the devices: I just tried this: went over to my wife's desktop, started Amarok playing "I Love the Nightlife," then stopped playback, left Amarok open and went back to my desktop, opened a new instance of Amarok and played 10,000 Maniacs. All with sound that worked. I also played a video on Youtube, and it worked perfectly.

If this has been solved on Slackware, please point me in the right direction. For right now it seems the only safe thing to do is for us not to have multiple sessions open, which is a kind of a drag.

Thanks for any suggestions,
Joel
trashbird1240 is offline  
Tag This Post , ,
Reply With Quote
Old 01-29-2008, 10:56 PM   #2
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware 12.2
Posts: 1,306
Thanked: 28
Unfortunately I have nothing to suggest -- however I will say that sound works for me from two X sessions (running from different users) simultaneously, even if sound is playing on both (ie sound from both sessions can play at the same time). So I know it isn't necessarily a problem with Slackware itself (I'm using Slackware 12.0) and may instead be a specific problem with the apps you are using or your setup (for the record, I have only tried Amarok on one session and youtube videos etc. on the other session -- it may be an artifact of the specific apps you are running; I have no idea).
T3slider is offline     Reply With Quote
Old 01-30-2008, 01:37 AM   #3
Alien_Hominid
Senior Member
 
Registered: Oct 2005
Location: Lithuania
Distribution: Hybrid
Posts: 2,220
Thanked: 7
This might happen due to variety of reasons. Applications can use /dev/dsp directly or use software based mixer like arts or esd. When some app is accessing dsp directly they put a lock on it, so no other app could use it. That's why you can't hear music from two sources at the same time if your mixer isn't setup. What does mixer do? It takes various sources of sound and mixes (adds) them together so the produced sound wave appears to be made from different sound sources. When this mixer is holding a lock on /dev/dsp, no other mixer can use /dev/dsp. (afaik, dsp - digital sound processor). So when you start KDE, arts sound deamon (artsd) is started. Arts is KDE sound mixer. When you start sound apps, they might access /dev/dsp directly, access arts(d) or any other mixer (like esd). So you can imagine that some app might be holding a lock on /dev/dsp when arts is accessing it (no sound from kde) or vice versa. The best practise is to set all apps to use same mixer and that could be done using alsa and its asoundrc. According to their wiki you don't need to set up asoundrc these days (I still have ancient alsa), so you could try to direct output to alsa from all apps (at least xmms can do this, not sure about Amarok).
Alien_Hominid is offline     Reply With Quote

Reply

Bookmarks


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Multiple Autologins; Multiple Users; Multiple Sessions mrclisdue Linux - Desktop 1 09-26-2007 06:50 AM
KDE and multiple sessions dismas Linux - Newbie 2 10-29-2006 01:10 AM
Multiple X Sessions with KDE/Gentoo bee2643 Linux - Distributions 1 01-26-2006 07:26 PM
Sound in multiple sessions LinuxConvert-06/05 Linux - Newbie 1 07-20-2005 01:00 PM
sharing sound in multiple sessions nitrambass Mandriva 5 06-23-2004 06:19 PM


All times are GMT -5. The time now is 08:44 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
RSS2  LQ Podcast
RSS2  LQ Radio
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration