My belenas forget that they know each other.

I have two identical RPi4 with the latest belanaOS and Belena sound installed. At first deployment, they work flawlessly with Spotify connect. Both play the music, very nice. One might say they are connected.

However, if they are off for a while, they forget each other. There is no connection, no love between them. I re-imaged them and once again they were tied together, inseparable. However again once they were without Spotify sending them a loving stream, they forgot each other.

I have tried adjusting variables, MULTI_ROOM_CLIENT, MULTI_ROOM, STANDALONE and that does not seem to help.

They both have modified BLUETOOTH_DEVICE_NAME and SOUND_DEVICE_NAME variables.

Any ideas why my Belanas won’t stay mated?

I am getting a lot of this:

02.06.21 21:21:13 (+0000) audio
02.06.21 21:21:13 (+0000) audio — Audio —
02.06.21 21:21:13 (+0000) audio Starting audio service with settings:
02.06.21 21:21:13 (+0000) audio - pulseaudio 13.0
02.06.21 21:21:13 (+0000) audio - Pulse log level: NOTICE
02.06.21 21:21:13 (+0000) audio - Default output: AUTO
02.06.21 21:21:13 (+0000) audio
02.06.21 21:21:13 (+0000) audio Detected audio cards:
02.06.21 21:21:13 (+0000) audio 0 bcm2835-jack bcm2835_headphonbcm2835Headphones-bcm2835Headphones
02.06.21 21:21:13 (+0000) audio
02.06.21 21:21:13 (+0000) audio
02.06.21 21:21:13 (+0000) bluetooth - Bluetooth profile not available or not initialized. Retrying (attempt 2/5)…
02.06.21 21:21:13 (+0000) audio
02.06.21 21:21:13 (+0000) audio — Audio —
02.06.21 21:21:13 (+0000) audio Starting audio service with settings:
02.06.21 21:21:13 (+0000) audio - pulseaudio 13.0
02.06.21 21:21:13 (+0000) audio - Pulse log level: NOTICE
02.06.21 21:21:13 (+0000) audio - Default output: AUTO
02.06.21 21:21:13 (+0000) audio
02.06.21 21:21:13 (+0000) audio Detected audio cards:
02.06.21 21:21:13 (+0000) audio 0 bcm2835-jack bcm2835_headphonbcm2835Headphones-bcm2835Headphones
02.06.21 21:21:13 (+0000) audio
02.06.21 21:21:13 (+0000) audio
02.06.21 21:21:14 (+0000) multiroom-client 2021-06-02 21-21-14.433 [Error] (Connection) Failed to connect to host ‘10.0.0.238’, error: Connection refused
02.06.21 21:21:14 (+0000) multiroom-client 2021-06-02 21-21-14.434 [Error] (Controller) Error: Connection refused
02.06.21 21:21:14 (+0000) multiroom-client 2021-06-02 21-21-14.434 [Error] (Connection) Error in socket shutdown: Transport endpoint is not connected
02.06.21 21:21:15 (+0000) multiroom-client 2021-06-02 21-21-15.434 [Error] (Connection) Failed to connect to host ‘10.0.0.238’, error: Connection refused
02.06.21 21:21:15 (+0000) multiroom-client 2021-06-02 21-21-15.434 [Error] (Controller) Error: Connection refused
02.06.21 21:21:15 (+0000) multiroom-client 2021-06-02 21-21-15.434 [Error] (Connection) Error in socket shutdown: Transport endpoint is not connected
02.06.21 21:21:16 (+0000) multiroom-client 2021-06-02 21-21-16.435 [Error] (Connection) Failed to connect to host ‘10.0.0.238’, error: Connection refused
02.06.21 21:21:16 (+0000) multiroom-client 2021-06-02 21-21-16.435 [Error] (Controller) Error: Connection refused
02.06.21 21:21:16 (+0000) multiroom-client 2021-06-02 21-21-16.435 [Error] (Connection) Error in socket shutdown: Transport endpoint is not connected
02.06.21 21:21:17 (+0000) multiroom-client 2021-06-02 21-21-17.436 [Error] (Connection) Failed to connect to host ‘10.0.0.238’, error: Connection refused
02.06.21 21:21:17 (+0000) multiroom-client 2021-06-02 21-21-17.436 [Error] (Controller) Error: Connection refused
02.06.21 21:21:17 (+0000) multiroom-client 2021-06-02 21-21-17.436 [Error] (Connection) Error in socket shutdown: Transport endpoint is not connected
02.06.21 21:21:18 (+0000) multiroom-client 2021-06-02 21-21-18.437 [Error] (Connection) Failed to connect to host ‘10.0.0.238’, error: Connection refused
02.06.21 21:21:18 (+0000) multiroom-client 2021-06-02 21-21-18.437 [Error] (Controller) Error: Connection refused
02.06.21 21:21:18 (+0000) multiroom-client 2021-06-02 21-21-18.437 [Error] (Connection) Error in socket shutdown: Transport endpoint is not connected
02.06.21 21:21:18 (+0000) bluetooth - Bluetooth profile not available or not initialized. Retrying (attempt 3/5)…
02.06.21 21:21:19 (+0000) multiroom-client 2021-06-02 21-21-19.437 [Error] (Connection) Failed to connect to host ‘10.0.0.238’, error: Connection refused
02.06.21 21:21:19 (+0000) multiroom-client 2021-06-02 21-21-19.437 [Error] (Controller) Error: Connection refused
02.06.21 21:21:19 (+0000) multiroom-client 2021-06-02 21-21-19.437 [Error] (Connection) Error in socket shutdown: Transport endpoint is not connected
02.06.21 21:21:20 (+0000) airplay Waiting for audioblock to start…
02.06.21 21:21:20 (+0000) multiroom-client 2021-06-02 21-21-20.438 [Error] (Connection) Failed to connect to host ‘10.0.0.238’, error: Connection refused
02.06.21 21:21:20 (+0000) multiroom-client 2021-06-02 21-21-20.438 [Error] (Controller) Error: Connection refused
02.06.21 21:21:20 (+0000) multiroom-client 2021-06-02 21-21-20.438 [Error] (Connection) Error in socket shutdown: Transport endpoint is not connected
02.06.21 21:21:21 (+0000) multiroom-client 2021-06-02 21-21-21.439 [Error] (Connection) Failed to connect to host ‘10.0.0.238’, error: Connection refused
02.06.21 21:21:21 (+0000) multiroom-client 2021-06-02 21-21-21.439 [Error] (Controller) Error: Connection refused
02.06.21 21:21:21 (+0000) multiroom-client 2021-06-02 21-21-21.439 [Error] (Connection) Error in socket shutdown: Transport endpoint is not connected
02.06.21 21:21:22 (+0000) multiroom-client 2021-06-02 21-21-22.439 [Error] (Connection) Failed to connect to host ‘10.0.0.238’, error: Connection refused
02.06.21 21:21:22 (+0000) multiroom-client 2021-06-02 21-21-22.440 [Error] (Controller) Error: Connection refused
02.06.21 21:21:22 (+0000) multiroom-client 2021-06-02 21-21-22.440 [Error] (Connection) Error in socket shutdown: Transport endpoint is not connected
02.06.21 21:21:23 (+0000) multiroom-client 2021-06-02 21-21-23.440 [Error] (Connection) Failed to connect to host ‘10.0.0.238’, error: Connection refused
02.06.21 21:21:23 (+0000) multiroom-client 2021-06-02 21-21-23.440 [Error] (Controller) Error: Connection refused
02.06.21 21:21:23 (+0000) multiroom-client 2021-06-02 21-21-23.440 [Error] (Connection) Error in socket shutdown: Transport endpoint is not connected
02.06.21 21:21:23 (+0000) bluetooth - Bluetooth profile not available or not initialized. Retrying (attempt 4/5)…
02.06.21 21:21:23 (+0000) audio Setting audio routing rules…
02.06.21 21:21:23 (+0000) audio Routing ‘balena-sound.input’ to ‘balena-sound.output’.
02.06.21 21:21:23 (+0000) audio Routing ‘balena-sound.output’ to ‘alsa_output.bcm2835-jack.stereo-fallback’.
02.06.21 21:21:23 (+0000) audio W: [pulseaudio] main.c: This program is not intended to be run as root (unless --system is specified).
02.06.21 21:21:23 (+0000) audio W: [pulseaudio] server-lookup.c: Unable to contact D-Bus: org.freedesktop.DBus.Error.NotSupported: Unable to autolaunch a dbus-daemon without a $DISPLAY for X11
02.06.21 21:21:23 (+0000) audio W: [pulseaudio] main.c: Unable to contact D-Bus: org.freedesktop.DBus.Error.NotSupported: Unable to autolaunch a dbus-daemon without a $DISPLAY for X11
02.06.21 21:21:24 (+0000) multiroom-client 2021-06-02 21-21-24.441 [Error] (Connection) Failed to connect to host ‘10.0.0.238’, error: Connection refused
02.06.21 21:21:24 (+0000) multiroom-client 2021-06-02 21-21-24.441 [Error] (Controller) Error: Connection refused
02.06.21 21:21:24 (+0000) multiroom-client 2021-06-02 21-21-24.441 [Error] (Connection) Error in socket shutdown: Transport endpoint is not connected
02.06.21 21:21:25 (+0000) multiroom-client 2021-06-02 21-21-25.442 [Error] (Connection) Failed to connect to host ‘10.0.0.238’, error: Connection refused
02.06.21 21:21:25 (+0000) multiroom-client 2021-06-02 21-21-25.442 [Error] (Controller) Error: Connection refused
02.06.21 21:21:25 (+0000) multiroom-client 2021-06-02 21-21-25.442 [Error] (Connection) Error in socket shutdown: Transport endpoint is not connected
02.06.21 21:21:26 (+0000) multiroom-client 2021-06-02 21-21-26.443 [Error] (Connection) Failed to connect to host ‘10.0.0.238’, error: Connection refused
02.06.21 21:21:26 (+0000) multiroom-client 2021-06-02 21-21-26.443 [Error] (Controller) Error: Connection refused
02.06.21 21:21:26 (+0000) multiroom-client 2021-06-02 21-21-26.443 [Error] (Connection) Error in socket shutdown: Transport endpoint is not connected
02.06.21 21:21:27 (+0000) multiroom-client 2021-06-02 21-21-27.444 [Error] (Connection) Failed to connect to host ‘10.0.0.238’, error: Connection refused
02.06.21 21:21:27 (+0000) multiroom-client 2021-06-02 21-21-27.444 [Error] (Controller) Error: Connection refused

