I tried the stable release 4.3 as well as the 4.4.beta1 of subsonic. Playing music in the browser works fine, but the jukebox does not work at all
More precisely, the server stays silent - no sound at all. The UI switches to "Stop" as if it was playing, but I hear nothing. And it stays like this - it neither switches to the next song of the playlist (even though a 3 minute song should be finished after 15 minutes) nor does the "Stop" switch to "Play" again.
Looking into the log file /var/subsonic/subsonic_sh.log shows this:
14411 [btpool0-5] INFO org.directwebremoting.log.startup - Starting: DwrServlet v3.0.0.116.rc1 on jetty-6.1.x / JDK 1.6.0_20 from Sun Microsystems Inc. at
23481 [btpool0-7] INFO javazoom.jlgui.basicplayer.BasicPlayer - open(java.io.BufferedInputStream@5f0772d2)
23503 [btpool0-7] INFO javazoom.jlgui.basicplayer.BasicPlayer - Create Line
23503 [btpool0-7] INFO javazoom.jlgui.basicplayer.BasicPlayer - Create Line : Source format : MPEG1L3 44100.0 Hz, unknown bits per sample, stereo, unknown frame size, 38.28125 frames/second,
23504 [btpool0-7] INFO javazoom.jlgui.basicplayer.BasicPlayer - Create Line : Target format: PCM_SIGNED 44100.0 Hz, 16 bit, stereo, 4 bytes/frame, little-endian
23533 [btpool0-7] INFO javazoom.jlgui.basicplayer.BasicPlayer - Line : com.sun.media.sound.MixerSourceLine@5460eb0c
23534 [btpool0-7] INFO javazoom.jlgui.basicplayer.BasicPlayer - startPlayback called
23534 [btpool0-7] INFO javazoom.jlgui.basicplayer.BasicPlayer - initLine()
Nothing more - no exception, no warning.
In order to find a solution, I browsed the forum for quite a while and read dozens of threads, but nothing helped. I do use Sun Java (version 1.6.0_20). I do have flac, faad et al installed (all symlinks in /var/subsonic/transcode/ point to existing executables), I do have permissions to write to the sound card (subsonic runs as root according to ps aux | grep java) and there is no exception message like in many of the threads discussing jukebox problems.
The only thread that helped a bit further is this: http://forum.subsonic.org/forum/viewtopic.php?t=2038
The command 'aplay -l' gives me this result:
root@myserver:~/install/subsonic# aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: SB [HDA ATI SB], device 0: ALC888 Analog [ALC888 Analog]
Subdevices: 0/1
Subdevice #0: subdevice #0
card 0: SB [HDA ATI SB], device 1: ALC888 Digital [ALC888 Digital]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: HDMI [HDA ATI HDMI], device 3: ATI HDMI [ATI HDMI]
Subdevices: 1/1
Subdevice #0: subdevice #0
And when I compile & run this little java class, I see this:
root@myserver:~/install/subsonic# java audioDevList
Available mixers:
SB [plughw:0,0]
SB [plughw:0,1]
SB [plughw:0,2]
HDMI [plughw:1,3]
Java Sound Audio Engine
Port SB [hw:0]
Port HDMI [hw:1]
So I tried playing around with the settings in /usr/lib64/jvm/java-6-sun/jre/lib/sound.properties and had some success after adding these lines:
javax.sound.sampled.Clip=#SB [plughw:0,1]
javax.sound.sampled.Port=#Port SB [hw:0]
javax.sound.sampled.SourceDataLine=#SB [plughw:0,1]
javax.sound.sampled.TargetDataLine=#SB [plughw:0,1]
With these settings, the log looks differently:
455940 [btpool0-2] INFO javazoom.jlgui.basicplayer.BasicPlayer - open(java.io.BufferedInputStream@10c7eb9d)
455962 [btpool0-2] INFO javazoom.jlgui.basicplayer.BasicPlayer - Create Line
455962 [btpool0-2] INFO javazoom.jlgui.basicplayer.BasicPlayer - Create Line : Source format : MPEG1L3 44100.0 Hz, unknown bits per sample, stereo, unknown frame size, 38.28125 frames/second,
455962 [btpool0-2] INFO javazoom.jlgui.basicplayer.BasicPlayer - Create Line : Target format: PCM_SIGNED 44100.0 Hz, 16 bit, stereo, 4 bytes/frame, little-endian
455966 [btpool0-2] INFO javazoom.jlgui.basicplayer.BasicPlayer - Line : com.sun.media.sound.DirectAudioDevice$DirectSDL@102e6640
455966 [btpool0-2] INFO javazoom.jlgui.basicplayer.BasicPlayer - startPlayback called
455966 [btpool0-2] INFO javazoom.jlgui.basicplayer.BasicPlayer - initLine()
456006 [btpool0-2] INFO javazoom.jlgui.basicplayer.BasicPlayer - Open Line : BufferSize=88200
456007 [btpool0-2] INFO javazoom.jlgui.basicplayer.BasicPlayer - Master Gain Control : [-80.0,6.0206] 0.625
456007 [btpool0-2] INFO javazoom.jlgui.basicplayer.BasicPlayer - Pan Control : [-1.0,1.0] 0.0078125
456007 [btpool0-2] INFO javazoom.jlgui.basicplayer.BasicPlayer - Creating new thread
456007 [BasicPlayer] INFO javazoom.jlgui.basicplayer.BasicPlayer - Thread Running
1221661 [BasicPlayer] INFO javazoom.jlgui.basicplayer.BasicPlayer - Stream closed
1221662 [BasicPlayer] INFO javazoom.jlgui.basicplayer.BasicPlayer - Thread completed
If I play a song, after a few minutes (when the song finished) the next song is picked from the playlist. Unfortunately though, everything is still silent. I assume that is, because the device "SB [plughw:0,1]" is my digital output - however I do not have digital sound equipment and my sound system is connected via the analogue connector.
Note, that I do not have two sound cards! That's just one ordinary on-board device which seems to offer both analogue and digital output.
Well, I give up for now - please let me know if there is anything else I can try! For example: Can I use an external player app (e.g. mpg123 & ogg123) instead of the internal java player? Or can I change the configuration to use another java player class? Or is it possible to change the behaviour of the player - e.g. to suppress sth. that makes it hang up (e.g. querying the gain)?
Btw. note, that I can play sound just fine with other applications - including java apps (!) - on this server. Only subsonic fails to use the sound card
Best regards, Marco
