Hubris and Humility

The release of a small open-source operating system for deeply-embedded computer systems.

Bryan Cantrill
5 min readintermediate
--
View Original

Overview

The article discusses the development of Hubris, a new operating system designed by Oxide, focusing on its unique architecture and the decision to create it from scratch rather than using existing systems. It emphasizes the importance of a hardware root of trust, security, and robustness in embedded systems, alongside the introduction of Humility, a debugger designed to work with Hubris.

What You'll Learn

1

How to design a microkernel-based operating system for embedded systems

2

Why using Rust can enhance safety and isolation in system software

3

How to create a static task model to avoid dynamic resource exhaustion

Prerequisites & Requirements

  • Understanding of embedded systems and their constraints
  • Familiarity with Rust programming language(optional)

Key Questions Answered

What is the main purpose of the Hubris operating system?
Hubris is designed as an all-Rust, microkernel-based operating system that prioritizes safety and isolation, specifically tailored for embedded systems. It aims to address the limitations of existing operating systems by providing a static task model that eliminates dynamic resource exhaustion issues.
How does Hubris ensure task safety and resource availability?
Hubris specifies all tasks at build time, allowing the system to know in advance the resources required for each task. This design choice ensures that tasks can be safely restarted without the risk of resource exhaustion, as the necessary resources are guaranteed to be available.
What distinguishes Hubris from traditional operating systems?
Unlike traditional operating systems that dynamically create tasks at runtime, Hubris fully specifies tasks at build time, which enhances reliability and performance. This approach also allows for a more efficient use of resources, reducing failure modes associated with dynamic task creation.
What role does Humility play in the Hubris ecosystem?
Humility is a debugger developed to work alongside Hubris, designed to enhance the debugging experience and improve the overall quality of the system. It reflects the commitment to creating a robust and reliable operating environment for embedded systems.

Technologies & Tools

Some links below are affiliate links. We may earn a commission if you make a purchase.

Key Actionable Insights

1
Consider developing your own operating system if existing solutions do not meet your security and robustness requirements.
As demonstrated by the development of Hubris, creating a custom OS can allow for tailored solutions that address specific constraints, particularly in embedded systems.
2
Utilize a static task model in your system design to improve reliability and performance.
The Hubris approach shows that knowing all tasks at build time can mitigate issues related to dynamic resource allocation, which is crucial for embedded systems.
3
Leverage Rust's features to enhance memory safety in system software.
The article highlights how Rust's memory protection capabilities contribute to the overall safety and isolation of the Hubris operating system.

Common Pitfalls

1
Assuming existing operating systems will meet all embedded system requirements can lead to significant limitations.
This often occurs because traditional systems are designed with general-purpose use in mind, which may not account for the specific constraints of embedded environments.

Related Concepts

Embedded Systems
Microkernel Architecture
Static Vs Dynamic Resource Allocation