Can't use Mender-Arrtifact to create a snapshot

I’m newbie in Mender and I’m in topic that create a snapshot using Mender-Artifact on Raspberry Pi 4 but I’m get an error like this when run Mender-Artifact command. Please help!!!
Thansk for reading


P/s I’m using Raspios-Buster-Lite-Armhf OS

1 Like

The precompiled mender-artifact binary is for x86_64 not Arm. It’s normally run on a development system running either MacOS or Linux. Is there reason you need to run it on the Raspberry Pi?

Drew

I’m trying to learn how to convert a current OS image so I can deploy to many devices using Pi and Mender Server. Is there any solutions for my problem???
Thanks

The main docs for that are here.

The alternative is to use the snapshot feature.

Can I upgrade my Pi to 64 bit kernel and use the old way to create snapshot? I mean that the beta 64 bit kernel of Raspberry Pi??

It’ll still be Arm64 no X86_64.

What do you mean by the “old way” to create a snapshot?

I mean that use Mender-Artifact to create a snapshot by following the guide in this links

But why do you want to do this on the Raspberry Pi itself? The mender-artifact binary that we provide is intended to run on your desktop/laptop build system.

Well, I just following the guide in Mender Docs. It said that I need a Raspberry Pi devices and Raspbian as Operating system

Right. That is the device that is being updated. The development of the images to run on those devices is handled by a separate development system. All the steps from here are expected to be run from your workstation.
Drew

I think i don’t get it. Can you explain more specific for me??? I want to create a golden image of my Raspbian OS on Raspberry Pi 4.Upload it to Mender Server and deploy to the device. All the steps from Mender Docs I run it on my Raspberry Pi 4. Thanks!!!

Then you want to use the snapshot feature.

But more likely what you want is to take your golden image, without any Mender integration, run it through our mender-convert utility to create the multiple partition image. I assume your existing image is a single partition (plus the boot) which we cannot use to do full robust updates. If you review sections 1-4 of our docs site, I think that will explain it all.

So now how can i create a golden image to deploy? I already tried the Snapshot feature and it still don’t work. I also try a System Updates Debian Family that you suggests but I still get the same error when i execute MenderArtifact command

The golden master is whatever you want to be installed on top of the base Raspbian. That’s really not a part of Mender. Our mender-convert utility works as a post-processing step.

Basically:

  1. Install Raspbian
  2. Boot Raspbian
  3. Add all your apps using APT or whatever other mechanism you need
  4. Power Down
  5. Move SDCard to desktop
  6. Use dd command to create an image file from the SDCard.

Drew

Well, I have deleted all and start over again and here are all steps I had do. Hope you can look over for me one more time. I’ll be much appreciated.

  1. I install a Raspbian OS by recommend in the Mender Docs and flash it into SD card using Win32DiskImager
  2. Insert it into a Raspberry Pi 4(Pi) and boot it, set up connection,language,etc.
  3. Copy the code from hosted Mender and run it on Pi like this
    After that I saw my device in Hosted Mender, and I accept it.
  4. I follow the Guide in Deploy a system update


and when I run the final command it get an error like this

It supposed to executed and after that I should have a “system-v1.mender” for me to upload to Hosted Mender right? Please tell me what I’ve done wrong

You are running steps on the Raspberry Pi that should be run on your development workstation. The mender-artifact binary you are using is compiled for X86 and not for ARM. Note that step 1 of our docs states that this should be done on your workstation. If you absolutely need to run the mender-artifact command on your Raspberry Pi you will need to build it yourself.

Thanks for all information and support Mr @drewmoseley. I was able to create a snapshot now. But now I have 2 more problem, I hope you can help me figure out
Here is my problem
In tab Dashboard, it show my device is connected but can’t deploy anything to my devices. I have checked Identity, MAC address, it all match with my device. Then, I dismiss my device and add it again to Hosted-Mender and the second problem is here. My device did not show up in Pending tab. I have logout my account, refresh page but is still the same. Do you have any suggest for me Mr @drewmoseley.

Can you provide more details? Screen shots of your devices tab, device details, releases tab and release details will be helpful.
Also how did you create the deployment and what happened with it? Do you have a deployment status window?

Of course Mr @drewmoseley I can provide it for you. Here is my info about my device Ip and Mac address
image
here is releases tab

I create the deployment by the option " Create a deployment "and after create is pending

On your raspberrypi terminal, what does the output of the following command show? If you can copy and paste the text rather than a screenshot that is much better.

$ sudo journalctl -u mender-client --no-pager

Drew