The common way to flash OS images to SD cards used to be “dd”. But you could potentially damage your system with a wrong command, it will not do verification after writing the firmware image, and it was not available in Windows, so people had to use Win32DiskImager, and last time I check it did not do verification either.
So Etcher, now called balenaEtcher, became a popular cross-operating systems tool to flash images for Raspberry Pi and other SBCs. It’s easy to use and does verification after flashing. However, the binary is rather large at around 130 MB, and the company started to show sponsors to fund the development of the program, and this was not to the liking of everyone.
During my review of CrowPi2 Raspberry Pi 4 laptop, I encountered an issue with balenaEtcher, which was quickly fixed once I updated the program to the latest version. But commenters pointed out there are now better tools including USBImager, a lightweight cross-platform tool with many of the same features as balenaEtcher.
USBImager is open source (MIT license), takes around 256KB of storage space, support verification, compressed files (gz, bz2, xz, zip), etc….
The table below compares USBImager to balenaEtcher and Win32DIskImager program.
|Description||balenaEtcher||WIN32 Disk Imager||USBImager|
|Windows||Windows 7 or greater||Windows XP or greater||Windows XP or greater|
|MacOSX ||✔||✗||✔ (10.14+)|
|Available on Raspberry Pi OS||✗||✗||✔|
|Program size ||130 MB||11.7 MB (Installer)||256 KB|
|Dependencies||lots, ~300 Mb||Qt, ~8 Mb||✗ none|
|Spyware-free and ad-free||✗||✔||✔|
|Guarantee on data writes||✗||✗||✔|
|Verify data written||✔||✗||✔|
|Raw write time||23:16||23:28||24:05|
|Compressed write time||01:12:51||✗||30:47|
You’ll find the source code, and binary image for Windows, Linux, Mac OS, and Raspberry Pi on Gitlab.
It looks great, so I’ve tried the latest version on Ubuntu 20.04:
sudo dpkg -i usbimager_1.0.4-amd64.deb
The file size is indeed 256KB:
ls -lh /usr/bin/usbimager
-rwxr-xr-x 1 jaufranc jaufranc 249K Jun 21 20:47 /usr/bin/usbimager
Let’s start the program. The user interface is really basic and simple with a browse file button, Write and Read buttons, a drop-down list to select a drive, and tick box to enable Verify and/or compress, buffer size selection from 1MB to 512MB, as well as a progress bar.
Let’s enlarge the window a bit, insert a MicroSD card in my PC taken from Raspberry Pi 4, and let’s try the Read function with Compress enabled.
This will create a bz2 compressed file save to the Desktop. I select another directory before clicking on Read, but the program ignored this meaning files will be saved to the Desktop directory by default. Nevermind I can always move the file later on, and the program did the job in about 33 minutes here.
Then I tried to flash an image compression with 7z. This won’t work USBImager only supports .gz, .bz2, .xz, and .zip compressed files. So instead, I just flashed the uncompressed image and it worked nicely.
I have a 2TB USB 3.0 hard drive connected to my laptop, and USBImager correctly filtered it only showing smaller removable drives. You may also want to check out the user manual for more options including the ability to flash an image to a microcontroller over serial and to learn how to build the program from source.
Jean-Luc started CNX Software in 2010 as a part-time endeavor, before quitting his job as a software engineering manager, and starting to write daily news, and reviews full time later in 2011.