Posts: 4
Threads: 1
Joined: Oct 2024
Reputation:
0
I have Moode set up on a Raspberry Pi 3b. Everything works fine except Spotify Connect randomly disonnects throughout the day. I can get it to reconnect by reselecting my Moode device from Spotify, but I want to know how I can prevent the disconnects form happening in the first place. My software is up to date and this problem has persisted for the last few months.
Here is a snippet of the log which captured a dropout. At 10:36, it disconnected:
20241008 103541 DEBUG: chkSQL(): type in ('nfs', 'cifs')
20241008 103542 DEBUG: chkSQL(): param='aplactive'
20241008 103542 DEBUG: chkSQL(): param='spotactive'
20241008 103545 DEBUG: chkSQL(): param='aplactive'
20241008 103545 DEBUG: chkSQL(): param='spotactive'
20241008 103548 DEBUG: chkSQL(): param='aplactive'
20241008 103548 DEBUG: chkSQL(): param='spotactive'
20241008 103551 DEBUG: chkSQL(): param='aplactive'
20241008 103551 DEBUG: chkSQL(): param='spotactive'
20241008 103554 DEBUG: chkSQL(): param='aplactive'
20241008 103554 DEBUG: chkSQL(): param='spotactive'
20241008 103558 DEBUG: chkSQL(): param='aplactive'
20241008 103558 DEBUG: chkSQL(): param='spotactive'
20241008 103601 DEBUG: chkSQL(): param='aplactive'
20241008 103601 DEBUG: chkSQL(): param='spotactive'
20241008 103604 DEBUG: chkSQL(): param='aplactive'
20241008 103604 DEBUG: chkSQL(): param='spotactive'
20241008 103607 DEBUG: chkSQL(): param='aplactive'
20241008 103607 DEBUG: chkSQL(): param='spotactive'
20241008 103610 DEBUG: chkSQL(): param='aplactive'
20241008 103610 DEBUG: chkSQL(): param='spotactive'
20241008 103611 DEBUG: chkSQL(): type in ('nfs', 'cifs')
20241008 103613 DEBUG: chkSQL(): param='aplactive'
20241008 103613 DEBUG: chkSQL(): param='spotactive'
20241008 103613 DEBUG: chkValue(): On
20241008 103613 DEBUG: chkValue(): jukebox
20241008 103613 DEBUG: chkValue(): Jukebox
20241008 103613 DEBUG: chkValue(): Europe/London
20241008 103613 DEBUG: chkValue(): gb
20241008 103613 DEBUG: chkValue(): Default
20241008 103613 DEBUG: chkValue(): performance
20241008 103613 DEBUG: chkValue(): vc4-kms-v3d
20241008 103613 DEBUG: chkValue(): 1
20241008 103613 DEBUG: chkValue(): 1
20241008 103613 DEBUG: chkValue(): 1
20241008 103613 DEBUG: chkValue(): 1
20241008 103613 DEBUG: chkValue(): 90
20241008 103613 DEBUG: chkValue(): Value is blank
20241008 103613 DEBUG: chkValue(): Off
20241008 103613 DEBUG: chkValue(): Off
20241008 103613 DEBUG: chkValue(): Value is blank
20241008 103613 DEBUG: chkValue(): rw,sync,no_subtree_check,no_root_squash
20241008 103613 DEBUG: chkValue(): Value is blank
20241008 103613 DEBUG: chkValue(): Moode DLNA
20241008 103613 DEBUG: chkValue(): 1
20241008 103613 DEBUG: chkValue(): off
20241008 103613 DEBUG: chkValue(): Value is blank
20241008 103613 DEBUG: chkValue(): automatic
20241008 103613 DEBUG: chkValue(): on
20241008 103613 DEBUG: chkValue(): 1
20241008 103613 DEBUG: chkValue(): 1
Posts: 13,445
Threads: 305
Joined: Mar 2018
Reputation:
545
Turn off Debug logging, reboot and then post the contents of the startup log.
The log can be viewed via the SSH command moodeutl -l or downloaded via the Logs section in System Config, or via Menu, System info from any of the Config screens. The startup log will be at the end of System info output.
Posts: 4
Threads: 1
Joined: Oct 2024
Reputation:
0
10-08-2024, 03:00 PM
(This post was last modified: 10-08-2024, 03:10 PM by Tim Curtis.
Edit Reason: put log in code box for readability
)
Hi Tim,
Thanks for the quick reply. Here is the startup log:
Code: 20241008 155833 worker: --
20241008 155833 worker: -- Start moOde 9 series
20241008 155833 worker: --
20241008 155833 worker: Successfully daemonized
20241008 155833 worker: Wait for Linux startup
20241008 155833 worker: Linux startup complete
20241008 155833 worker: Boot config is ok
20241008 155834 worker: Session loaded
20241008 155838 worker: Package locks applied
20241008 155843 worker: File check complete
20241008 155843 worker: Log to RAM on
20241008 155843 worker: Debug logging off
20241008 155843 worker: --
20241008 155843 worker: -- System
20241008 155843 worker: --
20241008 155846 worker: Host name: jukebox
20241008 155846 worker: RPi model: Pi-3B 1.2 1GB
20241008 155847 worker: moOde release: 9.1.2 2024-09-28
20241008 155847 worker: RaspiOS: 12.6 Bookworm 64-bit
20241008 155847 worker: Linux Kernel: 6.6.47 64-bit
20241008 155847 worker: MPD version: 0.23.14
20241008 155847 worker: User id: pi
20241008 155847 worker: Home folder: /home/pi
20241008 155847 worker: Time zone: Europe/London
20241008 155847 worker: Kbd layout: gb
20241008 155847 worker: HDMI ports(s): on
20241008 155847 worker: HDMI-CEC: off
20241008 155847 worker: Sys LED0: on
20241008 155847 worker: Sys LED1: on
20241008 155847 worker: Reduce power: n/a
20241008 155847 worker: CPU governor: ondemand
20241008 155847 worker: Integ audio: vc4-kms-v3d
20241008 155847 worker: --
20241008 155847 worker: -- Network
20241008 155847 worker: --
20241008 155847 worker: Eth0
20241008 155847 worker: Ethernet: adapter exists
20241008 155847 worker: Ethernet: timeout off
20241008 155847 worker: Ethernet: address not assigned
20241008 155847 worker: Wlan0
20241008 155847 worker: Wireless: adapter exists
20241008 155847 worker: Wireless: country GB
20241008 155847 worker: Wireless: SSID BTB-SCCGNQ
20241008 155847 worker: Wireless: other None
20241008 155847 worker: Wireless: timeout up to 90 secs
20241008 155847 worker: Wireless: connect to BTB-SCCGNQ
20241008 155847 worker: Wireless: method static
20241008 155847 worker: Wireless: address 192.168.1.151
20241008 155847 worker: Wireless: netmask 255.255.255.0
20241008 155847 worker: Wireless: gateway 192.168.1.254
20241008 155847 worker: Wireless: pri DNS 192.168.1.254
20241008 155847 worker: Wireless: domain home
20241008 155847 worker: --
20241008 155847 worker: -- File sharing
20241008 155847 worker: --
20241008 155847 worker: SMB file sharing: off
20241008 155847 worker: NFS file sharing: off
20241008 155847 worker: DLNA file sharing: off
20241008 155847 worker: --
20241008 155847 worker: -- Special configs
20241008 155847 worker: --
20241008 155847 worker: Plexamp: not installed
20241008 155847 worker: RoonBridge: not installed
20241008 155847 worker: Allo Piano 2.1: not detected
20241008 155847 worker: Allo Boss 2: not detected, OLED script ok
20241008 155847 worker: IQaudIO AMP*: not detected
20241008 155847 worker: --
20241008 155847 worker: -- ALSA debug
20241008 155847 worker: --
20241008 155847 worker: Cards: 0:vc4hdmi 1:IQaudIODAC 2:empty 3:empty
20241008 155847 worker: 4:empty 5:empty 6:empty 7:empty
20241008 155848 worker: Mixers: 0:none 1:(Digital) 2:none 3:none
20241008 155848 worker: 4:none 5:none 6:none 7:none
20241008 155848 worker: --
20241008 155848 worker: -- Audio configuration
20241008 155848 worker: --
20241008 155848 worker: Audio device: 1:IQaudIO Pi-DAC+
20241008 155848 worker: ALSA card: has not been reassigned
20241008 155848 worker: MPD config: update not needed
20241008 155848 worker: ALSA output: I2S
20241008 155848 worker: ALSA mode: Default (plughw)
20241008 155848 worker: ALSA mixer Digital
20241008 155849 worker: ALSA volume: 100% (0.00dB)
20241008 155849 worker: ALSA maxvol: 100%
20241008 155849 worker: ALSA loopback: off
20241008 155849 worker: MPD mixer Software
20241008 155849 worker: Audio formats: S16_LE, S24_LE, S32_LE
20241008 155849 worker: CamillaDSP: off
20241008 155849 worker: CDSP volume: 0dB
20241008 155849 worker: CDSP volrange: 60dB
20241008 155849 worker: --
20241008 155849 worker: -- MPD startup
20241008 155849 worker: --
20241008 155850 worker: MPD service: started
20241008 155850 worker: MPD port 6600: accepting connections
20241008 155916 worker: MPD ALSA Default: on
20241008 155916 worker: MPD ALSA Bluetooth: off
20241008 155916 worker: MPD HTTP Server: off
20241008 155916 worker: MPD volume: 0
20241008 155916 worker: Saved MPD vol: -1
20241008 155916 worker: Saved SRC vol: 0
20241008 155916 worker: MPD crossfade: off
20241008 155916 worker: MPD ignore CUE: yes
20241008 155916 worker: MPD CDSP volsync: off
20241008 155916 worker: --
20241008 155916 worker: -- Music sources
20241008 155916 worker: --
20241008 155916 worker: USB drives: none
20241008 155916 worker: NVMe drives: none
20241008 155916 worker: NAS sources: none
20241008 155916 worker: --
20241008 155916 worker: -- Feature availability
20241008 155916 worker: --
20241008 155916 worker: Input select: available, Source: MPD, Output: IQaudIO Pi-DAC+
20241008 155918 worker: Bluetooth: started, PIN: None, ALSA/CDSP maxvol: 100%/0dB, ALSA outmode: Standard
20241008 155918 worker: AirPlay: started
20241008 155918 worker: Spotify Connect: started
20241008 155918 worker: Squeezelite: available
20241008 155918 worker: UPnP client: available
20241008 155918 worker: Plexamp: not installed, ALSA maxvol: 100%
20241008 155918 worker: RoonBridge: not installed
20241008 155918 worker: Multiroom: available
20241008 155918 worker: GPIO buttons: available
20241008 155918 worker: Stream recorder: n/a
20241008 155918 worker: --
20241008 155918 worker: -- Security
20241008 155918 worker: --
20241008 155918 worker: Web SSH server: on
20241008 155918 worker: XSS detection: off
20241008 155918 worker: HTTPS mode: available
20241008 155918 worker: --
20241008 155918 worker: -- Peripherals
20241008 155918 worker: --
20241008 155923 worker: Local display: off
20241008 155923 worker: HDMI 4K 60Hz: off
20241008 155923 worker: On-screen kbd: off
20241008 155923 worker: Rotary encoder: off
20241008 155923 worker: USB volume knob: off
20241008 155923 worker: LCD updater: off
20241008 155923 worker: --
20241008 155923 worker: -- Miscellaneous
20241008 155923 worker: --
20241008 155923 worker: Software update: Automatic check on
20241008 155923 worker: Software update: Checking for available update...
20241008 155924 worker: Software update: Software is up to date
20241008 155924 worker: Auto-CoverView: off
20241008 155924 worker: CoverView timeout: Never
20241008 155924 worker: Auto-shuffle: off
20241008 155924 worker: Auto-play: off
20241008 155924 worker: Maintenance task: 360 mins
20241008 155924 worker: Current view: reset to Playback
20241008 155924 worker: Active flags: at least one true
20241008 155924 worker: Reset flags: all reset to false
20241008 155924 worker: MPD volume: set to 0
20241008 155924 worker: Session check: ok
20241008 155924 worker: --
20241008 155924 worker: -- Startup complete
20241008 155924 worker: --
20241008 155924 worker: Mount monitor: started
20241008 155924 worker: Radio monitor: off
20241008 155926 worker: Watchdog monitor: started
20241008 155926 worker: Responsiveness: Default
20241008 155926 worker: Ready
Posts: 13,445
Threads: 305
Joined: Mar 2018
Reputation:
545
I don't see anything suspicious in the log.
I never experience issues with Spotify Connect but some users have reported these random disconnects and in some cases librespot has crashed. You can determine if it has crashed by running the command below. It returns 0 if librespot is not running or has crashed.
When the disconnect occurs is librespot still running?
Posts: 4
Threads: 1
Joined: Oct 2024
Reputation:
0
I ran the command when Spotify dropped and got the following output:
pi@jukebox:~ $ pgrep -c librespot
1
Posts: 13,445
Threads: 305
Joined: Mar 2018
Reputation:
545
(10-08-2024, 03:54 PM)StudioSeventeen Wrote: I ran the command when Spotify dropped and got the following output:
pi@jukebox:~ $ pgrep -c librespot
1
That indicates it's still running which would suggest some sort of network issue external to moode and librespot
Posts: 4
Threads: 1
Joined: Oct 2024
Reputation:
0
Is there any way you could point me in the direction of finding out which part of my setup is causing the issue?
Posts: 5
Threads: 0
Joined: Aug 2023
Reputation:
0
I want to say "me too" here. I have 4 moode units each at different locations running on dedicated RPi4B's with Boss2 DACs, I have used at least one of them virtually every day with Spotify for years, and for at least a month now, Spotify connections drop constantly, sometimes in 2 minutes, sometimes but rarely as long as 20. I know my networks well and nothing has changed, all the more surely not in all locations simultaneously. Previously, connections would last indefinitely. If I accidentally left one playing at the end of the day having turned off the amp, it would still be playing the next day when I turn the amp on.
I'm not sure whether the problems began with a Moode update or if so which one, as there have been quite a few in v9.x All machines are on 9.1.2 now.
After the connection is dropped, it is interesting that after re-selecting the moode device, play resumes immediately, without a separate step of pressing "play." I have not tested to confirm, but I think this also happens when librespot loses its upstream connection temporarily. I'm using the upstream connection regularly on my computer and there is no problem with the upstream connection. Of course there are occasional glitches, but again they can't be happening so consistently at several locations over many weeks, without my noticing other upstream issues. The only thing in common is all upstreams are Comcast; could it be that Comcast is blacklisting Spotify servers? Audio traffic bandwidth is going to be trivial compared to video so I can't see why this would happen, I'm just thinking of plausible reasons which fit the evidence.
I've just turned on debug logging and will monitor. I see in a recent release librespot is under watchdog, but I should be seeing that get caught and restart, right? I don't think that's happening because I don't think play wouldn't resume immediately on re-connect.
Posts: 5
Threads: 0
Joined: Aug 2023
Reputation:
0
10-14-2024, 05:19 PM
(This post was last modified: 10-14-2024, 05:20 PM by chaetura.
Edit Reason: typo
)
(10-14-2024, 03:35 PM)chaetura Wrote: I want to say "me too" here. I have 4 moode units each at different locations running on dedicated RPi4B's with Boss2 DACs, I have used at least one of them virtually every day with Spotify for years, and for at least a month now, Spotify connections drop constantly, sometimes in 2 minutes, sometimes but rarely as long as 20. I know my networks well and nothing has changed, all the more surely not in all locations simultaneously. Previously, connections would last indefinitely. If I accidentally left one playing at the end of the day having turned off the amp, it would still be playing the next day when I turn the amp on. Today it seems like finally posting about this problem has made it go away: 90 minutes and counting, no drop so far today.
If only doing this would reliably make problems go away.
It's certainly plausible that some Spotify servers (i.e,. those serving some not all users) have been behaving poorly for weeks.
Posts: 6,029
Threads: 177
Joined: Apr 2018
Reputation:
235
I don't see how Tim and his merry band of devs (including backbenchers like me) can solve this problem. Since moOde is simply a conduit for the output of the third-party librespot app it would seem disconnection/dropout issues arise in librespot or upstream.
I note that there has been an ongoing librespot github discussion thread about how to "Handle reconnection for Sessions" that started in 2018 and continues today. The librespot devs don't seem to have a definitive answer. I don't understand the Spotify protocols well enough to know if that discussion topic covers your issue or not but it certainly rhymes.
Recently, one of the participants on that thread remarked "I'm testing go-librespot now. My experiences are much better. Very stable connection." Another responded "I see that go-librespot is just retrying a bunch of times, rotating around the access points. That isn't what librespot does but we might as well go down this route and paper over whatever problem this is. Maybe it is just Spotify's shoddy servers." (Here, access points refers to Spotify servers.) The principal dev responds that this papering over might work but would require substantial code rewrite on their part. This doesn't suggest to me that they have even identified the root causes.
Comcast is my ISP as well and I don't believe they're doing anything untoward with Spotify service (or any other music streaming service I dabble with). Spotify isn't my usual source but as a reference point, I've been listening to one of Spotify's "Radio" channels for the past hour without interruption. I'll keep it on in the background all today to see if it ever glitches.
Perhaps we have different experiences because our clients are connecting to different Spotify access points. I'm in Maryland on the east coast of the USA. Where are you located.
Regards,
Kent
|