PDA

View Full Version : SoftSqueeze headless with squeezecenter problems



rjg_scotland
2009-05-05, 09:59
I've had a search but can't find any topic referencing this particular problem.

I have a linux server which is being used as a jukebox machine. It's running the latest SqueezeCenter and is playing out of the local soundcard via squeezeslave at the moment.

All control is via SqueezeCenter web interface.

As I'm sure you all know squeezeslave has a massive flaw in that it can only handle 44kHz sample rate. While most of the music should be at 44kHz, there's some stuff kicking about which is either higher or lower, resulting in slower or faster playback than normal.

I decided a solution would be SoftSqueeze in headless mode (java -Dslimserver=127.0.0.1 -Dskins=headless -jar SoftSqueeze.jar). It'll handle different sample rates fine. I have a problem with it though, it'll work initially and start playing a song but after that SqueezeCenter loses all control of it and you cannot change the volume, skip or even stop songs. Terminating the SoftSqueeze process is the only way.

I cannot for the life of me get it to work properly! Does anyone have any idea what could be the cause of the problem? Is there any additional configuration steps I should be taking for SoftSqueeze or SqueezeCenter?

Maybe there's something better out there for headless local playback I don't know about...

Any help is much appreciated!

Thanks :)

nowork
2009-05-05, 13:56
Hi,

I have the same problem. I can't listen to NPR radio with squeezeslave, because it sounds like "chipmunks." I tried softsqueeze and could play NPR but was tied to the local monitor/gui.

Maybe as more of these cheap/energy efficient boxes get linux/squeezecenter installations by endusers, we can get enough interest to have squeezeslave be updated to work with more bitrates?

