Mender client retro-compatibility

I am looking for information regarding the mender client reto-compatibility.

During an update, the first part of the update (install) will be done in the initial system version (orgin). The second part (commit) will be done in the upgraded version of the system (target). This means that the mender version on “target” must be compatible with the mender version on “origin”. When I say compatible, I mean that the information produced by “origin” must be consumed by “target”.

I had no issues in the past with upgrading from a 2.2 mender client version system to a mender 3.3 version system. However, I’m now trying to upgrade to 5.0 and it fails. On the target system, mender will systematically do a rollback (e.g. when running mender-update commit), without any warning or info on why it occurs. This leads me to think that 5.0 is not retro-compatible with 3.3 in some way.

Do you have any information regarding retro-compatibility in mender client between 2.x, 3.x, 4.x and 5.x versions?

Hi @Chris,

The Mender Client does not roll back based on versions or such, so the first thing to check is if there was an additional reboot between the origin and the target version. Depending on your exact setup, inspect the bootcount and upgrade_available variables before invoking mender-update commit, as described at Integration checklist | Mender documentation.

If those are not as expected, that’s the reason for the rollback. What OS and release(s) are you on?

Greetz,
Josef

Hi Josef,
Thanks for your answer. The environment is correct (bootcount=1,upgrade_available=1).

This happens systematically when using 5.0 and never when using 3.3/4.0.

Here is the log for 5.0:

$ sudo mender-update -l trace commit
record_id=1 severity=trace time="2024-Nov-28 15:32:15.697540" name="Global" msg="Entering state N6mender6update10standalone13JustSaveStateE" 
record_id=2 severity=trace time="2024-Nov-28 15:32:15.713711" name="Global" msg="Entering state N6mender6update10standalone17ScriptRunnerStateE" 
record_id=3 severity=info time="2024-Nov-28 15:32:15.955880" name="Global" msg="Running State Script: /var/lib/mender/scripts/ArtifactRollback_Enter_10_Config-migration-enable" 
record_id=4 severity=trace time="2024-Nov-28 15:32:16.022629" name="Global" msg="Entering state N6mender6update10standalone21ArtifactRollbackStateE" 
record_id=5 severity=trace time="2024-Nov-28 15:32:17.349786" name="Global" msg="Entering state N6mender6update10standalone17ScriptRunnerStateE" 
record_id=6 severity=trace time="2024-Nov-28 15:32:17.542640" name="Global" msg="Entering state N6mender6update10standalone13JustSaveStateE" 
record_id=7 severity=trace time="2024-Nov-28 15:32:17.548771" name="Global" msg="Entering state N6mender6update10standalone17ScriptRunnerStateE" 
record_id=8 severity=info time="2024-Nov-28 15:32:17.739180" name="Global" msg="Running State Script: /var/lib/mender/scripts/ArtifactFailure_Enter_10_Config-migration-enable" 
record_id=9 severity=trace time="2024-Nov-28 15:32:17.791775" name="Global" msg="Entering state N6mender6update10standalone20ArtifactFailureStateE" 
record_id=10 severity=trace time="2024-Nov-28 15:32:17.841236" name="Global" msg="Entering state N6mender6update10standalone17ScriptRunnerStateE" 
record_id=11 severity=info time="2024-Nov-28 15:32:18.030807" name="Global" msg="Running State Script: /var/lib/mender/scripts/ArtifactFailure_Leave_00_Setup-migration-cleanup" 
record_id=12 severity=trace time="2024-Nov-28 15:32:18.083071" name="Global" msg="Entering state N6mender6update10standalone13JustSaveStateE" 
record_id=13 severity=trace time="2024-Nov-28 15:32:18.087896" name="Global" msg="Entering state N6mender6update10standalone12CleanupStateE" 
record_id=14 severity=trace time="2024-Nov-28 15:32:18.147346" name="Global" msg="Entering state N6mender6update10standalone9ExitStateE" 
Rolled back.

This is a Poky based disto, on meta-mender kirkstone-4.0.22 with a few custom changes (but not on mender-client).

I know mender-client 5 has not been released yet, but do you know if there are any breaking changes planned?

Hi @Chris,

There is a breaking change, otherwise per semantic versioning it would have been a 4.x. This is it: https://github.com/mendersoftware/mender/commit/5b9691ae17e4b3d8724978bb5e809e7af9b8b9c6: the docker, script, deb and rpm Update Modules are moved out of the default installation.

