LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 03-04-2004, 04:17 PM   #1
hand of fate
Member
 
Registered: Nov 2003
Distribution: Mandriva
Posts: 441

Rep: Reputation: 31
Real Player and XMMS "Cannot open audio device" - SuSE 9 pro


I regularly use Real Player 8 under SuSE 9 pro, but every time I boot up my computer and start Real Player, I get a message saying "Connot open audio device", with buttons for "OK" and "More Info" If I select "More Info", the message box disappears, but no sign of nay more information appears, I just can't get any sound. I also have similar problems using XMMS.

If I delete and then reinstall my sound card usind YaST, everything works ok until I reboot or log in again, when the prolem occurs again. As the problem does not occur when I log in as root, I'm guessing it could be a file permission problem.

Any help would be appreciated. As I'm no erxpert, please try to use language I'm likely to understand.

Last edited by hand of fate; 03-04-2004 at 04:22 PM.
 
Old 03-05-2004, 09:09 AM   #2
Rounan
Member
 
Registered: Jun 2003
Location: Ontario
Distribution: Ubuntu, Gentoo, Debian
Posts: 416

Rep: Reputation: 30
Does it say "permission denied" after "cannot open audio device"?
If so, it's a permissions issue.
Make sure you have yourself in the audio group, and that the following devices are owned by audio, and have group r/w permissions, with:
chmod g+rw <file>

