OTA update with mender on ubuntu 22.04 fails with no match between root and boot partitions

ota
Wed, 13 Mar 2024 18:44:13 +0000
Debian family

Hi,
I am using Mender to perform OTA for my project.
My goal is to install the ubuntu 22.04 image on a OnLogic board (x86-64).
I was successfully able to create the golden image for ubuntu server using the mender convert documentation instructions.

$  fdisk  -l input/golden-image-1.img
Disk input/golden-image-1.img: 28.91 GiB, 31042043904 bytes, 60628992 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 7F3620EC-54D5-4DDF-98B7-35A4C7EFC0F7

Device                      Start      End  Sectors Size Type
input/golden-image-1.img1    2048  2203647  2201600   1G EFI System
input/golden-image-1.img2 2203648 23175167 20971520  10G Linux filesystem

I can successfully install mender client in the board and can see the client in the devices section in the Mender UI.
I am using uefi for bootloader.

Here is the mender config file

MENDER_BOOT_PART="/dev/sda1"
MENDER_ROOTFS_PART_A="/dev/sda2"
MENDER_ROOTFS_PART_B="/dev/sda3"
MENDER_DATA_PART="/dev/sda4"
MENDER_BOOT_PART_MOUNT_LOCATION="/boot/efi"
#MENDER_BOOT_PART_SIZE_MB="1017"
#MENDER_DATA_PART_SIZE_MB="128"
MENDER_DEVICE_TYPE="x86_64"
#MENDER_PARTITION_ALIGNMENT="8388608"
#MENDER_STORAGE_TOTAL_SIZE_MB="16000"
#MENDER_ARTIFACT_NAME="release-3"
#MENDER_FEATURES="mender-convert  mender-client-install"
#MENDER_MACHINE="x86_64"
MENDER_GRUB_EFI_INTEGRATION="y"

MENDER_STORAGE_DEVICE_BASE=/dev/sda
MENDER_DEVICE_TYPE="x86_64"

MENDER_STORAGE_TOTAL_SIZE_MB=16000

# Nothing to copy
MENDER_COPY_BOOT_GAP="n"

function platform_modify() {
    #
    # Make sure /lib64 exists since the Mender binary requires it.
    # Some systems put everything under /lib (ie Yocto) and a simple
    # symlink is enough to find everything Mender needs.
    #
    if [ ! -e work/rootfs/lib64 ]; then
        run_and_log_cmd "ln -s /lib work/rootfs/lib64"
    fi
}

On creating a deployment I get the following error

2024-03-12 21:08:07 +0000 UTC info: Running Mender client version: 3.5.2
2024-03-12 21:08:08 +0000 UTC info: State transition: update-fetch [Download_Enter] -> update-store [Download_Enter]
2024-03-12 21:08:08 +0000 UTC info: No public key was provided for authenticating the artifact
2024-03-12 21:08:08 +0000 UTC info: Output (stderr) from command "fw_printenv": Configuration file wrong or corrupted
2024-03-12 21:08:08 +0000 UTC info: Output (stderr) from command "fw_printenv": Configuration file wrong or corrupted
2024-03-12 21:08:08 +0000 UTC error: Artifact install failed: Payload: can not install Payload: rootfs.img: No match between boot and root partitions.: exit status 247
2024-03-12 21:08:08 +0000 UTC info: State transition: update-store [Download_Enter] -> cleanup [Error]
2024-03-12 21:08:08 +0000 UTC info: State transition: cleanup [Error] -> update-status-report [none]

The install process looks for fw_printenv which is uboot related . How can I make the mender OTA install to use grub/efi instead of uboot, thanks

1 post - 1 participant