ContainerTracer  0.1
ContainerTracer Documentation

한국어 링크

Introduction

Container Tracer is a tool that measures I/O performance per container. This program complements lacks of cgroup and container building sequence the existing I/O performance measurement program like fio and filebench.

Currently, Container Tracer uses trace-replay to measure the I/O performance of each container.

Execution Sample

Recommended system requirements

This program can run on the system which follows the POSIX standards.

But in these documents and our testing was based on the system which is described in the following table.

So, when you build and run this program you have to care about this information.

item content
Operting System Ubuntu 18.04
Kernel linux 4.19

Project Components

The composition of the project is as follows.

runner directory subdirectory test has unit-test program of each driver of runner.

Implementation

You have to check this link

Building

In common, you must do the following.

sudo pip3 install black flake8
sudo apt install doxygen

web

Since we are using Flask, you must install Flask and install the related package first.

sudo pip3 install flask flask_restful flask_socketio

And you can run this program with the following command in the project root directory.

sudo python web/run.py

You can get more information from this link.

trace-replay and runner

You download the source code and install necessary programs and libraries following.

Debian

sudo pip3 install scons scons-compiledb
sudo pip3 install clang-format
sudo apt install cppcheck libaio-dev libjson-c-dev libjemalloc-dev

Redhat

sudo yum install cppcheck libaio-devel json-c-devel jemalloc-devel

If you want to build by clang compiler then you must change the SConstruct file's CC section' gcc to clang and follow like below.

Debian

sudo apt install llvm-6.0 clang-6.0 libclang-6.0-dev
sudo ln -s /usr/bin/clang-6.0 /usr/bin/clang

Redhat

sudo yum install llvm6.0 clang7.0-devel clang7.0-libs

Based on the following commands you do the build and unit testing. This execution results are stored in ./build/debug.

sudo scons -c
sudo scons test DEBUG=True TARGET_DEVICE=<your device>

If you want to build the release mode then you do the following. This execution results are stored in ./build/release

sudo scons -c
scons

Moreover, you can install the release mode of runner libraries by following commands. If you want to install the debug mode then just change the sudo scons install to sudo scons DEBUG=True install

sudo scons install
sudo ldconfig

Under the redhat distribution, you must care about two things.

First, you have to check /etc/ld.so.conf file has the line /usr/local/lib. If not you add that line.

Second, if you encounter an error that related to the jemalloc you must build the jemalloc library based on this link.

Additionally, you can get information about how to make the driver program of the runner from this link

Notes

Warning

  1. Because the trace-replay does direct-IO, this may be destructing your disk's file system. So, you must run this program under an empty disk or virtual disk.
  2. You must follow the init JSON contents must be {"driver": "<DRIVER-NAME>", "setting": {...}}. And setting field has driver dependant contents.

Libraries

  1. pthread: POSIX thread library for trace-replay
  2. AIO: asynchronous I/O library
  3. rt: Real-Time library
  4. json-c: Json library for C language
  5. unity: Unit test library for C language
  6. jemalloc: A library which does the efficient memory dynamic allocation.

Contributing

You must follow the contributing rules in https://github.com/I-O-Benchmark-On-Container/ContainerTracer/blob/master/CONTRIBUTING.md "this link".