https://github.com/ivotron/docker-mica
Microarchitecture-independent profiling of containerized processes
https://github.com/ivotron/docker-mica
Last synced: about 2 months ago
JSON representation
Microarchitecture-independent profiling of containerized processes
- Host: GitHub
- URL: https://github.com/ivotron/docker-mica
- Owner: ivotron
- Created: 2016-01-07T23:11:25.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2016-01-09T10:00:46.000Z (over 10 years ago)
- Last Synced: 2025-06-13T18:07:24.576Z (12 months ago)
- Language: Python
- Homepage:
- Size: 13.7 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# MICA within docker
Leverages [mica](https://github.com/boegel/MICA) (and
[pin](https://software.intel.com/en-us/articles/pintool)) to profile a
process within a docker container.
To profile:
```bash
./profile \
-r \
-i
-f
-p
-c
-n
```
Arguments:
* `r` - whether to recompile MICA. When given, `gcc`, `g++`, and
`make` should be available inside the container.
* `i` - image name.
* `f` - flags to be passed to `docker run`.
* `p` - any commands that are executed prior to the one given in
`-c`, which are _not_ profiled. This **shouldn't** execute `cd`.
* `c` - command to execute and profile.
* `n` - name to associate to the output
For example, to profile `ls`:
```bash
./profile -i debian:jessie \
-f "--rm --net=host" \
-p "sleep 5" \
-c ls \
-n ls
```
For an example of the output generated (stored in `output.csv`) see
the [`examples/output_ls.csv`](examples/output_ls.csv) file. For a
description of each column, refer to the mica
[documentation](https://github.com/boegel/MICA/).
If the `output.csv` file exists, `profile` won't rewrite it; it will
append rows to it instead.
## Requirements
* Same requirements as pin/mica: Linux 2.6/3.x, `gcc` 3.4+,
single-threaded x86_64 applications.
* [`jq`](https://stedolan.github.io/jq/) 1.5+
* Only tested on debian/ubuntu-based docker images.