Software & AppsOperating SystemLinux

Fixing Chrome Not Working After Upgrading to Ubuntu 22.04

Ubuntu 21

In this article, we will explore how to troubleshoot and fix issues with Google Chrome not working after upgrading to Ubuntu 22.04. We will cover several steps, including checking if the Google Chrome repository is enabled, ensuring your system is fully updated, and more.

Checking if the Google Chrome Repository is Enabled

The first step in our troubleshooting process is to check if the Google Chrome repository is enabled. In some instances, third-party repositories may be disabled during a release upgrade.

To check if the Google Chrome repository is enabled, open the terminal and type the following command:

cat /etc/apt/sources.list.d/google-chrome.list

If the repository is enabled, you should see a line like this:

deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main

If the repository is not enabled, you can enable it by using the following command:

echo 'deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main' | sudo tee /etc/apt/sources.list.d/google-chrome.list

After running this command, update your package list with the command:

sudo apt update

Updating Your System

The next step is to ensure that your system is fully updated. This can be done by running the following command:

sudo apt update && sudo apt upgrade

The sudo apt update command updates the list of available packages and their versions, but it does not install or upgrade any packages. The sudo apt upgrade command actually installs newer versions of the packages you have.

Switching from Wayland to X11

If you encounter the error message “libva error: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null)”, it may be related to the libva library failing to connect to Wayland.

You can try switching from Wayland to X11 by selecting an X11 session on the login screen.

Additionally, you can install the vainfo package and run the commands vainfo --display wayland and vainfo --display x11 to further debug the issue.

The vainfo package provides a utility that displays the capabilities of any video hardware accessible to the VA API. The --display option allows you to specify the display to use.

Launching Google Chrome with the --v=1 Flag

If the above steps do not resolve the issue, you can try launching Google Chrome with the --v=1 flag. This flag enables verbose logging, which may provide additional insight into the issue.

To do this, edit the /usr/share/applications/google-chrome.desktop file and add the flag to the Exec command.

sudo nano /usr/share/applications/google-chrome.desktop

Find the line that starts with Exec and add --v=1 to the end.

For example:

Exec=/usr/bin/google-chrome-stable %U --v=1

After making this change, save and close the file. Restart GDM3 or reboot your system for the changes to take effect.

sudo systemctl restart gdm3

Or

sudo reboot

Conclusion

In this article, we covered several steps to troubleshoot and fix Google Chrome not working after upgrading to Ubuntu 22.04. If you’re still experiencing issues after following these steps, it may be worth trying Chromium, the open-source version of Google Chrome, which is available as a snap package and may work even if Google Chrome is experiencing issues.

How can I check if the Google Chrome repository is enabled?

To check if the Google Chrome repository is enabled, open the terminal and type the command cat /etc/apt/sources.list.d/google-chrome.list. If the repository is enabled, you will see a line similar to deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main. If the repository is not enabled, you can enable it by using the command echo 'deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main' | sudo tee /etc/apt/sources.list.d/google-chrome.list. After that, update your package list with the command sudo apt update.

How can I update my system?

You can update your system by running the command sudo apt update && sudo apt upgrade. The sudo apt update command will update the list of available packages and their versions, while the sudo apt upgrade command will actually install newer versions of the packages you have.

How can I switch from Wayland to X11?

If you encounter the error message "libva error: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null)", you can try switching from Wayland to X11 by selecting an X11 session on the login screen. Additionally, you can install the vainfo package and run the commands vainfo --display wayland and vainfo --display x11 to further debug the issue. The vainfo package provides a utility that displays the capabilities of any video hardware accessible to the VA API, and the --display option allows you to specify the display to use.

How can I launch Google Chrome with the `–v=1` flag?

If the previous steps do not resolve the issue, you can try launching Google Chrome with the --v=1 flag to enable verbose logging. To do this, edit the /usr/share/applications/google-chrome.desktop file using the command sudo nano /usr/share/applications/google-chrome.desktop. Find the line that starts with Exec and add --v=1 to the end. For example, Exec=/usr/bin/google-chrome-stable %U --v=1. After making this change, save and close the file. Restart GDM3 or reboot your system for the changes to take effect using the command sudo systemctl restart gdm3 or sudo reboot.

What can I do if Google Chrome still doesn’t work after following these steps?

If you’re still experiencing issues with Google Chrome after following these steps, it may be worth trying Chromium, the open-source version of Google Chrome. Chromium is available as a snap package and may work even if Google Chrome is experiencing issues.

Leave a Comment

Your email address will not be published. Required fields are marked *