Oh gosh @ijduncan this is the sweetest forum thread I’ve ever read. :heart_eyes:

Your poor balena-boxes… how could they forget one another when their love was so strong??? I will ping the engineer who developed balenaSound to see if he can help rekindle the love between these two love-boxes. :heart:

1 Like

Hi Ian,

I am not the fabled balenaSound engineer Kenna mentioned - but since he seems pretty busy, I’ll see if I can help at all. :slight_smile:

The thing that stands out to me, is the network address that the logs show this device is trying to connect to. Are you running the devices on a 10-dot network? Can you confirm that 10.0.0.238 is the IP of the other balenaSound device, and can you reach it OK?

Phil

Yes I am running a 10 dot network. I can reach them individually. They just forget each other.

Screenshot 2021-06-09 100501

Hello Ian, sorry for the delay in replying. This post is lovely!

Regarding your problem, there are two instances where devices “sync up” and look for each other. First one is when a device first comes online, second is when a device starts playing sound. In both cases devices should exchange messages to establish which one is the “master”.

Possible problems you might be experiencing are:

  • devices are somehow unable to communicate during this syncing period
  • devices are well aware of each other but can’t they can’t reach the other (Failed to connect to host '10.0.0.238', error: Connection refused hints to this)

What can we do to remediate this?

