[Android Apps and Games] matagou:
Hello,

Regarding the issue "cannot play to CCA group OpenHome renderer, because Chromecast Audio group changes the master device after a hours or days". The CCA group is having 2 devices:

Bedroom speakers 192.168.1.126

Work Cabinet 192.168.1.119

I noticed that in the server log file, there is a mention about issue to connect to one of the CCA (which I suppose previously was the master and server still consider it the master) :

[cling-494 (Play) (5234) ] INFO - 21:34:26.229 - b : All Home Speakers group: connecting to platform...
[cling-494 (Play) (5234) ] INFO - 21:34:26.229 - b : connecting to 192.168.1.126:42991 ...
[cling-494 (Play) (5234) ] WARNING - 21:34:27.237 - b : All Home Speakers group: failed to connect to Google Cast device: java.net.ConnectException: Connection refused: connect
[cling-494 (Play) (5234) ] WARNING - 21:34:27.237 - d : Play: Error: failed to connect to Google Cast device
[cling-490 (5230) ] WARNING - 21:34:28.237 - d : retrying action Play on failure (org.fourthline.cling.support.avtransport.b: failed to connect to Google Cast device)

Telnetting to 192.168.1.126 TCP/42991 fails from my machine, connected to same SSID as CCAs and having IP address from same IP subnet as CCAs. However, device is replying to ICMP ping :

PS C:\Users\amoraru> Get-NetIPAddress -InterfaceAlias "Wi-Fi" | Where-Object {$_.AddressFamily -eq "IPv4"} | Select-Object IPAddress

IPAddress
---------
192.168.1.113

PS C:\Users\amoraru> ping 192.168.1.126

Pinging 192.168.1.126 with 32 bytes of data:
Reply from 192.168.1.126: bytes=32 time=2ms TTL=64
Reply from 192.168.1.126: bytes=32 time=1ms TTL=64
Reply from 192.168.1.126: bytes=32 time=2ms TTL=64
Reply from 192.168.1.126: bytes=32 time=1ms TTL=64

Ping statistics for 192.168.1.126:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 1ms, Maximum = 2ms, Average = 1ms
PS C:\Users\amoraru> telnet 192.168.1.126 42991
Connecting To 192.168.1.126...Could not open connection to the host, on port 42991: Connect failed

However, telneting to TCP/42991 of other device in the group works as expected.

So is the server just remembered that 192.168.1.126 is the master device and keep trying to connect to it, even master has been re-elected.

Please could you somehow setup a logic inside the server to rescan what is the new CCA master in the group and address to it?

I am asking because I plan to add 3 more CCAs to the current 2-member CCA group and things could get worse.

Current workaround is to restart server application which is so inconvenient to do on mobile phone, over RDP session or browser.

I attached server log file in e-mail message to you.

***** Later edit:

After server application reboot, server communicates successfully with new CCA master:

[cling-43 (SetAVTransportURI)] INFO - 02:01:48.899 - a : get probe info took: 601 ms
[cling-43 (SetAVTransportURI)] INFO - 02:01:48.899 - b : All Home Speakers group: got track duration: 0s
[cling-43 (SetAVTransportURI)] INFO - 02:01:48.901 - b : All Home Speakers group: should proxy: false
[cling-42 (5509) ] INFO - 02:01:48.901 - b : All Home Speakers group (DLNA): play: waiting 100 ms...
[cling-40 (Play) (5507) ] INFO - 02:01:49.02 - b : All Home Speakers group: play()
[cling-40 (Play) (5507) ] INFO - 02:01:49.02 - b : All Home Speakers group: connecting to platform...
[cling-40 (Play) (5507) ] INFO - 02:01:49.04 - b : connecting to 192.168.1.119:42991 ...
[cling-40 (Play) (5507) ] INFO - 02:01:49.78 - b : connected to 192.168.1.119:42991
[CastSocketRead (5527) ] INFO - 02:01:49.80 - b$5 : CastSocketRead thread started
[cling-40 (Play) (5507) ] INFO - 02:01:49.93 - b : All Home Speakers group: platform connected
[cling-40 (Play) (5507) ] INFO - 02:01:49.93 - b : All Home Speakers group: launch receiver...
[cling-42 (5509) ] INFO - 02:01:49.97 - b : All Home Speakers group (DLNA): waitForTransportState: waiting for Playing
[CastSocketRead (5527) ] INFO - 02:01:52.793 - b : All Home Speakers group: receiver launched or joined

Best regards,

Andrei