Please connect to your OpenWrt device using ssh and copy the output of the following commands and post it here using the "Preformatted text </> " button:
Remember to redact passwords, MAC addresses and any public IP addresses you may have:
I also doubt it is strictly an OpenWRT issue. I think it's a compatibility issue between Windows and the avahi-daemon. Or maybe Apple's own Bonjour service implements mDNS in a more efficient manner?
I wonder though what causes the hiccups between the Windows and the Avahi reflector. What could I try to improve reliability? As I said, it eventually starts working i.e. the Chrome browser does eventually discover the Chromecast device. The problem is that it is not reliable.
Tried it! I turned off Windows Firewall. No results. Aditionaly, when the Windows machine and the Chromecast share the subnet, they instantly become visible to one another. (regardless of Windows Firewall)
I'm addressing this problem on a clean OpenWRT install. Created two VLAN subnets and placed them under the same firewall zone. The avahi-daemon is up and running with enable-reflector=yes.
One thing to note is that macOS routinely sends queries to the multicast IP address (224.0.0.251 port 5353).
For Windows, it takes something like the Chrome browser to initiate a query to the multicast IP address. Otherwise, Windows itself is completely silent.
In the picture above you can see:
violet: Chromecast on 10.20.23.225, constantly sending queries to 224.0.0.251
light blue: avahi-daemon on 10.20.23.1 repeating macOS routine announcements from a different subnet
The avahi-daemon stuck on DNS query retransmission. Another clue why Windows and the Chrome browser is failing to recognize Chromecast devices available on other subnets.
Add cache-entries-max=0 to your /etc/avahi/avahi-daemon.conf file and it will reflect chromecast symmetrically across multiple subnets. All it takes to increase reliability from 10% to 100% on Windows machines. macOS does not care: works either way!