Obtaining minimega

There are two ways to get minimega: by downloading a pre-compiled binary distribution, or by building from source yourself. Using a binary distribution is more convenient, but building from source means you can get the most up-to-date development version if desired.

Binary distribution

minimega is available as a pre-built, x86-64 debian package, or as a standalone tarball. minimega has been tested on debian 7-9 and Ubuntu 18.04-22.04. For more information on system requirements and runtime dependencies, see Module 2 in the Tutorials section.

Current, stable release: Debian based system: minimega-2.9.deb

For other x86-64 systems, use the pre-built tarball: minimega-2.9-binaries.tar.gz

Simply unpack minimega and run it from the top level directory:

$ tar xzf minimega-2.9-binaries.tar.gz && cd minimega
$ ./bin/minimega

You may find it convenient to place the minimega directory in /opt.

For previous versions of minimega, visit our downloads page

Building from source

To build from source you will need Go (version 1.17 or newer) and libpcap headers. On a Debian-type system, you can install compile-time dependencies with:

$ apt-get install libpcap-dev

Having installed the dependencies, grab the minimega source:

$ git clone git@github.com:sandia-minimega/minimega.git
$ cd minimega

Next, check out the 2.9 release. If you wish to run the development version (“tip”) of minimega, skip this command.

$ git checkout 2.9

Finally, compile minimega:

$ ./scripts/all.bash

This will build and test each of the libraries and tools in the minimega distribution and create a bin/ sudirectory containing each of the minimega tools. If you have a Windows cross compiler for Go set up, it will also build windows binaries of several tools.

Deploying minimega

minimega is a single binary and needs no configuration files. However, because minimega makes use of external programs, you’ll need to have some things installed—see the section “System requirements and runtime dependencies” in Module 2 in the Tutorials section.

To deploy minimega to any number of nodes, simply copy the binary to each node. See the usage article for information about launching minimega.

Depending on your cluster configuration, it is also possible to have minimega deploy itself. By launching minimega on a single node, you can use the deploy API which will cause minimega to copy itself and run remotely using ssh on a provided list of nodes. See the API documentation on deploy for more information, or read the article on setting up a cluster.

Grub note

If you intend to run Linux containers, you need to have the memory cgroup enabled, but Debian (and some other distros) do not enable it by default. If you try to start a container and get an error, you may need to enable the memory cgroup.

To enable it, add the following to your kernel boot parameters:

cgroup_enable=memory

On Debian, you can do this by opening /etc/default/grub and adding that parameter to the GRUB_CMDLINE_LINUX_DEFAULT line. It should end up looking something like this:

GRUB_CMDLINE_LINUX_DEFAULT="quiet cgroup_enable=memory"

Then run update-grub and reboot for the change to take effect.