Yocto vs. Ubuntu – the operating systems in comparison
Overview: Operating system
A key decision in the development of IoT projects and edge infrastructures concerns software and, related to this, the choice of a suitable operating system. An operating system is a low-level system software that manages the computer’s hardware and software resources and greatly facilitates the computer’s basic functions, such as resource management, memory management, control of peripheral devices and networking. The operating system serves as the interface between the computer’s hardware and software and is therefore an important component of a system. There are several operating systems available on the market, with Microsoft Windows being the best known in the desktop environment. If one leaves the area of desktop computers, operating systems based on the Linux kernel are often used.
Open-source operating system: Linux
Linux is a group of Unix-like operating systems built on the Linux kernel. It belongs to the family of free and open source software and is usually available free of charge in a Linux distribution such as Ubuntu. A Linux distribution is a selection of certain software and a kernel of Linux that are coordinated with each other to form a usable operating system. It is most commonly used for servers and embedded systems, but is also available in a desktop version. Since Linux is open source, it can even be viewed and verified at the kernel level. Edge computing and IoT often involve embedded systems, so hardware and software must be integrated accordingly according to individual requirements. For this, Linux is the best option because it allows basic drivers to be written at kernel level to meet these needs.
Especially in the world of embedded systems, the size of a full Ubuntu distribution can be enough to severely limit the board’s limited memory before you can even start installing additional software or collecting data. So when it comes to data-intensive applications, an operating system with a small footprint is needed. This is where Yocto comes in: the goal of the Yocto project is to provide optimised software for highly specific embedded applications.
Yocto and the difference to Ubuntu
First, it is important to understand that Yocto is not a Linux distribution. In fact, the Yocto project website states, “It’s not an embedded Linux distribution, it creates its own.” In contrast, Ubuntu is a full Linux distribution for general computing purposes. Because Ubuntu and other Debian-based distributions are geared towards general computing and programming purposes, they are a good choice for a development environment where code may need to be changed and prototypes changed often.
Yocto allows the size of the operating system to be reduced to what is necessary to run the system. Yocto is modular and requires an SDK to build a distribution. In this, Yocto is more commonly referred to as a meta-distribution and can be seen as a collection of libraries, dependencies, configuration values and classes that are put together to create a custom Linux runtime image.
The Yocto project is thus an open source collaborative project that helps developers create custom Linux-based systems regardless of hardware architecture. Yocto provides a flexible set of tools and a space where embedded developers worldwide can share technologies, software stacks, configurations and best practices to create custom Linux images for embedded and IoT devices or anywhere a custom Linux operating system is needed.
“Ubuntu as a tool can be categorised under Operating Systems, while Yocto is categorised under Infrastructure Build Tools.”
Often desktop environment
|≈ 2 GB
|Includes unneeded software packages
|Only necessary software packages included,
Lowest possible footprint
|Rapid prototyping, proof of concept during development
|Production-ready operating system for embedded systems
|Is already prepared for use
|Best results are achieved when everything is set up individually
|Easy handling by apt-get [package name] via console
|Requires a complete image rebuild and reinstallation
|The distribution component is already installed
Image creation is fast
|Provides the tool for incremental image creation
|Maintenance is done by the desktop community
Support and porting must be done manually if custom packages are used
|The Yocto project provides long-term support,
Layers may require some fixes and updates,
Designed for continuous integration
|Rollout / OTA updates
|High amount of data sent to devices in the field
High data consumption
|Low amount of data sent to devices in the field
Low data consumption
When it comes to a decision between Yocto or Ubuntu, the verdict should be pretty clear. If codes are being developed, a proof-of-concept is being created and early prototypes are being tested, Ubuntu should be used. If code is fully tested and a working prototype is to be tested on an embedded board, Yocto should be used as this offers advantages in terms of speed and memory.
Another point where the Yocto project comes out ahead is the ability to customise the size of the operating system. Especially with regard to device management solutions, which are used for remote updates of IoT and edge devices in the field, the amount of data to be transferred plays a major role. The footprint on the devices in the field can also be kept to a minimum. This means that the limited storage space is used efficiently and thus the resources of the devices in the field can be utilised to the full extent. Especially with a large number of devices, this leads to significant cost savings.