Subsonic (Remote) can't connect with Sonos

Need help? Post your questions here.

Moderator: moderators

Subsonic (Remote) can't connect with Sonos

Postby micsnare » Fri Jul 14, 2017 7:10 am

Hello everyone,

I recently purchased a Sonos Play 3 and wanted to connect it to my subsonic server. I've read the tutorial on the subsonic page and thought it was pretty straight forward.
However, my subsonic server is not in the same network, it's a remote one hosted by a friend therefore only reachable over a public IP address. I followed the exact same steps in the subsonic guide for remote subsonic servers.
I'm able to authenticate to my subsonic server on my Sonos, and I'm also able to browse the music libraries....however, I cannot play any song. The moment I hit "play" it automatically jumps to the next song without any playback and at the end it returns "Unable to connect to Subsonic".

I'm using Subsonic version 6.1.1

and this is the output of my debug log when I sent a request to my subsonic server...
https://pastebin.com/Z9jZrmtz

and also here's my apache config
https://pastebin.com/uNUSUvnH

any idea why I am getting the error message "unable to connect to sub" when I browse the music library? i can see all albums and songs, but I am unable to play any of these songs...

I'd appreciate any help!!

many thanks in advance,
cheers
micsnare
micsnare
 
Posts: 3
Joined: Fri Jul 14, 2017 7:02 am

Re: Subsonic (Remote) can't connect with Sonos

Postby micsnare » Sat Jul 15, 2017 12:11 pm

Hi,

any idea on how to troubleshoot this problem? I'm quite desperate.... I'm sure it's just a small issue since I seem to be able to browse the music library and actually also authenticate to the subsonic server....

I'd appreciate any help on this!

best,
micsnare
micsnare
 
Posts: 3
Joined: Fri Jul 14, 2017 7:02 am

Re: Subsonic (Remote) can't connect with Sonos

Postby micsnare » Sun Jul 16, 2017 7:21 pm

Hi,

This setup works for Sonos->Remote Subsonic in a reverse proxy
situation. The proxy and Subsonic must be listening on the same
port, otherwise this kind of setup won't work (see bugs below).
At the moment SSL is not supported, as Subsonic does not honor
X-Forwarded-* headers. someone even contributed a patch, but
it seems it never got implemented.
A possible workaround would be to use the .war version of
subsonic and run it in a tomcat application server, which
should respond correctly to proxied requests.

Bug/Patch on SF:
- https://sourceforge.net/p/subsonic/bugs/179/
- https://sourceforge.net/p/subsonic/patches/23/

subsonic .war:
- https://sourceforge.net/projects/subson ... nic/6.1.1/

possible tomcat workaround
- https://github.com/Libresonic/libresonic/issues/119

haproxy config
Code: Select all
listen subsonic
  bind    1.2.3.4:4040     # server public ip
  log     global
  mode    tcp
  option  tcpka
  timeout server  1h
  timeout client  1h
  timeout connect 5s
  stick   on src
  stick-table type ip size 200k expire 24h
  server  sublocal 127.0.0.1:4040  check inter 10s


!! Warning !!
This is a setup without transport layer encryption (TLS/SSL).
You will be sending unencrypted data over the internet.

Code: Select all
                                                   +----------------------------------------+
                                                   |     SERVER                              |
+-------+        +-------------+   +----------+    |  +----------------+   +---------------+ |
| sonos |------->| home router |-->| internet |--> |  |  haproxy:4040  |-->| subsonic:4040 | |
+-------+        +-------------+   +----------+    |  | proxy mode tcp |   +---------------+ |
    |                                              |  +----------------+                     |
+------------+                                     +-----------------------------------------+
| controller |
+------------+


cheers,
micsnare
micsnare
 
Posts: 3
Joined: Fri Jul 14, 2017 7:02 am


Return to Help

Who is online

Users browsing this forum: No registered users and 20 guests