6

System information: Computer Summary

Ubuntu version: 
philossefer@dell:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 22.04 LTS
Release:    22.04
Codename:   jammy

When I'm trying to launch Firefox Web Browser through terminal, following message is displayed before firefox is launched.

philossefer@dell:~$ firefox
update.go:85: cannot change mount namespace according to change mount (/var/lib/snapd/hostfs/usr/share/libreoffice/help /usr/share/libreoffice/help none bind,ro 0 0): cannot create directory "/usr/share/libreoffice/help": permission denied
Gtk-Message: 11:19:46.906: Failed to load module "canberra-gtk-module"
Gtk-Message: 11:19:46.985: Failed to load module "canberra-gtk-module"
ATTENTION: default value of option mesa_glthread overridden by environment.
ATTENTION: default value of option mesa_glthread overridden by environment.
ATTENTION: default value of option mesa_glthread overridden by environment.

Afterwards, whenever I'm trying to launch firefox, after the first launch in-between system boot, following messaged is been displayed before firefox gets launched.

philossefer@dell:~$ firefox
Gtk-Message: 11:19:46.906: Failed to load module "canberra-gtk-module"
Gtk-Message: 11:19:46.985: Failed to load module "canberra-gtk-module"
ATTENTION: default value of option mesa_glthread overridden by environment.
ATTENTION: default value of option mesa_glthread overridden by environment.
ATTENTION: default value of option mesa_glthread overridden by environment.

I have tried the following solution,by "copy and paste" those messages on google.

What I have tried so far, without any success

Try 1

sudo apt install libcanberra-gtk-module libcanberra-gtk3-module

Try 2

sudo apt-get install --reinstall libcanberra-gtk-module

Try 3: Remove firefox and then reinstall

Uninstall:

 sudo snap remove firefox

Reinstall:

sudo apt install firefox

NOTE: I was rebooting the system after, every installation and uninstallation.

reboot

Also Updated my Ubuntu beforehand.

sudo apt update && sudo apt upgrade -y

Current Status: Still those messages are there, when I'm launching firefox using command line.

My question is, why those messages are been displayed and how to get rid of them?

SubQuestion: Is there any difference between launching firefox through icon and through using command line?

11
  • 1
    If your Firefox is working correctly, you can ignore the messages to the terminal window. Many graphical programs send warning messages when started from a terminal window. -- Otherwise, if Firefox fails, and if you are using Wayland, you can try after changing to Xorg for the desktop graphics. See this link to another (maybe similar) thread at AskUbuntu.
    – sudodus
    May 20, 2022 at 7:27
  • That is 'only' a comment, not an error message.
    – sudodus
    May 20, 2022 at 13:32
  • @sudodus This is fresh installed copy of Ubuntu 22.04 LTS, On booting with ext4 or LVM installed copy, It would display /dev/sda2: clean, 194908/6102208 files, 6378606/244059136 blocks before the login. Installing Ubuntu through ZFS helped to resolve that issue. While trying to resolve /dev/sda2: clean, 194908/6102208 files, 6378606/244059136 blocks I tried, sudo apt-get install --reinstall xserver-xorg-video-vesa Xorg -configure' startx` From this link May 20, 2022 at 13:46
  • @sudodus Here, again you're suggesting Otherwise, if Firefox fails, and if you are using Wayland, you can try after changing to *Xorg* for the desktop graphics. IS there a correlation between it? Installation booting comment and firefox comment? May 20, 2022 at 13:48
  • In this case, I don't think so. Do Firefox and other important programs work?
    – sudodus
    May 20, 2022 at 13:52

3 Answers 3

2

I ran into the same issue. I was not able to get the snap working, however I was able to successfully install a Firefox deb on Ubuntu 22.04. You add the Mozilla Team PPA, install the Firefox deb, then pin them so the Firefox Snap is not installed later. Here are the steps I followed:

Step 1:

sudo snap remove firefox

Step 2:

echo '
Package: *
Pin: release o=LP-PPA-mozillateam
Pin-Priority: 1001
' | sudo tee /etc/apt/preferences.d/mozilla-firefox

Step 3:

echo 'Unattended-Upgrade::Allowed-Origins:: "LP-PPA-mozillateam:${distro_codename}";' | sudo tee /etc/apt/apt.conf.d/51unattended-upgrades-firefox

Step 4:

sudo apt install firefox

Reference: https://www.omgubuntu.co.uk/2022/04/how-to-install-firefox-deb-apt-ubuntu-22-04

2
  • 1
    Had a similar problem with inkscape 1.2 on ubuntu 22.04.some functionalitiese weren't working correctly. When starting from terminal, the failed-to-load-"canberra-gtk-module" message appeared. Uninstalling the snap-package and installing via apt fixed the problem
    – Max
    Feb 10, 2023 at 15:27
  • 2024 the snap package is still not a good one (at least not in all cases). Switching to deb fixed firefox 123.0.1 for me. Firefox now survives a reboot. By the way appamor profiles for snap firefox 123.0.1 do have syntax errors (appamor_parser 3.0.4 says). Funny thing is that the snap packages works as long as i do not do a reboot. Use the link above to use the latest tutorial instructions! Mar 9 at 14:21
1

Can't upvote or comment on the second answer due to just creating an account for mainly that purpose - so I'll write a follow-up answer.

I've run into the same problem, force-installing the snap-package despite the normal use of apt by Ubuntu is causing a heap of issues, and the one you're observing is one of them.

Uninstall the snap package, install the apt-package as described by @kaiyobi, and your issues should be gone (just until Ubuntu force-feeds you the snap package again, ignoring Pin-Priority etc, by their installers).

0

First, make sure it start well in GUI (normally by click)

If yes, then Try:

$ firefox-esr (this may work)

Firefox logo

4
  • It's working fine in GUI as well as through command line. I tried firefox-esr and this is the output firefox-esr: command not found. May 21, 2022 at 4:47
  • I think u install with snap May 21, 2022 at 5:49
  • I think u install with snap <br> that why msg occured . something snap not work fine. May be, snap can't get resources install by "apt'' . For example.., If u install VLC Media Player with apt as well snap .... You find there are two vlc media player available in menu.... you """"FireFox""" snap and you install PacKage through apt ................. then remove the snap package (of firefox) and install through apt *****It work well*** thank May 21, 2022 at 5:58
  • Earlier it was installed via apt, found it using type firefox. I removed it, due to your second comment I think u install with snap and installed it via snap. Later I read your recent comment, so should I install firefox or firefox-esr via apt? May 21, 2022 at 6:34

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .