22 releases

0.0.22 Sep 10, 2020
0.0.20 May 14, 2020
0.0.18 Mar 29, 2020
0.0.6 Dec 16, 2019
0.0.5 Oct 30, 2019

#66 in Operating systems

Download history 19/week @ 2020-06-08 3/week @ 2020-06-15 6/week @ 2020-06-22 39/week @ 2020-06-29 30/week @ 2020-07-06 46/week @ 2020-07-13 28/week @ 2020-07-20 31/week @ 2020-07-27 32/week @ 2020-08-03 48/week @ 2020-08-10 23/week @ 2020-08-17 29/week @ 2020-08-24 54/week @ 2020-08-31 112/week @ 2020-09-07 29/week @ 2020-09-14 19/week @ 2020-09-21

172 downloads per month


6.5K SLoC

uhyve - A minimal hypervisor for RustyHermit

crates.io Actions Status Build Status Slack Status


uhyve is small hypervisor to boot the library operating systems RustyHermit, which is a unikernel operating system targeting a scalable and predictable runtime behavior for HPC and cloud environments.


An installation of the Rust toolchain is required. Please visit the Rust website and follow the installation instructions. The project can then be installed with the following command:

cargo install uhyve # Install latest published version from crates.io



To check if your system supports virtualization, you can use the following command:

if egrep -c '(vmx|svm)' /proc/cpuinfo > /dev/null; then echo "Virualization support found"; fi

On Linux, uhyve depends on the virtualization solution KVM (Kernel-based Virtual Machine). If the following command gives you some output, you are ready to go!

lsmod | grep kvm


Disclaimer: Currently, uhyve is mainly developed for Linux. The macOS version has not been tested extensively and does not support all features of the Linux version.

Apple's Command Line Tools must be installed. The following terminal command installs these tools without Apple's IDE Xcode:

xcode-select --install

Additionally, the included hypervisor bases on the Hypervisor Framework depending on OS X Yosemite (10.10) or newer. To verify if your processor is able to support this framework, run the following in your Terminal:

sysctl kern.hv_support

The output kern.hv_support: 1 indicates virtualization support.

Building from source

To build from souce, simply checkout the code and use cargo build.

git clone https://github.com/hermitcore/uhyve.git
cd uhyve
cargo build --release

Running RustyHermit apps within uhyve

Use the hypervisor to start the unikernel.

uhyve /path/to/the/unikernel/binary


uhyve can be configured via environment variables. The following variables are supported.

  • HERMIT_CPUS: specifies the number of cores the virtual machine may use.
  • HERMIT_MEM: defines the memory size of the virtual machine. The suffixes M and G can be used to specify a value in megabytes or gigabytes, respectively.
  • setting HERMIT_VERBOSE to 1 makes the hypervisor print kernel log messages to the terminal.
  • HERMIT_GDB_PORT=port activate a gdb server for the application running inside uhyve. See below

By default, the loader initializes a system with one core and 512 MiB RAM.

Example: the following command starts the demo application in a virtual machine, which has 4 cores and 8GiB memory:

HERMIT_CPUS=4 HERMIT_MEM=8G uhyve /path/to/the/unikernel/binary

Debugging of RustyHermit apps (unstable)

Basic support of (single-core) applications is already integrated into uhyve. By specifying variable HERMIT_GDB_PORT=port, uhyve is working as gdbserver and is waiting on port port for a connection to a gdb. For instance, with the following command uhyve is waiting on port 6677 for a connection.

HERMIT_GDB_PORT=6677 uhyve /path_to_the_unikernel/hello_world

In principle, every gdb-capable IDE should be able to debug RustyHermit applications. (Eclipse, VSCode, ...)

The repository rusty-hermit provides example configuration files to debug a RustyHermit application with Visual Code.

Debugging RustyHermit apps

Known issues

  • Uhyve isn't able to pass more than 128 environment variables to the unikernel


Licensed under either of

at your option.


Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.


~220K SLoC