/dev/dsp
/dev/mixer
/dev/midi
/dev/sequencer
/dev/snd
/dev/snd/*

Make sure you have execute (open) permissions for /dev/snd, too: chmod /dev/snd g+rwx

--Rounan
 
Old 03-05-2004, 12:37 PM   #3
hand of fate
Member
 
Registered: Nov 2003
Distribution: Mandriva
Posts: 441

Original Poster
Rep: Reputation: 31
I've changed all the files you listedc to full permission (ie. read, write, exec) for all users, but the problem still occurs.


When I get the error message, it say that "another application may be using it". As the problem doews not happen fror the root login, it looks like something to do with permission, but doesn't appear to be corrected after changing any of the files you listed.
 
Old 03-05-2004, 12:46 PM   #4
Rounan
Member
 
Registered: Jun 2003
Location: Ontario
Distribution: Ubuntu, Gentoo, Debian
Posts: 416

Rep: Reputation: 30
If you're using KDE, it may be that you're running arts (KDE's sound server), and this has control of your sound card.
Check your KDE setup: control center-> sound and multimedia.

If the "run arts at startup" box is checked, uncheck it, hit "apply", and try XMMS again. (you may need to killall arts or restart KDE for this to take effect)

If that works, but you still want KDE to produce sound (or want more than one program using sound at once), then you need to leave arts enabled, but have Realplayer/XMMS output to arts, not to OSS. THere should be plugins available for both.

--Rounan
 
Old 03-06-2004, 06:25 AM   #5
hand of fate
Member
 
Registered: Nov 2003
Distribution: Mandriva
Posts: 441

Original Poster
Rep: Reputation: 31
Thanks. I will look at how to output to ARTS later. I've disabled it for now.

Last edited by hand of fate; 03-06-2004 at 08:49 PM.
 
Old 05-11-2004, 01:31 PM   #6
wmeler
Member
 
Registered: Dec 2003
Distribution: Linux Mint 21 (Cinnamon)
Posts: 234

Rep: Reputation: 20
Same problem as you

Did you ever figure out a solution to the problem? I have the same exact thing and it is driving me bonkers. Every time I come into KDE it gives that same message you referred to.

Thanks in advance for any help!
 
Old 05-11-2004, 03:08 PM   #7
Rounan
Member
 
Registered: Jun 2003
Location: Ontario
Distribution: Ubuntu, Gentoo, Debian
Posts: 416

Rep: Reputation: 30
Don't really know what to say... there are tons of threads about this and similar issues.

To get sound, you need:
The right sound module loaded into the kernel (do a 'lsmod' to see loaded modules)
A program outputting sound to the proper device - usually /dev/dsp- and using the proper method - usually ALSA or OSS.
In KDE, you can configure ARTS to output to your soundcard, and have other programs output to arts - this way, you get sound from different programs at once.

so... check your arts setup under Kmenu->settings->control center->sound & multimedia->sound system. Then check the outputs of your programs to make sure they're sending to arts.

If you hit snags, post back here with DETAILED error messages. I'm still unsure what the exact error message in the above problem was, and so am unsure if it's a permissions issue, a driver issue, or a sound system issue.
 
Old 05-12-2004, 11:21 AM   #8
wmeler
Member
 
Registered: Dec 2003
Distribution: Linux Mint 21 (Cinnamon)
Posts: 234

Rep: Reputation: 20
1) I have sound. In fact, sound and mp3s work really well in xmms. I have installed ALSA and thought I even have OSS emulation in it.
2) I should say WORKS WELL UNTIL another program competes for audio at the same time. For example, if I open mozilla with xmms pumping out MP3s, xmms will work for a while. However, if I go to a site with sound...BOOM...xmms dies.
3) I looked at the preferences in xmms and it says it is using the OSS driver. I do not know how to do something different. There are other options, but nothing like arts or artsd or artsdsp.

The DETAILED error message is the following popup box:
Cannot open the audio device. Another application may be using it."

4)Thanks for you continued help in advance!
 
Old 05-12-2004, 08:02 PM   #9
Rounan
Member
 
Registered: Jun 2003
Location: Ontario
Distribution: Ubuntu, Gentoo, Debian
Posts: 416

Rep: Reputation: 30
This isn't a bug. this is normal. XMMS has control of your soundcard, and nothing else can use it until it's free.
This is why you need to run artsd, and have xmms output to arts - get the xmms-arts plugin.

What is abnormal is that xmms dies - generally, you just don't get sound from other apps, but the one locking the card should continue unaffected.

Search these forums for instructions on setting up arts. There are many threads about it.
 
Old 05-13-2004, 10:24 PM   #10
wmeler
Member
 
Registered: Dec 2003
Distribution: Linux Mint 21 (Cinnamon)
Posts: 234

Rep: Reputation: 20
Rounan, thanks. I took your advice. I believe this is deeply related to a configuration problem with qt. When I use xmms with the arts plugin, the qt problem rears it's ugly head.

Here is my description of the qt problem (which is causing problems with several programs):

http://www.linuxquestions.org/questi...hreadid=181275

Thanks in advance for any help. Tell me if I'm off here about the xmms problem and you think they are unrelated.
 
Old 05-26-2004, 06:12 AM   #11
cellist
Member
 
Registered: Oct 2003
Location: Cincinnati, OH
Distribution: Ubuntu 12.04
Posts: 145

Rep: Reputation: 16
So.... how do we tell RealPlayer to output to ARts? There doesn't appear to be an option for this in the Preferences. There's Linux Native, OSS, and ESound. Is there a Realplayer plugin that gets downloaded for this too?

I have exactly the same problem with exatly the same error message. Thanks for the tip about outputting to Arts by the way, that was really useful with xmms.

Thanks in advance!

Last edited by cellist; 05-26-2004 at 06:13 AM.
 
Old 05-31-2004, 01:58 AM   #12
wmeler
Member
 
Registered: Dec 2003
Distribution: Linux Mint 21 (Cinnamon)
Posts: 234

Rep: Reputation: 20
Sorry...never did figure this one out. I re-installed my ALSA installation and everything is cool again. I had to play around in KDE Control Center with the Audio settings as well.

If anyone figures this out, please post! The world wants to know! (Or at least I do!)
 
Old 06-11-2004, 12:04 AM   #13
MorningStar
LQ Newbie
 
Registered: Aug 2003
Location: Columbus, OH
Distribution: Mandrake 9.1
Posts: 4

Rep: Reputation: 0
I'm having a similar problem, using GNOME though.

Running XMMS, it plays find, but when it tries to switch tracks (I'm assuming letting control of the sound for a sec), I get an error like "Cannot Open Audio" or something similar, then here a bunch of 'delayed sounds' (e.g. IMs, email notice, etc.). Is there any way to get this to share the card or something? I don' t know much about how linux sound works, but opened "Volume Control" and see tabs for both OSS and ALSA, both seem to be active (guessing this isn't good).

Anyways - using onboard sound (SiS chipset)
Fedora Core 2
GNOME


Thanks,

Jeff
 
Old 06-11-2004, 02:15 AM   #14
Rounan
Member
 
Registered: Jun 2003
Location: Ontario
Distribution: Ubuntu, Gentoo, Debian
Posts: 416

Rep: Reputation: 30
What's happening is you're using XMMS to play to your soundcard (using either ALSA or OSS - ALSA has an emulation layer for OSS, so if you have ALSA installed, that's what would be used).

Gnome, I believe, uses the ESD sound daemon - this program also wants to control the soundcard. It probably has a timeout, after which it relinquishes control again.
So, what happens is:
XMMS has control, and plays music happily. During this time, ESD tries to generate sound events, but the card is locked by XMMS - so it waits.
XMMS tries to change tracks, and momentarily frees the card
ESD jumps in, plays its queued sounds, and then waits for the timeout before giving up the card again
Meanwhile, XMMS tries to play the next track, finds the card locked, and instead of waiting it gives the "cannot open audio" error.

What you need to do:
make XMMS output to ESD. This way, esd controls all audio, and only one program needs to own the card at a time.

How? It should be an output option. If not, there should be a plugin - there's an xmms-arts plugin for KDE, but I can't find an equivalent for ESD (in gentoo's tree, anyway).

Search the forums. There's definitely an answer here. probably several. I know I've posted information similar to this at least 5 times.

--Rounan
 
Old 06-11-2004, 04:19 AM   #15
thatcher
LQ Newbie
 
Registered: Jun 2004
Location: Sweden
Distribution: Debian GNU/Linux 3.0r2 Woody
Posts: 4

Rep: Reputation: 0
I've got a Debian system with a 2.4 kernel and i'm using Gnome.

And in my Xmms options I can choose between the following outputs:
ALSA
OSS
eSound
 
  


Reply



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
Mplayer sound error: "Could not open/initialize audio device -> no sound" GTBlackwell Linux - Software 9 06-11-2008 02:23 PM
XMMS: "Cannot open audio" bikecoop Linux - Software 10 09-01-2005 12:14 AM
Looking for an audio player with "Internet Radio" list michaely Linux - Software 2 09-09-2004 06:14 PM
"Unable to open USB device "usb://hp/LaserJet%201000": No such device" lordshipmayhem Mandriva 2 08-08-2004 04:56 PM
CD Player. Sound only works with Kaffeine, XMMS is "silent" :( m15a4 Linux - General 1 07-10-2004 01:32 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 07:16 PM.

Main Menu
Advertisement
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
Twitter: @linuxquestions
Open Source Consulting | Domain Registration