Boot Balena OS Generic x86_64 from USB alongside other OS

Hello,

A bit of context: we are (happily) using balena to run our software on Rasbperry. Up until now we ship the device + the system but we want to open-up our use-cases by letting people use their own computers. We hence investigated how we could switch part of our software to a generic x86_64 image. The idea was to provide an image that users could flash to a USB key, let them boot from the USB key to use our software, remove the USB key and get back to their regular system when they want to move to something else. Here we cannot expect users to have a dedicated computer to run balena since there is some dedicated hardware in the loop that is being used for different projects by the final users.

I did not find any specific information regarding the use of the generic x86_64 version. Long story short, I discovered the hard way that this balena image is not meant to run all by itself, but instead partition the drive of the host system (without any warnings or confirmation??) to install the image that will boot a “regular” balena. In a way it can make sense, but I clearly did not expect that. :scream_cat: If I missed the documentation, my bad; if there is none, there should be :wink:

Fast-forward a week and a tedious attempt to salvage my files (which brought some early linux installations memories), and I’m back to ask the proper way to to it

So, is there any way to achieve the desired setup, where balena x86_64 nicely boots from USB, without touching anything else? At this stage it would be okay if we need to prepare a full image for each target computer.

Hi Jeremy, sure, running balenaOS for the Generic x86_64 device types from a USB is supported. You just need to use the raw/direct image instead of the installer/flasher image.

The trick here is that the flasher images is the only one that balenaCloud provides, but it contains the raw image inside. You can use an unwrapping script to obtain the raw image, program that to a USB disk using Etcher and try it out.

Awesome, thanks for the tip, I’ll try that and report back in case some are curious about the results :slight_smile: