Installation

Option 2: Install on user’s custom VM or directly on host OS

As described above, installation on user’s custom VM or directly on the host OS has several disadvantages. It is not convenient to manage the test environment compared to the option 1. For this option, it is recommended to install Ubuntu 20.04 LTS freshly inside the VM or as the host OS to avoid potential package conflicts. Currently, this option is not well-tested compared to the option 1.

  • Install essential packages required by the installer from your package management systems:

$ sudo apt update
$ sudo apt upgrade
$ sudo apt install git iperf iperf3 make pkg-config python3 python3-dev python3-pip sudo
  • Install ComNetsEmu with all dependencies:

$ cd $TOP_DIR/comnetsemu/util
$ bash ./install.sh -a

Option 3: Download the pre-built VM image

Only if the previous option does not suit you, please use this option. Because the VM image may not be updated frequently and you need to manually configure the VM for e.g. port forwarding, folder synchronization.

The VM image (comnetsemu.ova) for Virtualbox is uploaded to the Google cloud drive. Please verify the sha512sum with the given files in the folder.

The default account and password for the VM are both vagrant. There is no pre-configured root password. The vagrant user can run sudo command without password, so root password can be configured via sudo passwd if required.

For KVM user, you can convert the ova file to qcow2 file with following commands (Assume the file has the name some_name):

$ tar -xvf some_name.ova
$ qemu-img convert some_name.vmdk some_name.qcow2 -O qcow2

Post-Installation

MARK: ComNetsEmu is developed with Python3 (3.8). Please use python3 command to run examples or applications. Because the current master branch is still under heavy development, therefore this python3 package can be only installed from source using setuptools.

ComNetsEmu uses Docker containers to emulate network nodes. Some images are used to run hosts and app containers in examples and also applications. The Dockerfiles for external Docker hosts are located in ./test_containers.

These Docker images are built automatically when the Vagrant VM is created. The upgrade script of ComNetsEmu also rebuild them automatically.

If there is an error related to the test Docker images, they can be created also manually:

$ cd ./test_containers
# This script also removes all dangling images after build.
$ python ./build.py