we tried a deployment to a group of devices and got a failure with no option for log output.
Reading the journal from that device we repeatedly see these lines:
Dec 27 13:30:17 hostname mender[283]: time="2021-12-27T13:30:17Z" level=info msg="State transition: update-retry-report [none] -> update-status-report [none]"
Dec 27 13:30:20 hostname mender[283]: time="2021-12-27T13:30:20Z" level=error msg="Got unexpected HTTP status when uploading log: 400"
Dec 27 13:30:20 hostname mender[283]: time="2021-12-27T13:30:20Z" level=error msg="error uploading logs: (request_id: ): uploading logs failed, bad status 400 server error message: no messages: invalid deployment log"
Dec 27 13:30:20 hostname mender[283]: time="2021-12-27T13:30:20Z" level=error msg="Failed to report deployment logs: transient error: (request_id: ): uploading logs failed, bad status 400 server error message: no messages: invalid deployment log"
Dec 27 13:30:20 hostname mender[283]: time="2021-12-27T13:30:20Z" level=error msg="Failed to send deployment logs to server: transient error: failed to send deployment logs: transient error: (request_id: ): uploading logs failed, bad status 400 server error message: no messages: invalid deployment log"
Dec 27 13:30:20 hostname mender[283]: time="2021-12-27T13:30:20Z" level=info msg="State transition: update-status-report [none] -> update-retry-report [none]"
We had an older mender artifact on site so we performed a manual mender install artifact.mender, all went well, rebooted to new partition, committed successfully but same errors appear and mender cloud still reports previous version.
The command echo string | nc hosted.mender.io 443 reports correctly 400 Bad Request as it should. Also nslookup seems fine:
Something possibly timed-out and did send correct inventory to server so we retried another manual install with that same old artifact and it did reboot ok and committed and updated the server fine but once we started another cloud based deployment we got an instant failure and journal reported this:
Dec 27 14:17:21 hostname mender[284]: time="2021-12-27T14:17:21Z" level=info msg="Forced wake-up from sleep"
Dec 27 14:17:21 hostname mender[284]: time="2021-12-27T14:17:21Z" level=info msg="Forcing state machine to: update-check"
Dec 27 14:17:21 hostname mender[284]: time="2021-12-27T14:17:21Z" level=info msg="State transition: check-wait [Idle] -> update-check [Sync]"
Dec 27 14:17:22 hostname mender[284]: time="2021-12-27T14:17:22Z" level=info msg="Correct request for getting image from: https://s3.amazonaws.com/hosted-mender-artifacts/5f4cabcfxxx200f34/ad9051f8-1ce1-4b9xxxafb052b?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAQWI2xxxLMYE2%2F20xxx227%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20211227T141722Z&X-Amz-Expires=86400&X-Amz-SignedHeaders=host&response-content-type=application%2Fvnd.mender-artifact&X-Amz-Signature=ee2a1984dxxx98f7e8e60e385a7c8bd0c467c3a2e2774e [name: base-1.0.0; devices: [ds-pi]]"
Dec 27 14:17:22 hostname mender[284]: time="2021-12-27T14:17:22Z" level=info msg="State transition: update-check [Sync] -> update-fetch [Download_Enter]"
Dec 27 14:17:22 hostname mender[284]: time="2021-12-27T14:17:22Z" level=info msg="State transition: update-fetch [Download_Enter] -> update-status-report [none]"
Dec 27 14:17:29 hostname mender[284]: time="2021-12-27T14:17:29Z" level=error msg="Got unexpected HTTP status when uploading log: 400"
Dec 27 14:17:29 hostname mender[284]: time="2021-12-27T14:17:29Z" level=error msg="error uploading logs: (request_id: ): uploading logs failed, bad status 400 server error message: no messages: invalid deployment log"
Dec 27 14:17:29 hostname mender[284]: time="2021-12-27T14:17:29Z" level=error msg="Failed to report deployment logs: transient error: (request_id: ): uploading logs failed, bad status 400 server error message: no messages: invalid deployment log"
Dec 27 14:17:29 hostname mender[284]: time="2021-12-27T14:17:29Z" level=error msg="Failed to send deployment logs to server: transient error: failed to send deployment logs: transient error: (request_id: ): uploading logs failed, bad status 400 server error message: no messages: invalid deployment log"
Dec 27 14:17:29 hostname mender[284]: time="2021-12-27T14:17:29Z" level=info msg="State transition: update-status-report [none] -> update-retry-report [none]"
Nothing found from the recent attempts. Actually only one log which seems to be when the problem started (but gone unnoticed until now) a few months ago:
There were about 200MB free.
Manual installation seemed to “fix” the problem, unfortunately without understanding the root cause.
Any extra troubleshooting you may need, I’ll be happy to help for the rest of the day as my holidays start tomorrow
I don’t see anything in the logs, which tells me anything other than that it did not have any deployment logs to upload, which is odd.
If you can get me a full log from an old deployment, the log from the passing one, and all the log files present in your data partition that would be a nice start
The reason there is no log in the UI is because the client does not upload any logs to the UI, and the deployments service returns the error No Messages.
But this is odd. And I’m not sure what to make of it right now, I will take a closer look at the client in the meantime.