But your log looks more like something in ArtifactInstall going wrong, as it goes straight to ArtifactFailure from there (see also State scripts | Mender documentation).

Does it also happen without the state scripts, e.g. if you build the same image with pre-5.0 and 5.0, no application change and no migration?

Greetz,
Josef

Hi Josef,

I get the same behavior without any state scripts.

$ sudo mender --version
v3.3.0     runtime: go1.19.4

$ sudo mender -l trace install http://artifact-url.mender
DEBU[0000] Reading Mender configuration from file /var/lib/mender/mender.conf 
INFO[0000] Loaded configuration file: /var/lib/mender/mender.conf 
DEBU[0000] Reading Mender configuration from file /etc/mender/mender.conf 
INFO[0000] Loaded configuration file: /etc/mender/mender.conf 
DEBU[0000] Loaded 2 configuration file(s)               
INFO[0000] 'UpdateControlMapExpirationTimeSeconds' is not set in the Mender configuration file. Falling back to the default of 2*UpdatePollIntervalSeconds 
INFO[0000] 'UpdateControlMapBootExpirationTimeSeconds' is not set in the Mender configuration file. Falling back to the default of 600 seconds 
DEBU[0000] Loaded configuration = &conf.MenderConfig{MenderConfigFromFile:conf.MenderConfigFromFile{ArtifactVerifyKey:"", HttpsClient:client.HttpsClient{Certificate:"", Key:"", SSLEngine:""}, Security:client.Security{AuthPrivateKey:"", SSLEngine:""}, Connectivity:client.Connectivity{DisableKeepAlive:false, IdleConnTimeoutSeconds:0}, RootfsPartA:"ubi0_0", RootfsPartB:"ubi0_1", BootUtilitiesSetActivePart:"", BootUtilitiesGetNextActivePart:"", DeviceTypeFile:"", DBus:conf.DBusConfig{Enabled:true}, UpdateControlMapExpirationTimeSeconds:0, UpdateControlMapBootExpirationTimeSeconds:0, UpdatePollIntervalSeconds:1800, InventoryPollIntervalSeconds:28800, SkipVerify:false, RetryPollIntervalSeconds:300, RetryPollCount:0, StateScriptTimeoutSeconds:0, StateScriptRetryTimeoutSeconds:0, StateScriptRetryIntervalSeconds:0, ModuleTimeoutSeconds:0, ServerCertificate:"", ServerURL:"https://docker.mender.io", UpdateLogPath:"", TenantToken:"dummy", Servers:[]client.MenderServer(nil)}, ModulesPath:"/usr/share/mender/modules/v3", ModulesWorkPath:"/var/lib/mender/modules/v3", ArtifactInfoFile:"/etc/mender/artifact_info", ArtifactScriptsPath:"/var/lib/mender/scripts", RootfsScriptsPath:"/etc/mender/scripts"} 
DEBU[0000] Verified configuration = &conf.MenderConfig{MenderConfigFromFile:conf.MenderConfigFromFile{ArtifactVerifyKey:"", HttpsClient:client.HttpsClient{Certificate:"", Key:"", SSLEngine:""}, Security:client.Security{AuthPrivateKey:"", SSLEngine:""}, Connectivity:client.Connectivity{DisableKeepAlive:false, IdleConnTimeoutSeconds:0}, RootfsPartA:"ubi0_0", RootfsPartB:"ubi0_1", BootUtilitiesSetActivePart:"", BootUtilitiesGetNextActivePart:"", DeviceTypeFile:"/var/lib/mender/device_type", DBus:conf.DBusConfig{Enabled:true}, UpdateControlMapExpirationTimeSeconds:0, UpdateControlMapBootExpirationTimeSeconds:0, UpdatePollIntervalSeconds:1800, InventoryPollIntervalSeconds:28800, SkipVerify:false, RetryPollIntervalSeconds:300, RetryPollCount:0, StateScriptTimeoutSeconds:0, StateScriptRetryTimeoutSeconds:0, StateScriptRetryIntervalSeconds:0, ModuleTimeoutSeconds:0, ServerCertificate:"", ServerURL:"https://docker.mender.io", UpdateLogPath:"", TenantToken:"dummy", Servers:[]client.MenderServer{client.MenderServer{ServerURL:"https://docker.mender.io"}}}, ModulesPath:"/usr/share/mender/modules/v3", ModulesWorkPath:"/var/lib/mender/modules/v3", ArtifactInfoFile:"/etc/mender/artifact_info", ArtifactScriptsPath:"/var/lib/mender/scripts", RootfsScriptsPath:"/etc/mender/scripts"} 
DEBU[0000] Tried command "grub-mender-grubenv-print", but it was not found 
DEBU[0000] Tried command "systemd-boot-printenv", but it was not found 
DEBU[0000] Have U-Boot variable: mender_check_saveenv_canary=1 
DEBU[0000] List of U-Boot variables:map[mender_check_saveenv_canary:1] 
DEBU[0000] Tried command "grub-mender-grubenv-print", but it was not found 
DEBU[0000] Tried command "systemd-boot-printenv", but it was not found 
DEBU[0000] Have U-Boot variable: mender_saveenv_canary=1 
DEBU[0000] List of U-Boot variables:map[mender_saveenv_canary:1] 
DEBU[0000] Tried command "grub-mender-grubenv-print", but it was not found 
DEBU[0000] Tried command "systemd-boot-printenv", but it was not found 
DEBU[0000] Have U-Boot variable: mender_boot_part=0     
DEBU[0000] List of U-Boot variables:map[mender_boot_part:0] 
WARN[0000] Could not resolve path link: overlay:user Attempting to continue 
DEBU[0000] Setting active partition from configuration and environment: ubi0_0 
INFO[0000] Mender running on partition: ubi0_0          
DEBU[0000] ModuleTimeoutSeconds not set. Defaulting to 14400 seconds 
DEBU[0000] Starting device update.                      
INFO[0000] Performing remote update from: [http://artifact-url.mender]. 
DEBU[0000] Client initialized. Start downloading image. 
DEBU[0000] Received fetch update response &{200 OK 200 HTTP/1.1 1 1 map[Accept-Ranges:[bytes] Content-Length:[84441600] Date:[Mon, 02 Dec 2024 14:58:13 GMT] Etag:["5087a00-6284ac37e6a68"] Last-Modified:[Mon, 02 Dec 2024 14:57:12 GMT] Server:[Apache/2.4.58 (Unix)]] 0x100f740 84441600 [] false false map[] 0x1098680 <nil>}+ 
DEBU[0000] Image downloaded: 84441600 [&{0x100f740 0x1146220 0x1098600 0 84441600 0 0}] [<nil>] 
Installing Artifact of size 84441600...
DEBU[0000] Reading data from the device manifest file: /var/lib/mender/device_type 
DEBU[0000] device_type=l1                               
DEBU[0000] Current manifest data: l1                    
DEBU[0000] statescript: The timeout for executing scripts is not defined; using default of 1h0m0s seconds 
INFO[0000] No public key was provided for authenticating the artifact 
INFO[0000] Update Module path "/usr/share/mender/modules/v3" could not be opened (open /usr/share/mender/modules/v3: no such file or directory). Update modules will not be available 
DEBU[0000] Checking if device [l1] is on compatible device list: [l1] 
DEBU[0000] Installer: Successfully read artifact [name: artifact-name; version: 3; compatible devices: [l1]] 
WARN[0000] Returning artifact name from /etc/mender/artifact_info file. This is a fallback, in case the information can not be retrieved from the database, and is only expected when an update has never been installed before. 
DEBU[0000] Reading data from the device manifest file: /etc/mender/artifact_info 
DEBU[0000] artifact_name=artifact-name        
DEBU[0000] Current manifest data: artifact-name 
DEBU[0000] Active partition: ubi0_0                     
DEBU[0000] Detected inactive partition ubi0_1, based on active partition ubi0_0 
INFO[0000] Opening device "ubi0_1" for writing          
DEBU[0000] Installing update of size: 105771008         
DEBU[0000] Device: ubi0_1 is a ubi device: true         
INFO[0000] Native sector size of block device /dev/ubi0_1 is 126976 bytes. Mender will write in chunks of 2031616 bytes 
DEBU[0000] Opening device: /dev/ubi0_1 for writing with flag: 1 
.............................................................. - 100 %
INFO[0082] All bytes were successfully written to the new partition 
INFO[0082] Wrote 105771008/105771008 bytes to the inactive partition 
DEBU[0082] statescript: The timeout for executing scripts is not defined; using default of 1h0m0s seconds 
DEBU[0082] statescript: The timeout for executing scripts is not defined; using default of 1h0m0s seconds 
DEBU[0082] Inactive partition: ubi0_1                   
INFO[0082] Enabling partition with new image installed to be a boot candidate: 1 
DEBU[0082] Tried command "grub-mender-grubenv-print", but it was not found 
DEBU[0082] Tried command "systemd-boot-printenv", but it was not found 
DEBU[0082] Have U-Boot variable: mender_check_saveenv_canary=1 
DEBU[0082] List of U-Boot variables:map[mender_check_saveenv_canary:1] 
DEBU[0082] Tried command "grub-mender-grubenv-print", but it was not found 
DEBU[0082] Tried command "systemd-boot-printenv", but it was not found 
DEBU[0082] Have U-Boot variable: mender_saveenv_canary=1 
DEBU[0082] List of U-Boot variables:map[mender_saveenv_canary:1] 
DEBU[0082] Probing the Bootloader environment for which separator to use 
DEBU[0082] Writing map[mender_uboot_separator:1] to the U-Boot environment, using separator:   
DEBU[0082] Tried command "grub-mender-grubenv-set", but it was not found 
DEBU[0082] Tried command "systemd-boot-setenv", but it was not found 
DEBU[0082] Tried command "grub-mender-grubenv-print", but it was not found 
DEBU[0082] Tried command "systemd-boot-printenv", but it was not found 
DEBU[0082] Have U-Boot variable: mender_check_saveenv_canary=1 
DEBU[0082] List of U-Boot variables:map[mender_check_saveenv_canary:1] 
DEBU[0082] Tried command "grub-mender-grubenv-print", but it was not found 
DEBU[0082] Tried command "systemd-boot-printenv", but it was not found 
DEBU[0083] Have U-Boot variable: mender_saveenv_canary=1 
DEBU[0083] List of U-Boot variables:map[mender_saveenv_canary:1] 
DEBU[0083] Tried command "grub-mender-grubenv-print", but it was not found 
DEBU[0083] Tried command "systemd-boot-printenv", but it was not found 
DEBU[0083] Have U-Boot variable: mender_uboot_separator= 
DEBU[0083] List of U-Boot variables:map[mender_uboot_separator:] 
DEBU[0083] Using (=) as the bootloader environment separator 
DEBU[0083] Writing map[bootcount:0 mender_boot_part:1 mender_boot_part_hex:1 upgrade_available:1] to the U-Boot environment, using separator: = 
DEBU[0083] Tried command "grub-mender-grubenv-set", but it was not found 
DEBU[0083] Tried command "systemd-boot-setenv", but it was not found 
DEBU[0083] Marking inactive partition as a boot candidate successful. 
DEBU[0083] statescript: The timeout for executing scripts is not defined; using default of 1h0m0s seconds 
Use 'commit' to update, or 'rollback' to roll back the update.
At least one payload requested a reboot of the device it updated.

>>> REBOOT <<<

sudo mender-update -l trace commit
record_id=1 severity=trace time="2024-Dec-02 15:11:13.777833" name="Global" msg="Entering state N6mender6update10standalone13JustSaveStateE" 
record_id=2 severity=trace time="2024-Dec-02 15:11:13.792937" name="Global" msg="Entering state N6mender6update10standalone17ScriptRunnerStateE" 
record_id=3 severity=trace time="2024-Dec-02 15:11:13.812646" name="Global" msg="Entering state N6mender6update10standalone21ArtifactRollbackStateE" 
record_id=4 severity=trace time="2024-Dec-02 15:11:15.138724" name="Global" msg="Entering state N6mender6update10standalone17ScriptRunnerStateE" 
record_id=5 severity=trace time="2024-Dec-02 15:11:15.149508" name="Global" msg="Entering state N6mender6update10standalone13JustSaveStateE" 
record_id=6 severity=trace time="2024-Dec-02 15:11:15.156323" name="Global" msg="Entering state N6mender6update10standalone17ScriptRunnerStateE" 
record_id=7 severity=trace time="2024-Dec-02 15:11:15.165562" name="Global" msg="Entering state N6mender6update10standalone20ArtifactFailureStateE" 
record_id=8 severity=trace time="2024-Dec-02 15:11:15.217239" name="Global" msg="Entering state N6mender6update10standalone17ScriptRunnerStateE" 
record_id=9 severity=trace time="2024-Dec-02 15:11:15.225529" name="Global" msg="Entering state N6mender6update10standalone13JustSaveStateE" 
record_id=10 severity=trace time="2024-Dec-02 15:11:15.233478" name="Global" msg="Entering state N6mender6update10standalone12CleanupStateE" 
record_id=11 severity=trace time="2024-Dec-02 15:11:15.291560" name="Global" msg="Entering state N6mender6update10standalone9ExitStateE" 
Rolled back.

My hypothesis is that there is some kind of bug here. Either it doesn’t detect correctly the state, either there is a missing error message indicating why it fails to commit.

How is the state determined ? Is it related to the storage? If it is, are there any tools to inspect the storage (lmdb) to compare the results of an install from 3.3 and 5.0 ?

Same is happening between v4 and v5:

$ sudo mender-update --version
4.0.4-dirty

$ sudo mender-update -l trace install http://artifact-url.mender
record_id=1 severity=debug time="2024-Dec-02 15:35:01.552291" name="Global" msg="No Bootstrap Artifact found at: /var/lib/mender/bootstrap.mender" 
record_id=2 severity=trace time="2024-Dec-02 15:35:01.651387" name="Global" msg="URL broken down into (protocol: http), (host: fqdn.net), (port: 8080), (path: /artifact-path.mender),(username: ), (password: )" 
record_id=3 severity=trace time="2024-Dec-02 15:35:01.664129" name="Global" msg="Setting HOST address: fqdn.net:8080" 
record_id=4 severity=debug time="2024-Dec-02 15:35:01.698016" name="http_client" url="http://artifact-url.mender" msg="Hostname fqdn.net resolved to [<ipv4>, <ipv6>]" 
record_id=5 severity=debug time="2024-Dec-02 15:35:01.726541" name="http_client" url="http://artifact-url.mender" msg="Connected to <ipv4>" 
record_id=6 severity=trace time="2024-Dec-02 15:35:01.746869" name="http_client" url="http://artifact-url.mender" msg="Wrote 118 bytes of header data to stream." 
record_id=7 severity=trace time="2024-Dec-02 15:35:01.758497" name="http_client" url="http://artifact-url.mender" msg="Read 211 bytes of header data from stream." 
record_id=8 severity=debug time="2024-Dec-02 15:35:01.761796" name="http_client" url="http://artifact-url.mender" msg="Received response: 200 OK" 
record_id=9 severity=debug time="2024-Dec-02 15:35:01.767800" name="http_client" url="http://artifact-url.mender" msg="Received headers:
Date: Mon, 02 Dec 2024 15:35:01 GMT
Server: Apache/2.4.58 (Unix)
Last-Modified: Mon, 02 Dec 2024 15:22:33 GMT
ETag: "507dc00-6284b1e1c22a3"
Accept-Ranges: bytes
Content-Length: 84401152
" 
record_id=10 severity=trace time="2024-Dec-02 15:35:01.791520" name="http_client" url="http://artifact-url.mender" msg="Read 14269 bytes of body data from stream." 
record_id=11 severity=trace time="2024-Dec-02 15:35:01.802974" name="Global" msg="Entry name: version" 
record_id=12 severity=trace time="2024-Dec-02 15:35:01.806263" name="Global" msg="Parsing Version" 
record_id=13 severity=trace time="2024-Dec-02 15:35:01.811645" name="Global" msg="Parsing the Manifest" 
record_id=14 severity=trace time="2024-Dec-02 15:35:01.814922" name="Global" msg="Entry name: manifest" 
record_id=15 severity=trace time="2024-Dec-02 15:35:01.841550" name="Global" msg="Entry name: header.tar.gz" 
record_id=16 severity=trace time="2024-Dec-02 15:35:01.844805" name="Global" msg="Parsing the Header" 
record_id=17 severity=trace time="2024-Dec-02 15:35:01.855312" name="Global" msg="Entry name: header-info" 
record_id=18 severity=trace time="2024-Dec-02 15:35:01.858483" name="Global" msg="StringToType: header-info" 
record_id=19 severity=trace time="2024-Dec-02 15:35:01.863960" name="Global" msg="Parse(header-info)" 
record_id=20 severity=trace time="2024-Dec-02 15:35:01.867820" name="Global" msg="Parsing the payloads" 
record_id=21 severity=trace time="2024-Dec-02 15:35:01.870983" name="Global" msg="Parsing the header-info artifact_provides" 
record_id=22 severity=trace time="2024-Dec-02 15:35:01.874435" name="Global" msg="Parsing the header-info provides:artifact_name" 
record_id=23 severity=trace time="2024-Dec-02 15:35:01.876810" name="Global" msg="Parsing the header-info provides:artifact_group (if any)" 
record_id=24 severity=trace time="2024-Dec-02 15:35:01.879928" name="Global" msg="Parsing the header-info depends:artifact_depends (if any)" 
record_id=25 severity=trace time="2024-Dec-02 15:35:01.882727" name="Global" msg="Entry name: headers/0000/type-info" 
record_id=26 severity=trace time="2024-Dec-02 15:35:01.885827" name="Global" msg="StringToType: headers/0000/type-info" 
record_id=27 severity=trace time="2024-Dec-02 15:35:01.890468" name="Global" msg="Parsing the sub-header ..." 
record_id=28 severity=trace time="2024-Dec-02 15:35:01.894214" name="Global" msg="Parse(type-info)..." 
record_id=29 severity=trace time="2024-Dec-02 15:35:01.899348" name="Global" msg="type-info: Parsing the payload type" 
record_id=30 severity=trace time="2024-Dec-02 15:35:01.903375" name="Global" msg="type-info: Parsing the artifact_provides" 
record_id=31 severity=trace time="2024-Dec-02 15:35:01.906876" name="Global" msg="type-info: Parsing the artifact_depends" 
record_id=32 severity=trace time="2024-Dec-02 15:35:01.909963" name="Global" msg="No artifact_depends found in type-info" 
record_id=33 severity=trace time="2024-Dec-02 15:35:01.913265" name="Global" msg="type-info: Parsing the clears_artifact_provides" 
record_id=34 severity=trace time="2024-Dec-02 15:35:01.917518" name="Global" msg="Finished parsing the type-info.." 
record_id=35 severity=debug time="2024-Dec-02 15:35:01.921142" name="Global" msg="Setting the type-info in payload nr 0 to rootfs-image" 
record_id=36 severity=trace time="2024-Dec-02 15:35:01.924022" name="Global" msg="Entry name: headers/0000/meta-data" 
record_id=37 severity=trace time="2024-Dec-02 15:35:01.927663" name="Global" msg="StringToType: headers/0000/meta-data" 
record_id=38 severity=trace time="2024-Dec-02 15:35:01.934475" name="Global" msg="sub-header: looking for meta-data" 
record_id=39 severity=trace time="2024-Dec-02 15:35:01.937617" name="Global" msg="Parsing the header meta-data" 
record_id=40 severity=trace time="2024-Dec-02 15:35:01.953721" name="Global" msg="Received json load error: Failed to parse JSON from stream: [json.exception.parse_error.101] parse error at line 1, column 1: syntax error while parsing value - unexpected end of input; expected '[', '{', or a literal" 
record_id=41 severity=trace time="2024-Dec-02 15:35:01.956556" name="Global" msg="Received an empty Json body. Not treating this as an error" 
record_id=42 severity=trace time="2024-Dec-02 15:35:01.959478" name="Global" msg="sub-header: parsed the meta-data" 
Installing artifact...
record_id=43 severity=trace time="2024-Dec-02 15:35:02.009842" name="Global" msg="Entry name: data/0000.tar.gz" 
record_id=44 severity=trace time="2024-Dec-02 15:35:02.013224" name="Global" msg="Parsing the payload" 
record_id=45 severity=trace time="2024-Dec-02 15:35:02.017229" name="http_client" url="http://artifact-url.mender" msg="Read 16384 bytes of body data from stream." 
record_id=46 severity=debug time="2024-Dec-02 15:35:02.118929" name="Global" msg="Calling Update Module with command `/usr/share/mender/modules/v3/rootfs-image DownloadWithFileSizes /var/lib/mender/modules/v3/payloads/0000/tree`." 
0%record_id=47 severity=trace time="2024-Dec-02 15:35:03.069856" name="Global" msg="Wrote 16384 bytes to Update Module" 
...
100%record_id=11659 severity=trace time="2024-Dec-02 15:37:27.955050" name="Global" msg="Wrote 105897984 bytes to Update Module" 
100%record_id=11660 severity=debug time="2024-Dec-02 15:37:28.013539" name="Global" msg="Update Module finished all downloads" 
record_id=11661 severity=debug time="2024-Dec-02 15:37:28.027903" name="Global" msg="Found no state script directory (/var/lib/mender/scripts). Continuing on" 
record_id=11662 severity=debug time="2024-Dec-02 15:37:28.881407" name="Global" msg="Found no state script directory (/var/lib/mender/scripts). Continuing on" 
Installed, but not committed.
Use 'commit' to update, or 'rollback' to roll back the update.
At least one payload requested a reboot of the device it updated.

>>> REBOOT <<<

$ sudo mender-update --version
5.0.0-build6-dirty

$ sudo mender-update -l trace commit
record_id=1 severity=trace time="2024-Dec-02 15:42:20.350368" name="Global" msg="Entering state N6mender6update10standalone13JustSaveStateE" 
record_id=2 severity=trace time="2024-Dec-02 15:42:20.365370" name="Global" msg="Entering state N6mender6update10standalone17ScriptRunnerStateE" 
record_id=3 severity=debug time="2024-Dec-02 15:42:20.371415" name="Global" msg="Found no state script directory (/var/lib/mender/scripts). Continuing on" 
record_id=4 severity=trace time="2024-Dec-02 15:42:20.375556" name="Global" msg="Entering state N6mender6update10standalone21ArtifactRollbackStateE" 
record_id=5 severity=trace time="2024-Dec-02 15:42:21.765115" name="Global" msg="Entering state N6mender6update10standalone17ScriptRunnerStateE" 
record_id=6 severity=debug time="2024-Dec-02 15:42:21.768737" name="Global" msg="Found no state script directory (/var/lib/mender/scripts). Continuing on" 
record_id=7 severity=trace time="2024-Dec-02 15:42:21.771946" name="Global" msg="Entering state N6mender6update10standalone13JustSaveStateE" 
record_id=8 severity=trace time="2024-Dec-02 15:42:21.778268" name="Global" msg="Entering state N6mender6update10standalone17ScriptRunnerStateE" 
record_id=9 severity=debug time="2024-Dec-02 15:42:21.781668" name="Global" msg="Found no state script directory (/var/lib/mender/scripts). Continuing on" 
record_id=10 severity=trace time="2024-Dec-02 15:42:21.784895" name="Global" msg="Entering state N6mender6update10standalone20ArtifactFailureStateE" 
record_id=11 severity=trace time="2024-Dec-02 15:42:21.835647" name="Global" msg="Entering state N6mender6update10standalone17ScriptRunnerStateE" 
record_id=12 severity=debug time="2024-Dec-02 15:42:21.836533" name="Global" msg="Found no state script directory (/var/lib/mender/scripts). Continuing on" 
record_id=13 severity=trace time="2024-Dec-02 15:42:21.837234" name="Global" msg="Entering state N6mender6update10standalone13JustSaveStateE" 
record_id=14 severity=trace time="2024-Dec-02 15:42:21.841987" name="Global" msg="Entering state N6mender6update10standalone12CleanupStateE" 
record_id=15 severity=trace time="2024-Dec-02 15:42:21.912591" name="Global" msg="Entering state N6mender6update10standalone9ExitStateE" 
Rolled back.

Hi @Chris,

Right from looking at it, I don’t know. I’ll try to reproduce but not sure how fast I get to it, sorry - this week the Yocto Project Summit is happening. Also poked the devs, hopefully it rings a bell for them.

Last question for now, this is standalone mode, right?

Greetz,
Josef

Hi Josef,

Thanks for your support and time.

Yes it’s standalone. I did not yet give it a try through managed updates.

Hi @Chris and thank you for your report.

We seem to have a regression for standalone mode. I have reported it now in our bug tracking system and we will be working on a fix ASAP.

As Josef pointed out, this bug is not related to the major bump in the version. We do design Mender client exactly as you described in your original message: the “target” Mender shall understand the database state of the “origin” Mender and commit correctly.

I’ll ping you in the next release candidate for you to verify on your side :slight_smile:

Lluis

Hi Lluis,

Thanks for the update. I’m glad and relieved to hear that there are no planned breaking change about that.

Please let me know if your need any additional data or other kind of feedback.

By the way, is there an approximate ETA for v5 ?

Best regards,
Chris