First, ensure that your devices have a solid network connection (it appears they have one as you showed), you can double check for connectivity by SSHing into the hostOS on each device and pinging the other one (ping IP_ADDRESS, replace with actual ip addresses :D), you can use balenaCloud’s dashboard for that.

Second, you can collect useful device state to help troubleshoot. When you detect the devices are “disconnected” from each other, on your browser visit http://IP_ADDRESS/support for both devices are save the output. That’s going to help for sure.

Lastly, I created this GitHub issue (multiroom: improve fleet sync · Issue #466 · balenalabs/balena-sound · GitHub). I’ll be working on improving the way devices sync up shortly, I don’t have an ETA (let’s say a week-ish) but you’ll get notified in this thread once it’s done.

Hi @ijduncan,

I see you are running Unifi to manage your WiFi setup. I recognize that screen cap because I also run Unifi.

Unifi has a setting for your WiFi networks that isolates WiFi clients and prevents them from exchanging traffic directly, which could be causing this issue if it is enabled. Take a look through your WiFi network settings and make sure that setting is not enabled on your network. The feature is good for something like an office cafeteria network, where users have no need to access each other’s computers, and everyone should only be accessing the Internet. But in a home network, I think it’s more of a pain than it’s worth.

I looked and can’t seem to find the setting this time, because Ubiquiti keeps changing where things are in Unifi. But it’s there and should be turned off. I’m pretty sure it’s in the SSID configs - probably in the Advanced or Security sections.

EDIT: The setting is L2 Isolation: UniFi - SSID Options – Ubiquiti Support and Help Center

Cheers!
Mark-