rjg_scotland
2009-05-05, 14:44
Further research (http://forums.slimdevices.com/archive/index.php/t-37460.html) suggests that all the effort is going to go into SqueezePlay now and that a headless mode might be implemented at some point in the future. I've no idea when or if it'll happen though.

An update for squeezeslave in the mean time to allow different sample rates would be awesome. If I had the coding skills I'd tackle it myself, but I don't unfortunately. I don't know the reason why squeezeslave is locked at 44kHz but I'm under the impression (and I may be wrong) there's no real technical reason, it's just nothing has ever been done about it.

bpa
2009-05-05, 17:24
More system details - what version of SC and SS ?

If you are using 7.3.x - then use SS 3.9b1 - see http://forums.slimdevices.com/showthread.php?t=62060


Re: "Chipmunks"
What formats are you playing ?
What version of SC and what OS ?

If it is not a native format either MP3 or Flac then you should examine the transcoding rules and also try 7.3.3.

rjg_scotland
2009-05-06, 01:55
SqueezeCenter: 7.3.2 - 24695
SqueezeSlave: 0.8-33
SoftSqueeze: 3.8

OS: Ubuntu 8.04 server

"Chipmunks" happens with any format (at a sample rate under 44kHz), including MP3. There's a number of sources (including the thread I referenced earlier) saying that SqueezeSlave is locked at 44kHz. If you know different do let me know! It's a shame because otherwise it's absolutely rock solid.

In the mean time I'll experiment with SoftSqueeze 3.9b1 and SqueezeCenter 7.3.3.

Thanks for your help!

Update:
I've upgraded both SqueezeCenter and SoftSqueeze and I can confirm that the problem still exists with both "chipmunks" SqueezeSlave and uncontrollable SoftSqueeze headless.

bpa
2009-05-06, 03:53
I know about "chipmunks" - 7.3.3. has some fixes to cure problem where the transcoded streams WAV didn't have a header and so encoding app such as Flac or MP3 used 44.1 by default.

nowork
2009-05-06, 04:24
Hi,

Fedora 10
Squeezecenter Version: 7.3.3 - 26407 @ Tue May 5 03:07:03 PDT 2009
squeezeslave-0.8.33-2.i386
MSI Atom 330 Motherboard, Realtek ALC858 audio(40Watts total power)

Squeezeslave plays ripped CDs and high bitrate internet radio like IO Radio at 128KBPS, OK.

SqueezeSlave, Chipmunks with National Public Radio (NPR) on WBUR 24kbps CBR or 32kbps CBR. The words are intelligible, but the pitch is chipmunk.

SoftSqueeze plays NPR fine on the same machine. However I don't know how to make SoftSqueeze "run as a service."

I want to run this box headless and control the onboard audio via SqueezeCenter/the Web. Except for chipmunks, squeezeslave seems great.

Thanks

bpa
2009-05-06, 04:32
uncontrollable SoftSqueeze headless.


I have done some basic testing headless of Softsqueeze 3.9b1 on Ubuntu 8.10 and no problems with MP3 or WMA both streams and files.

Can you be very explicit about your system config and also provide a reproducible exact sequence which shows up a specific symptom.

Softsqueeze is now community supported so if you don't provide good info on problems, they will never get fixed.

rjg_scotland
2009-05-06, 05:31
I have done some basic testing headless of Softsqueeze 3.9b1 on Ubuntu 8.10 and no problems with MP3 or WMA both streams and files.

Can you be very explicit about your system config and also provide a reproducible exact sequence which shows up a specific symptom.

Softsqueeze is now community supported so if you don't provide good info on problems, they will never get fixed.


jukebox@jukebox:~$ java -showversion
java version "1.6.0_07"
Java(TM) SE Runtime Environment (build 1.6.0_07-b06)
Java HotSpot(TM) Client VM (build 10.0-b23, mixed mode, sharing)

Soundcard: SiS SI7012

SC installed via squeezecenter_7.3.3~26407_all.deb


SqueezeCenter Status
Version: 7.3.3 - 26407 @ Tue May 5 03:18:00 PDT 2009
Hostname: jukebox
Server IP Address: 192.168.1.102
Server HTTP Port Number: 9000
Operating system: Debian - EN - utf8
Platform Architecture: i686-linux
Perl Version: 5.8.8 - i486-linux-gnu-thread-multi
MySQL Version: 5.0.51a-3ubuntu5.4
Total Players Recognized: 1

squeezeslave-0.8-33-lnx26-alsa-display-i686.tar.gz extracted and run

SoftSqueeze extracted from SoftSqueeze39b1.zip and run via java -Dslimserver=127.0.0.1 -Dskins=headless -jar SoftSqueeze.jar

Please tell me what info you want me to provide and I'll happily provide it (any config file contents, etc). Perhaps something in convert.conf needs to be added/changed (with regards to squeezeslave "chipmunks" anyway)..?

Thanks

bpa
2009-05-06, 06:38
I'll only try to reproduce with Softsqueeze headless issue.

What type of processor ? Does it have HyperThreading or multiple cores ?

Assuming SC is running and Softsqueeze has just been started.
Also make sure SC and Softsqueeze are running on the same system.

Please describe a sequence of mouse clicks on WebUI that causes a reproducible problem. Please describe the problem. If it involves playing a file or stream - please give details of the file format or stream url.

rjg_scotland
2009-05-06, 07:36
SqueezeCenter is running and SoftSqueeze is started.

SoftSqueeze is selected from the player dropdown.

Some music is browsed/searched for in the left pane.

A song is set to play.

At this point it does start playing and shows the progress/time, etc. It's after this it all goes wrong...

If I put the volume up one notch or change track, it works once. After that the web UI has no effect at all on SoftSqueeze. You can click the volume, progress bar, next/prev track, pause, or whatever, and nothing happens. The only way I can shut the player up is to terminate the process. This happens consistently. I've tried restarting SC also with no effect.

Hope that helps.

bpa
2009-05-06, 07:53
What is the format (MP3/WMA/ALAC/OGG ?) and source (file/stream) of music played.

What type of processor ? Doe it have HT or mulitple cores ?

rjg_scotland
2009-05-06, 08:17
Single core P4 with HT (according to cpuinfo):


jukebox@jukebox:~/softsqueeze$ cat /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 15
model : 2
model name : Intel(R) Pentium(R) 4 CPU 2.40GHz
stepping : 4
cpu MHz : 2400.236
cache size : 512 KB
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 2
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm up pebs bts sync_rdtsc
bogomips : 4803.75
clflush size : 64

The format doesn't matter (same result with any) and it's all from local files. I should also point out that the display stops updating with the time/progress bar when it stops responding to user input.

bpa
2009-05-06, 08:28
I assume when Softsqueeze is running, it is running in a shell with its own window. I want you to get a thread dump of Softsqueeze when it is stuck.

From another shell prompt window - find out the process number (pid) of the Softsqueeze process and issue the following command
kill -QUIT <pid>

where <pid> is the process number.

This will cause the JVM to do a thread dump. Copy the dump to a file and attach to a post.

rjg_scotland
2009-05-06, 08:44
Attached is the thread dump. The process continued to play the track while stuck for a minute or so before spitting the following out to the console:


0 [SlimTCP-1] WARN softsqueeze - Lost contact with Slim Server

Thanks a lot for your help.

bpa
2009-05-06, 09:20
IT's posible the Softsqueeze is locked waiting on the Sun JavaSound output.

How is your audio configured on your system - ALSA, Pulse, OSS ?

Is there any other app that could do audio at the same time (e.g. Browser open running a Java applet). ?

bpa
2009-05-07, 00:41
Can you run Softsqueeze without the "-Dskins=headless" and then ignore the display and use as if headless (i.e. do not do anything at all with Softsqueeze UI) to see if problems happen. Make sure after Softsqueeze starts you select a different window and do no SoftSqueeze UI action whatsoever (e.g. no minimise)

This is needed to check if headless skin is the problem or whether some part of UI initialisation is the problem.

rjg_scotland
2009-05-07, 02:27
It's ALSA I'm using. I don't actually have X installed on the box I'm afraid - it's very minimal just for playing audio. Could that be causing problems with SoftSqueeze even in headless mode do you think?

bpa
2009-05-07, 02:51
Could that be causing problems with SoftSqueeze even in headless mode do you think?

It's a possibility and worth checking but it may require creating a special headless build with no GUI libraries to test.

rjg_scotland
2009-05-07, 04:45
It's a possibility and worth checking but it may require creating a special headless build with no GUI libraries to test.

Well, if you want I could install X (but not sure if/when I could get round to it today) however I'd rather avoid it. It depends how much of a bother it is for you (or I) to compile a version without the GUI libraries.

Thanks for your help so far!

nowork
2009-05-07, 05:01
Hi,

I vote for a non GUI version of SoftSqueeze, or at least being able to invoke SoftSqueeze without a GUI that runs continuously with no problems.

I too am running a minimal Fedora linux installation without X installed (booting from a 8Gig Compact Flash Card). I don't want the overhead of a GUI, and I hope this will be a set-and-forget box.

I'm happy to move from SqueezeSlave to SoftSqueeze on this box if SoftSqueeze can solve the chipmunk problem, and run non GUI as-a-service.

Thanks for your help.

bpa
2009-05-07, 07:26
I am only doing basic maintenance on Softsqueeze to keep it runnig with new version of Java and Squeezecenter. If I build a no GUI version would be only to test headless issue to isolate the problem.

However, this does not stop anybody else from doing so but as I see it squeezeslave is the no GUI player and there is no point in creating yet another player and spreading resources even thinner.

rjg_scotland
2009-05-07, 11:49
I agree squeezeslave is the no-gui player, it's just unfortunate that it has a major flaw and is not being developed any more. Well, if you could build a version, just for testing, it'd be really appreciated - but no pressure :).

Perhaps someone else might take up an interest in persuing the no-gui version further if it tests sucessful. I'd do it myself but I don't know either Java or what I'm really doing when it comes to compiling Java applications.


Thanks again.

rickwookie
2009-05-07, 16:55
I'd be really interested in seeing this issue resolved. I've had the same problems reported here for a long time and I'd never considered that it might be because I don't have X. I assumed that -Dskin=headless would switch off all GUI routines.

If this could be fixed it would be great.

bpa
2009-05-07, 17:09
I agree squeezeslave is the no-gui player, it's just unfortunate that it has a major flaw and is not being developed any more.

There has been more development recently on squeezeslave that Softsqueeze.



I'd do it myself but I don't know either Java or what I'm really doing when it comes to compiling Java applications.

Everybody starts with no knowledge of Java - I didn't about 3 months ago.