Chromecast Fails to Work in Chromium or Chrome on F31

I have installed on a work laptop F31 XFCE spin. We use this computer to do presentations, normally plugged into a projector, but sometimes we cast a Google Presentation to a TV with a Chromecast. I know the Chromecast is working fine. A Windows 10 computer running Google Chrome was able to cast to the Chromecast/TV combo just fine. Both computers are connected to the same network interface as the Chromecast as well.

My F31 XFCE computer has both Chromium and Chrome installed. Neither of the browsers see the Chromecast device on the network. When I attempt to ā€œcastā€ to a device it searches and comes back saying ā€œNo devices foundā€. I installed Chromium from the F31 repos, and I installed Chrome from the Google download rpm that they provide so I know Iā€™m using the lastest stable versions.

Are there some security settings in F31 that I might need to adjust to make this work?

1 Like

I donā€™t experience this on chrome, but on chromium-freeworld when using F31 with gnome.
There is an open source project ā€˜fx castā€™ which aims to bring chromecast to firefox.
I know, this doesnā€™t seem to be a proper solution, but might be still useful to others.

May I ask how you installed Chrome?

  • My Chrome install seems to have the same issue as my Chromium install from the default F31 repos.

Also it sounds like casting fails when you use chromium-freeworld from the RPMFusion repos, is that correct?

  • If that is correct it wouldnā€™t help to uninstall chromium from the default F31 repos and reinstall from the RPMFusion repos.

This same machine had Lubuntu 19.04 on it, with Chromium installed, and casting worked great. I switched it over to F31 because Iā€™m on Fedora at home and have become more familiar with managing Fedora systems. I donā€™t know what Fedora could be doing differently from the Ubuntu when it comes to Chromium or Chrome and casting, that is why I wondered if there was a Fedora security setting that might be getting in the way.

Ok, an update. I decided to try Chrome again after @locke had mentioned that it worked. I had to boot up the computer (I did not reboot after installing Chrome earlier). When I booted up:

  1. Chrome (installed from the Google provided rpm on their Chrome site) worked as expected. It connected to the Chromecast, and I was able to cast a Google Slides presentation to the TV.

  2. Chromium still failed to find the Chromecast, even though Chrome had just connected to it. Then when I went back into Chrome its casting ability was now broke again. It could no longer find the Chromecast after Chromium had attempted to find it and failed. After rebooting Chrome once again could connect to the Chromecast.

  • My current work around is this. I uninstalled Chromium from the standard F31 repos, and I will just run Chrome on this work computer.
  • Iā€™m thinking that some library or proprietary bit was removed from the standard F31 repo version of Chromium that is needed for casting to work with a Chromecast. I guessing Ubuntu has chosen to leave that library or bit in their built version of Chromium in their repos and that is why casting works fine from the Ubuntu family with Chromium or Chrome.
  • Iā€™m not sure why attempting to cast from Chromium in F31 then breaks Chromeā€™s casting ability until a reboot.

If others can verify this behavior, perhaps I will file a bug with the Fedora devs to see if there is an easy fix.

1 Like

I decided to file a bug report to get the eyes of the developers on this issue since it sounds like both @locke and I have the same issue.

https://bugzilla.redhat.com/show_bug.cgi?id=1769970

3 Likes

This seems to be related to mDNS discovery.
I recommend to replace the default resolver with systemd-resolved and nss-resolve which should work better for mDNS, especially in the dual-stack mode:

sudo systemctl --now enable systemd-resolved.service
sudo ln -r -s -f /run/systemd/resolve/stub-resolv.conf /etc/resolv.conf
sudo sed -i -r -e "s/^(hosts:\s*).*/\1files mymachines resolve [!UNAVAIL=return] dns myhostname/" /etc/nsswitch.conf

@vgaetera so I have tested chromium-freeworld (which installed when I attempted to install chromium-vaapi Iā€™m assuming it is the same thing from rpmfusion). That version of chromium doesnā€™t find the chromecast device on the network either.

You seem to believe that this is not related to Chromium and what the Fedora team has removed from Chromium, but instead it has to do with mDNS. Iā€™m a little unsure of what your sed command does to fix this issue, and Iā€™m also wondering why this is needed for Chromium and not for Chrome, because I have confirmed that Chrome does work after installing and rebooting it will find a Chromecast. I would however appreciate your feedback.

I would like to update the Fedora Quick Doc for installing Chromium and Chrome, but I donā€™t feel that mucking around in the internals of Fedoraā€™s mDNS system belongs in the ā€œQuick Docsā€. That seems to be taking the issue to a new level that is probably a bit beyond the average user that would be consulting the Quick Docs to simply figure out how to get Chromium or Chrome installed on their system. So what do you think we should do to proceed and help resolve this issue for Fedora users?

  1. I would like to rewrite the Quick Doc with a note that the Chromium builds available in the Fedora Repos and RPMFusion repos have broken features such as Chromecasting. If Chromecasting is a feature the is needed it is encouraged that the user installs Chrome from the Google provided RPM.
  • Do you feel this is a good solutions for the Quick Docs so they are no longer giving misinformation?
  1. Would it be a good idea to add your thoughts about mDNS to the bug report that I opened, and request an infrastructure change to correct this problem or should to be done as a separate bug. I noticed that you CC: yourself to the bug that I opened, that is why Iā€™m asking for your input on this.

Thank you for the part you played in researching mDNS, that is an area where I have no knowledge so I appreciate the work you have done there.

Hi. You need enable Chomecast feature. I am not sure if chromium in Fedora repositories enabled it in the builtā€¦ But as consumer I told you chromium-freeworld (UnitedRPMs) works fine with my Chromecast v.3 and V.2.

How to enable Chromecast support in chromium-freeworld or Chrome?

  1. All thatā€™s needed is to enable ā€œ chrome://flags/#load-media-router-component-extension ā€œā€¦ just copy and paste that bold text into your Chromium URL entry field and you get this, and enable it.

  1. Enable ā€œ chrome://flags/#mirroring-service ā€œā€¦ just copy and paste that bold text into your Chromium URL entry field and you get this, and enable it.

Enjoy!

I responded on your bug, and Iā€™ll also respond here, although likely you are no longer on F31, this might help someone else:

ā€œI experienced the same issue on F33 with chromium and found the solution. You must only enable the following flag: chrome://flags/#load-media-router-component-extension. Yes there are a few other casting related settings, but you donā€™t need them. There may also be some firewall related settings, Thereā€™s a post on the internet about it from a ā€˜Linux Kamaradaā€™ if youā€™re interested (itā€™s talking about a different distro but the settings are the same)ā€.

If you also want to cast from VLC, you will likely need to install avahi and avahi-compat-libdns_sd, and if you want to cast DRM protected media then you will need to install Google Chrome proper.