Cannot install delta after updating to dunfell and 2.6.1 mender-client

We have happily enjoyed hosted mender in yocto warrior for some time now with 2.3 client but we need to update to something newer…
Yocto Dunfell and mender-client 2.6.1 it is.
One thing we noticed straight away is that even after full-image installs (either from local file or mender cloud, didn’t make a difference) the artifact hash is not stored and any consecutive attempt for a delta update fails as is not overwritten with below typical message:

level=error msg="Artifact dependency \"rootfs_image_checksum\" not satisfied by currently installed artifact (c931182714b75c4d87c0efbb5a07e0c0ff22c1e8b7b5690e1b1653b6ca1dba92 != <nil>)."

Produced conf files

cat /etc/mender/mender.conf 
{
    "ArtifactVerifyKey": "/etc/mender/artifact-verify-key.pem",
    "InventoryPollIntervalSeconds": 28800,
    "RetryPollIntervalSeconds": 300,
    "ServerURL": "https://hosted.mender.io",
    "TenantToken": "********",
    "UpdatePollIntervalSeconds": 1800
}
cat /etc/mender/mender-connect.conf 
{
    "ShellCommand": "/bin/bash",
    "User": "nobody"
}

Restarting mender-connect:
systemctl restart mender-connect

I get these logs:

journalctl -fu mende*
Oct 26 12:25:22 xxx systemd[1]: Started Mender Connect service.
Oct 26 12:25:28 xxx mender-connect[8582]: time="2021-10-26T12:25:28Z" level=info msg="Loaded configuration file: /etc/mender/mender-connect.conf"
Oct 26 12:25:28 xxx mender-connect[8582]: time="2021-10-26T12:25:28Z" level=warning msg="No server URL(s) specified in mender configuration."
Oct 26 12:25:28 xxx mender-connect[8582]: time="2021-10-26T12:25:28Z" level=warning msg="ShellArguments is empty, defaulting to [--login]"
Oct 26 12:25:28 xxx mender-connect[8582]: time="2021-10-26T12:25:28Z" level=warning msg="Server entry 1 has no associated server URL."
Oct 26 12:25:28 xxx mender-connect[8582]: time="2021-10-26T12:25:28Z" level=warning msg="The server certificate cannot be loaded: no file provided"

Non-delta updates work fine. What are we missing?

The format of rootfs_image_checksum has changed to rootfs-image.checksum in order to be more compatible with software versioning, which uses . for namespacing. This could be a reason, although artifacts are supposed to stay compatible nevertheless.

Let’s find out more:

  1. What does mender show-provides on the device say?
  2. How did you create the rootfs-image artifact?
  3. How did you create the mender-binary-delta artifact?
  4. Which version is mender-artifact?
  5. Which version is mender-binary-delta-generator?
$ mender show-provides
artifact_name=base-1.0.0
rootfs-image.checksum=72720c11a8fbf7c6167ba5a7b1a44fb4cfeac9a8bc94b36754d838ec4fa068aa
rootfs-image.version=base-1.0.0

Hmm… I probably won’t provide useful info on this one unless you could be a bit more specific. We have included these in our recipe:

poky/../meta-mender/meta-mender-core \
poky/../meta-mender/meta-mender-raspberrypi \
poky/../meta-mender/meta-mender-commercial \
  1. Running this:
mender-binary-delta-generator -o UNSIGNED-DIFF.mender from.mender to.mender;

and then signing it:

mender-artifact sign UNSIGNED-DIFF.mender -k private.key -o SIGNED-DIFF.mender
$ /usr/bin/mender-artifact --version
mender-artifact version 3.2.1-1

moving to 3.6.0 :slight_smile:

$ mender-binary-delta-generator --version
mender-binary-delta-generator 1.1.0

moving to 1.2.1 :slight_smile:

So I guess upgrading parts on the build environment is one thing I see we are behind…

Any luck after upgrading?

Nope… still the same issue ( <nil> found)

Hmm, ok. I was hoping an upgrade would solve the incorrect punctuation in rootfs_image_checksum.

Could you also post the output from mender-artifact read <ARTIFACT>?

Apologies… last week’s test possibly missed the first full-image install needed for populating rootfs-image.checksum :roll_eyes:. Seems to work as expected now. Thank you!

Regarding the mender-connect messages from my first post… is this something irrelevant I would need to chase up as they are still present?

Good to hear!

Those messages from mender-connect are harmless, and should in fact be removed. I have added a ticket to get it resolved here.