release upgrade fails due to `firefox package pre-installation script subprocess returned error exit status 1`

Bug #1966589 reported by Leó Kolbeinsson
24
This bug affects 3 people
Affects Status Importance Assigned to Milestone
firefox (Ubuntu)
Fix Released
Undecided
Unassigned
ubuntu-release-upgrader (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

Upgrading from Lubuntu Focal 20.04.4 to Lubuntu Jammy 22.04 (date 27.03.2022)

The upgrader was unable to connect to the snap store in order to install the firefox snap

The upgrade was performed with GUI - do-release-upgrade -d -m desktop -f DistUpgradeViewKDE

The error "could not install the upgrades" was received.
I closed the error and then received th dialog box message "upgrade complete but there were errors during the upgrade process"

After rebooting I received an upgrade notification and the Firefox snap was installed.

ProblemType: Bug
DistroRelease: Ubuntu 22.04
Package: ubuntu-release-upgrader-core 1:22.04.7
ProcVersionSignature: Ubuntu 5.15.0-23.23-generic 5.15.27
Uname: Linux 5.15.0-23-generic x86_64
ApportVersion: 2.20.11-0ubuntu79
Architecture: amd64
CasperMD5CheckResult: unknown
CrashDB: ubuntu
CurrentDesktop: LXQt
Date: Sun Mar 27 13:08:26 2022
InstallationDate: Installed on 2022-03-27 (0 days ago)
InstallationMedia: Lubuntu 20.04.4 LTS "Focal Fossa" - Release amd64 (20220223)
PackageArchitecture: all
SourcePackage: ubuntu-release-upgrader
Symptom: ubuntu-release-upgrader
UpgradeStatus: Upgraded to jammy on 2022-03-27 (0 days ago)
VarLogDistupgradeXorgFixuplog:
 INFO:root:/usr/bin/do-release-upgrade running
 INFO:root:No xorg.conf, exiting
---
ProblemType: Bug
AddonCompatCheckDisabled: False
ApportVersion: 2.20.11-0ubuntu27.21
Architecture: amd64
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/controlC0: kf 950 F.... pulseaudio
BuildID: 20220322144853
CasperMD5CheckResult: skip
Channel: Unavailable
CurrentDesktop: LXQt
DefaultProfileExtensions: extensions.sqlite corrupt or missing
DefaultProfileIncompatibleExtensions: Unavailable (corrupt or non-existant compatibility.ini or extensions.sqlite)
DefaultProfileLocales: extensions.sqlite corrupt or missing
DefaultProfilePrefErrors: Unexpected character ',' before close parenthesis @ /usr/lib/firefox/omni.ja:greprefs.js:364
DefaultProfileThemes: extensions.sqlite corrupt or missing
DistroRelease: Ubuntu 22.04
ForcedLayersAccel: False
InstallationDate: Installed on 2022-03-30 (0 days ago)
InstallationMedia: Lubuntu 20.04.4 LTS "Focal Fossa" - Release amd64 (20220223)
IpRoute:
 default via 192.168.1.1 dev enp0s31f6 proto dhcp metric 100
 192.168.1.0/24 dev enp0s31f6 proto kernel scope link src 192.168.1.250 metric 100
Package: ubuntu-release-upgrader
PackageArchitecture: amd64
ProcVersionSignature: Ubuntu 5.13.0-39.44~20.04.1-generic 5.13.19
Profile0Extensions: extensions.sqlite corrupt or missing
Profile0IncompatibleExtensions: Unavailable (corrupt or non-existant compatibility.ini or extensions.sqlite)
Profile0Locales: extensions.sqlite corrupt or missing
Profile0PrefErrors: Unexpected character ',' before close parenthesis @ /usr/lib/firefox/omni.ja:greprefs.js:364
Profile0PrefSources: prefs.js
Profile0Themes: extensions.sqlite corrupt or missing
Profiles:
 Profile1 (Default) - LastVersion=None/None (Out of date)
 Profile0 - LastVersion=98.0.2/20220322144853 (In use)
RunningIncompatibleAddons: False
Tags: jammy
Uname: Linux 5.13.0-39-generic x86_64
UpgradeStatus: Upgraded to jammy on 2022-03-30 (0 days ago)
UserGroups: adm cdrom dip lpadmin plugdev sudo
_MarkForUpload: True
dmi.bios.date: 07/08/2021
dmi.bios.release: 1.20
dmi.bios.vendor: Dell Inc.
dmi.bios.version: 1.20.2
dmi.board.name: 0Y7WYT
dmi.board.vendor: Dell Inc.
dmi.board.version: A00
dmi.chassis.type: 3
dmi.chassis.vendor: Dell Inc.
dmi.modalias: dmi:bvnDellInc.:bvr1.20.2:bd07/08/2021:br1.20:svnDellInc.:pnOptiPlex7040:pvr:rvnDellInc.:rn0Y7WYT:rvrA00:cvnDellInc.:ct3:cvr:sku06B9:
dmi.product.family: OptiPlex
dmi.product.name: OptiPlex 7040
dmi.product.sku: 06B9
dmi.sys.vendor: Dell Inc.

Revision history for this message
Leó Kolbeinsson (leok) wrote :
description: updated
Revision history for this message
Leó Kolbeinsson (leok) wrote :

attached screenshot when upgrade completed

Revision history for this message
Leó Kolbeinsson (leok) wrote :

After reboot message

Revision history for this message
Ubuntu QA Website (ubuntuqa) wrote :

This bug has been reported on the Ubuntu ISO testing tracker.

A list of all reports related to this bug can be found here:
http://iso.qa.ubuntu.com/qatracker/reports/bugs/1966589

tags: added: iso-testing
Revision history for this message
Brian Murray (brian-murray) wrote :

I found this in /var/log/dist-upgrade/main.log:

2022-03-27 12:49:11,381 ERROR got an error from dpkg for pkg: '/tmp/apt-dpkg-install-FzL4nS/14-firefox_1%3a1snap1-0ubuntu1_amd64.deb': 'new firefox package pre-installation script subprocess returned error exit status 1'
2022-03-27 12:49:11,382 DEBUG running apport_pkgfailure() firefox: new firefox package pre-installation script subprocess returned error exit status 1
2022-03-27 12:49:11,386 ERROR got an error from dpkg for pkg: '/tmp/apt-dpkg-install-FzL4nS/14-firefox_1%3a1snap1-0ubuntu1_amd64.deb': 'new firefox package pre-installation script subprocess returned error exit status 1'

And looking Aptermlog.txt we see:

Preparing to unpack .../14-firefox_1%3a1snap1-0ubuntu1_amd64.deb ...^M
=> Installing the firefox snap^M
==> Checking connectivity with the snap store^M
==> Installing the firefox snap^M
2022-03-27T12:33:55Z INFO Waiting for automatic snapd restart...^M
error: cannot perform the following tasks:^M
- Run configure hook of "firefox" snap if present (run hook "configure": error: cannot create transient scope: DBus error "org.freedesktop.DBus.Error.TimedOut": [Failed to activate service 'org.freedesktop.systemd1': timed out (service_start_timeout=25000ms)])^M
dpkg: error processing archive /tmp/apt-dpkg-install-FzL4nS/14-firefox_1%3a1snap1-0ubuntu1_amd64.deb (--unpack):^M
 new firefox package pre-installation script subprocess returned error exit status 1^M
Please restart all running instances of firefox, or you will experience problems.^M

tags: added: rls-jj-incoming
Changed in ubuntu-release-upgrader (Ubuntu):
milestone: none → ubuntu-22.04
Revision history for this message
Leó Kolbeinsson (leok) wrote : AlsaInfo.txt

apport information

tags: added: apport-collected
description: updated
Revision history for this message
Leó Kolbeinsson (leok) wrote : CurrentDmesg.txt

apport information

Revision history for this message
Leó Kolbeinsson (leok) wrote : Dependencies.txt

apport information

Revision history for this message
Leó Kolbeinsson (leok) wrote : IpAddr.txt

apport information

Revision history for this message
Leó Kolbeinsson (leok) wrote : Lspci.txt

apport information

Revision history for this message
Leó Kolbeinsson (leok) wrote : PciNetwork.txt

apport information

Revision history for this message
Leó Kolbeinsson (leok) wrote : ProcCpuinfoMinimal.txt

apport information

Revision history for this message
Leó Kolbeinsson (leok) wrote : ProcEnviron.txt

apport information

Revision history for this message
Leó Kolbeinsson (leok) wrote : Profile0Prefs.txt

apport information

Revision history for this message
Leó Kolbeinsson (leok) wrote : PulseList.txt

apport information

Revision history for this message
Leó Kolbeinsson (leok) wrote : Re: Upgrader unable to contact snap store

Tested again - this time with TUI interface (do-release-upgrade) from a terminal and the upgrade finished with the error - "This upgrade has finished but there were errors.."
During the upgrade I noticed that the snap store was not contacted.
After reboot I noticed that Firefox was still the deb version - opened Discover to apply updates and noticed (see screenshot) that758.4 MB were waiting to update. Comments 6 to 14 are from this upgrade.

Also note - running lsb_release - r shows 22.04 (wallpaper not updated) and Prompt shows = Prompt=lts

I thought best to not file a new bug report as it seems to be same result of snap store.

Revision history for this message
Brian Murray (brian-murray) wrote :

I was able to recreate this on an Ubuntu 20.04 LTS system by editing /etc/apt/sources.list so that focal was replaced with jammy and then running `sudo apt-get update` and `sudo apt-get dist-upgrade`. I then found the following in the terminal:

Errors were encountered while processing:
 /tmp/apt-dpkg-install-pYF5m8/17-firefox_1%3a1snap1-0ubuntu1_amd64.deb
Error: Timeout was reached
E: Sub-process /usr/bin/dpkg returned an error code (1)

And the same error as posted earlier in /var/log/apt/term.log:

==> Installing the firefox snap^M
error: cannot perform the following tasks:^M
- Run configure hook of "firefox" snap if present (run hook "configure": error: cannot create transient scope: DBus error "org.freedesktop.DBus.Error.TimedOut": [Failed to activate service 'org.freedesktop.systemd1': timed out (service_start_timeout=25000ms)])^M
dpkg: error processing archive /tmp/apt-dpkg-install-pYF5m8/17-firefox_1%3a1snap1-0ubuntu1_amd64.deb (--unpack):^M
 new firefox package pre-installation script subprocess returned error exit status 1^M

Changed in firefox (Ubuntu):
milestone: none → ubuntu-22.04
summary: - Upgrader unable to contact snap store
+ release upgrade fails due to `firefox package pre-installation script
+ subprocess returned error exit status 1`
Revision history for this message
Sebastien Bacher (seb128) wrote :

the error is similar to the one on bug #1965805 which was said to be fixed by the new snapd, it would be worth checking if upgrading snapd on the system before upgrading fixes the issue

Revision history for this message
Brian Murray (brian-murray) wrote :

I followed the same test, s/focal/jammy/ in /etc/apt/sources.list and apt-get update. I then first installed the new snapd from jammy:

...
Preparing to unpack .../6-snapd_2.55.2+22.04_amd64.deb ...
Unpacking snapd (2.55.2+22.04) over (2.54.3+20.04.1ubuntu0.2) ...
...
Setting up snapd (2.55.2+22.04) ...
Installing new version of config file /etc/apparmor.d/usr.lib.snapd.snap-confine.real ...
snapd.failure.service is a disabled or a static unit, not starting it.
snapd.snap-repair.service is a disabled or a static unit, not starting it.
...

I then ran "sudo apt-get dist-upgrade" but I still encountered the same error:

Errors were encountered while processing:
 /tmp/apt-dpkg-install-DY0azb/17-firefox_1%3a1snap1-0ubuntu1_amd64.deb
Error: Timeout was reached
E: Sub-process /usr/bin/dpkg returned an error code (1)

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in firefox (Ubuntu):
status: New → Confirmed
Changed in ubuntu-release-upgrader (Ubuntu):
status: New → Confirmed
Revision history for this message
Leó Kolbeinsson (leok) wrote :

@brian-murray Brian

Tested Dell Latitude 7280 box 03.04.2022

Before running the upgrade Lubuntu Focal to Lubuntu Jammy I installed Firefox snap with command
"snap install firefox" rebooted and ran the "sudo do-release-upgrade -d".

The system upgraded and without errors.

Revision history for this message
Leó Kolbeinsson (leok) wrote :

Tested Dell [ Optiplex] MT 7040, and also Dell [ Optiplex] MT 7040,upgrading from Lubuntu Focal 20.04,4 to Lubuntu Jammy tests dated 04-04-2022 - upgrades performed with no errors.

http://iso.qa.ubuntu.com/qatracker/milestones/429/builds/246405/testcases/1635/results/

Changed in ubuntu-release-upgrader (Ubuntu):
status: Confirmed → Invalid
Revision history for this message
Brian Murray (brian-murray) wrote :

@leok - The testing which you referred to in comment #23 - did you first install the firefox snap or did you let the upgrade proceed as normal?

Revision history for this message
Leó Kolbeinsson (leok) wrote :

@brian-murray

No I did not install the Firefox snap prior to upgrade.
Just performed normal upgrades.
All Lubuntu Jammy upgrades I performed since 04-04-2022 from Focal and Impish upgraded with no errors and no problem with the Firefox snap.

The last upgrades test results here : http://iso.qa.ubuntu.com/qatracker/milestones/429/builds/246675/testcases

It looks to me that this issue is fixed.

Revision history for this message
Brian Murray (brian-murray) wrote :

I tested a release upgrade of Ubuntu today and did not encounter an error with the Firefox package. Additionally, we can see in apt-term.log that there was no error:

Preparing to unpack .../15-firefox_1%3a1snap1-0ubuntu2_amd64.deb ...^M
=> Installing the firefox snap^M
==> Checking connectivity with the snap store^M
==> Installing the firefox snap^M
^[[1mWarning:^[[0m /snap/bin was not found in your $PATH. If you've not restarted your^M
         session since you installed snapd, try doing that. Please see^M
         https://forum.snapcraft.io/t/9469 for more details.^M
^M
firefox 99.0-2 from Mozilla^[[32m\u2713^[[0m installed^M
=> Snap installation complete^M
Unpacking firefox (1:1snap1-0ubuntu2) over (99.0+build2-0ubuntu0.20.04.2) ...^M

Subsequently, I'm setting this to Fix Released.

Changed in firefox (Ubuntu):
status: Confirmed → Fix Released
Revision history for this message
Grzegorz Żur (grzegorz-zur) wrote :

I beg to differ.

The error still occurs on 2020 LTS and on 2022 LTS upgrades. The workaround is to open xterm and run `killall snap`. Only then the upgrade can progress with an error.

Use xterm because at this point other terminal emulators don't work.

To post a comment you must log in.