SubSonic jukebox output broken in Debian 8 (Ubuntu as well?)

Need help? Post your questions here.

Moderator: moderators

SubSonic jukebox output broken in Debian 8 (Ubuntu as well?)

Postby benito » Sat Apr 30, 2016 2:41 am

KEYWORDS: Sunsonic Linux Debian Ubuntu no jukebox sound output jukebox: javax.sound.sampled.LineUnavailableException


I installed SubSonic, following the instructions on the subsonic website.
First, install Java: sudo apt-get install openjdk-7-jre
Download the Subsonic .deb package and install it: sudo dpkg -i subsonic-x.x.deb

All went to plan, and even Android playback does work, but Jukebox output errors out and there is no sound output.

Some background:
I had Subsonic working well with jukebox output under Debian 7 (using Sun java package).
Initially I tried Subsonic version 5.3.beta2 (the same version that worked on Debian7) ; no jukebox output, so I upgraded to latest 6.0.beta2, still no output.

I have a suspicion that Java version is to blame, but cannot prove it, nor know what to try next. ( I did as I was told to install)

P.S. Sun Java is no longer available for install on Debian / Ubuntu.


Here are the technical details:

Code: Select all
<-------------------------Subsonic Help Request---------------------->
Problem Description: No jukebox sound output
Troubleshooting Steps: Test sound output with alsaplayer=OK speakertest=OK
Playback Application and version: SubSonic Jukebox output to server PC Line-out.
Subsonic Version: 6.0.beta2 (build d85b52) – March 23, 2016
Server Version: jetty-6.1.x, java 1.7.0_95, Linux (105.1 MB / 134.0 MB
Hardware Platform: Linux (8.4 jesse) 3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt25-2 (2016-04-08) x86_64 GNU/Linux
Java Memory Limit: (Windows: found in the Subsonic Agent in the taskbar)
Problem Filename: all jukebox output fails
Output from ffmpeg -i: (If you open a command prompt and type 'ffmpeg -i <filename>' what is the output? Ideally put this in a "code" block)
Last ten log file lines: INFO TranscodeInputStream - Starting transcoder: /var/subsonic/transcode/ffmpeg -ss 0 -i /home/music/i/INXS/INXS -Shabooh Shoobah - 1982/03 - Spy of Love.mp3 -map 0:0 -v 0 -ar 44100 -ac 2 -f s16be -
[2016-04-30 11:28:03,263] ERROR JukeboxService - Error in jukebox: javax.sound.sampled.LineUnavailableException
javax.sound.sampled.LineUnavailableException
        at org.classpath.icedtea.pulseaudio.PulseAudioMixer.openImpl(PulseAudioMixer.java:714)
        at org.classpath.icedtea.pulseaudio.PulseAudioMixer.openLocal(PulseAudioMixer.java:588)
        at org.classpath.icedtea.pulseaudio.PulseAudioMixer.openLocal(PulseAudioMixer.java:584)
        at org.classpath.icedtea.pulseaudio.PulseAudioMixer.open(PulseAudioMixer.java:579)
        at org.classpath.icedtea.pulseaudio.PulseAudioDataLine.open(PulseAudioDataLine.java:94)
        at org.classpath.icedtea.pulseaudio.PulseAudioSourceDataLine.open(PulseAudioSourceDataLine.java:75)

<-------------------------Subsonic Help Request---------------------->


Code: Select all
#tail /var/log/subsonic/subsonic.log
ERROR JukeboxService - Error in jukebox: javax.sound.sampled.LineUnavailableException
javax.sound.sampled.LineUnavailableException
        at org.classpath.icedtea.pulseaudio.PulseAudioMixer.openImpl(PulseAudioMixer.java:714)

#java -version
java version "1.7.0_95"
OpenJDK Runtime Environment (IcedTea 2.6.4) (7u95-2.6.4-1~deb8u1)
OpenJDK 64-Bit Server VM (build 24.95-b01, mixed mode)


Code: Select all
# /var/subsonic/transcode/ffmpeg -i /etc/startup.wav
ffmpeg version 3.0-static http://johnvansickle.com/ffmpeg/  Copyright (c) 2000-2016 the FFmpeg developers
  built with gcc 5.3.1 (Debian 5.3.1-8) 20160205
  configuration: --enable-gpl --enable-version3 --disable-shared --disable-debug --enable-runtime-cpudetect --enable-libmp3lame --enable-libx264 --enable-libx265 --enable-libwebp --enable-libspeex --enable-libvorbis --enable-libvpx --enable-libfreetype --enable-fontconfig --enable-libxvid --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libtheora --enable-libvo-amrwbenc --enable-gray --enable-libopenjpeg --enable-libopus --enable-libass --enable-gnutls --enable-libvidstab --enable-libsoxr --enable-frei0r --enable-libfribidi --disable-indev=sndio --disable-outdev=sndio --enable-librtmp --enable-libmfx --cc=gcc
  libavutil      55. 17.103 / 55. 17.103
  libavcodec     57. 24.102 / 57. 24.102
  libavformat    57. 25.100 / 57. 25.100
  libavdevice    57.  0.101 / 57.  0.101
  libavfilter     6. 31.100 /  6. 31.100
  libswscale      4.  0.100 /  4.  0.100
  libswresample   2.  0.101 /  2.  0.101
  libpostproc    54.  0.100 / 54.  0.100
Guessed Channel Layout for  Input Stream #0.0 : mono
Input #0, wav, from '/etc/startup.wav':
  Metadata:
    artist          : Brian Eno
    copyright       : 1995 Microsoft Corporation
    title           : The Microsoft Sound
    album           : Microsoft Windows 95
    ISRC            : Microsoft Corporation
                    : One Microsoft Way
                    : Redmond, WA  98052-6399
  Duration: 00:00:06.12, bitrate: 177 kb/s
    Stream #0:0: Audio: pcm_u8 ([1][0][0][0] / 0x0001), 22050 Hz, 1 channels, u8, 176 kb/s
At least one output file must be specified


Code: Select all
#dpkg -l |grep (what I think is relevant)
ii  subsonic                           6.0.beta2                         all          A web-based music streamer, jukebox and Podcast receiver
ii  openjdk-7-jre:amd64    7u95-2.6.4-1~deb amd64            OpenJDK Java runtime, using Hotspot JIT
ii  openjdk-7-jre-headless 7u95-2.6.4-1~deb amd64            OpenJDK Java runtime, using Hotspot JIT (headless)
ii  libasound2:amd64                   1.0.28-1                          amd64        shared library for ALSA applications
ii  libasound2-data                    1.0.28-1                          all          Configuration files and profiles for ALSA drivers
ii  libasound2-plugins:amd64           1.0.28-1+b1                       amd64        ALSA library additional plugins
ii  libcanberra0:amd64                 0.30-2.1                          amd64        simple abstract interface for playing event sounds
ii  libmikmod3:amd64                   3.3.7-1                           amd64        Portable sound library
ii  libtext-soundex-perl               3.4-1+b2                          amd64        implementation of the soundex algorithm
ii  pulseaudio                         5.0-13                            amd64        PulseAudio sound server
ii  pulseaudio-module-x11              5.0-13                            amd64        X11 module for PulseAudio sound server
ii  pulseaudio-utils                   5.0-13                            amd64        Command line tools for the PulseAudio sound server
ii  alsa-base                          1.0.27+1                          all          dummy package to ease purging of obsolete conffiles
ii  alsa-utils                         1.0.28-1                          amd64        Utilities for configuring and using ALSA
ii  alsaplayer-alsa                    0.99.81-1+b1                      amd64        alsaplayer output module for ALSA
ii  alsaplayer-common                  0.99.81-1+b1                      amd64        audio player (common files)
ii  alsaplayer-gtk                     0.99.81-1+b1                      amd64        alsaplayer gtk interface
ii  alsaplayer-text                    0.99.81-1+b1                      amd64        alsaplayer text interface
Last edited by benito on Sun May 01, 2016 6:49 am, edited 1 time in total.
User avatar
benito
 
Posts: 31
Joined: Sun Nov 20, 2011 12:16 am

[Solved] SubSonic jukebox output broken in Debian 8

Postby benito » Sun May 01, 2016 6:32 am

I found the solution myself, with a little experimentation.
It seems that the Java implementation was the issue.

OpenJDK cannot produce sound output under Debian (and Ubuntu as well I suspect).
(True at least of OpenJDK 2.6.4 circa May 2016)

I replaced OpenJDK with Oracle Java and sound output is good.
Oracle Java (Formerly Sun Java) is no longer a package included with Debian or Ubuntu, but there are sources for .DEB packages, so install is pretty easy.

First, remove OpenJDK, so as not to clash with Oracle Java.
Code: Select all
sudo apt-get purge openjdk-7-jre
sudo apt-get autoremove


Then install Oracle Java (v1.8.0_91-b14 at time of writing)

Code: Select all
su -
echo "deb http://ppa.launchpad.net/webupd8team/java/ubuntu xenial main" | tee /etc/apt/sources.list.d/webupd8team-java.list
echo "deb-src http://ppa.launchpad.net/webupd8team/java/ubuntu xenial main" | tee -a /etc/apt/sources.list.d/webupd8team-java.list
apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys EEA14886
apt-get update
apt-get install oracle-java8-installer


et Voila! ce finis.

Sindre, perhaps you may wish to update the instructions for Debian/Ubuntu install with a caveat for those who use Jukebox mode.

I hope this post helps other save time and frustration.

Regards,
Benitio.
User avatar
benito
 
Posts: 31
Joined: Sun Nov 20, 2011 12:16 am


Return to Help

Who is online

Users browsing this forum: No registered users and 20 guests