Occasionally fwupd-refresh.service: Failed with result 'exit-code'

Bug #1909603 reported by Lyubomir
34
This bug affects 7 people
Affects Status Importance Assigned to Milestone
Fwupd
Fix Released
Unknown
fwupd (Ubuntu)
Fix Released
Undecided
Unassigned
Focal
Confirmed
Undecided
Unassigned
Groovy
Fix Released
Undecided
Unassigned
Hirsute
Fix Released
Undecided
Unassigned

Bug Description

Hello, inside the system logs i find these lines:
fwupd-refresh.service: Failed with result 'exit-code'.
Failed to start Refresh fwupd metadata and update motd.

systemctl status fwupd shows these:
дек 29 19:11:12 lyubo-Aspire-A515-51G systemd[1]: Starting Refresh fwupd metadata and update motd...
дек 29 19:11:19 lyubo-Aspire-A515-51G fwupdmgr[537540]: Fetching metadata https://cdn.fwupd.org/downloads/firmware.xml.gz
дек 29 19:11:20 lyubo-Aspire-A515-51G fwupdmgr[537540]: Fetching signature https://cdn.fwupd.org/downloads/firmware.xml.gz.asc
дек 29 19:11:20 lyubo-Aspire-A515-51G systemd[1]: fwupd-refresh.service: Main process exited, code=exited, status=1/FAILURE
дек 29 19:11:20 lyubo-Aspire-A515-51G systemd[1]: fwupd-refresh.service: Failed with result 'exit-code'.
дек 29 19:11:20 lyubo-Aspire-A515-51G systemd[1]: Failed to start Refresh fwupd metadata and update motd.

ProblemType: Bug
DistroRelease: Ubuntu 20.04
Package: fwupd 1.3.11-1~focal1
ProcVersionSignature: Ubuntu 5.10.0-1008.9-oem 5.10.0
Uname: Linux 5.10.0-1008-oem x86_64
ApportVersion: 2.20.11-0ubuntu27.14
Architecture: amd64
CasperMD5CheckResult: skip
Date: Tue Dec 29 21:17:34 2020
InstallationDate: Installed on 2020-12-27 (1 days ago)
InstallationMedia: Kubuntu 20.04.1 LTS "Focal Fossa" - Release amd64 (20200731)
SourcePackage: fwupd
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Lyubomir (mystiquewolf) wrote :
Revision history for this message
Mario Limonciello (superm1) wrote :

Do you know if you were offline at that time? Would you mind double checking if you can run it now and see if it reproduces?

# systemctl start fwupd-refresh.service

Revision history for this message
Lyubomir (mystiquewolf) wrote :

Now it seems that it succeeded. There are network problems sometimes, but most of the time there is an internet connection. Maybe 3-4 times per day for about 10 seconds at max there isn't internet.

Revision history for this message
Mario Limonciello (superm1) wrote :

Would it be possible to take it off internet and repeat and check if it happens when no internet? If so, we probably need to come up with a way to not run the unit in those circumstances.

Revision history for this message
Lyubomir (mystiquewolf) wrote :

7.01.21 г. 22:11 ч. sudo lyubo : TTY=pts/1 ; PWD=/home/lyubo ; USER=root ; COMMAND=/usr/bin/systemctl status fwupd-refresh.service
7.01.21 г. 22:13 ч. sudo lyubo : TTY=pts/1 ; PWD=/home/lyubo ; USER=root ; COMMAND=/usr/bin/systemctl start fwupd-refresh.service
7.01.21 г. 22:13 ч. systemd Starting Refresh fwupd metadata and update motd...
7.01.21 г. 22:13 ч. dbus-daemon [system] Activating via systemd: service name='org.freedesktop.fwupd' unit='fwupd.service' requested by ':1.377' (uid=62803 pid=18791 comm="/usr/bin/fwupdmgr refresh --no-metadata-check " label="unconfined")
7.01.21 г. 22:13 ч. dbus-daemon [system] Activating via systemd: service name='org.freedesktop.bolt' unit='bolt.service' requested by ':1.378' (uid=0 pid=18804 comm="/usr/libexec/fwupd/fwupd " label="unconfined")
7.01.21 г. 22:13 ч. bolt.service power: guard '2' for 'fwupd' active
7.01.21 г. 22:13 ч. fwupd 20:13:24:0921 FuEngine device 5dbeb140337f610d54913c0f43d15fdaa0eafb51 [WDC WD10SPZX-21Z10T0] does not define a vendor-id!
7.01.21 г. 22:13 ч. dbus-daemon [system] Successfully activated service 'org.freedesktop.fwupd'
7.01.21 г. 22:13 ч. fwupdmgr Fetching metadata https://cdn.fwupd.org/downloads/firmware.xml.gz
7.01.21 г. 22:13 ч. fwupdmgr Fetching signature https://cdn.fwupd.org/downloads/firmware.xml.gz.asc
7.01.21 г. 22:13 ч. fwupdmgr Successfully downloaded new metadata: 0 local devices supported
7.01.21 г. 22:13 ч. systemd fwupd-refresh.service: Succeeded.
7.01.21 г. 22:13 ч. systemd Finished Refresh fwupd metadata and update motd.
7.01.21 г. 22:13 ч. sudo lyubo : TTY=pts/1 ; PWD=/home/lyubo ; USER=root ; COMMAND=/usr/bin/systemctl status fwupd-refresh.service
7.01.21 г. 22:13 ч. bolt.service power: guard '2' for 'fwupd' deactivated
7.01.21 г. 22:13 ч. sudo lyubo : TTY=pts/1 ; PWD=/home/lyubo ; USER=root ; COMMAND=/usr/bin/systemctl start fwupd-refresh.service
7.01.21 г. 22:13 ч. systemd Starting Refresh fwupd metadata and update motd...
7.01.21 г. 22:13 ч. systemd fwupd-refresh.service: Succeeded.
7.01.21 г. 22:13 ч. systemd Finished Refresh fwupd metadata and update motd.
7.01.21 г. 22:14 ч. sudo lyubo : TTY=pts/1 ; PWD=/home/lyubo ; USER=root ; COMMAND=/usr/bin/systemctl status fwupd-refresh.service

Revision history for this message
Lyubomir (mystiquewolf) wrote :

The first time is with internet enabled, the second with internet disabled.

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

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

Changed in fwupd (Ubuntu):
status: New → Confirmed
Revision history for this message
sascha arthur (sarthur) wrote :

Its a bug in 1.3.* as you can read here:

https://github.com/fwupd/fwupd/issues/391#issuecomment-756941356

Also they dont want to bring an update for ubuntu 20.04 LTS as you can read here:

https://github.com/fwupd/fwupd/issues/2708#issuecomment-758850957

Further information can also be found here: https://github.com/fwupd/fwupd/issues/2532

Can someone explain why exactly this fwupd is installed on ubuntu 20.04 server editions?

I see mostly consumer hardware in their list of provided firmwares: https://cdn.fwupd.org/lvfs/devices/

On most servers thers prob. no advantage of having this daemon running/failing especially when they dont want to bring stability to their sofware used in LTS versions..

Im removing this daemon from my servers..

Changed in fwupd (Ubuntu Focal):
status: New → Confirmed
Changed in fwupd (Ubuntu Groovy):
status: New → Fix Released
Changed in fwupd (Ubuntu Hirsute):
status: Confirmed → Fix Released
summary: - fwupd-refresh.service: Failed with result 'exit-code'
+ Occasionally fwupd-refresh.service: Failed with result 'exit-code'
Revision history for this message
Mario Limonciello (superm1) wrote :

As mentioned in #8 there has been several upstream discussions and it was concluded this is due to a CDN mirroring issue causing problems with the metadata design used in 1.3.x or earlier versions.

There was an updated design added into fwupd 1.4.x and later that will avoid the CDN mirroring issue. So this bug does not affect groovy (1.4.x) or hirsute (1.5.x).

The reason that this started to "show up" in 1.3.x on focal is because focal also introduced a new systemd unit fwupd-refresh.service and fwupd-refresh.timer. These will download metadata regularly and notify the user via the motd of any devices with firmware updates.

That being said it's *definitely* occurred on fwupdmgr or gnome-software as well which can be seen from the other issues linked in #8.

For anyone encountering this, a few workarounds:
1) If you're not ever intending on using fwupd on your machine, you can remove it
# sudo apt purge fwupd

2) If your machine does support updates and you'll just manually check for updates, mask the service to prevent it from running.
# sudo systemctl mask fwupd-refresh.service

3) Modify the fwupd-refresh.service unit to set "1" as a valid return code. This would paper over the issues when there are CDN problems and potentially mean you'll be a day or two behind in notification for new firmware updates.

The most "proper" solution in Ubuntu should be a backport of 1.4.x or 1.5.x to focal. Due to the requirements and previous agreements in SRU policy this will require alignment with the technical board as well as a MIR for libjcat which is in universe for focal. It's in main for groovy and later.

Changed in fwupd:
status: Unknown → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.