IO_performance test allows you to run load testing of I/O. The test itself is a docker container. The container is flexible in settings for launching and building results and can accept environment variables described below as input.
Environment parameters that this container can accept.
- GIT_REPO - Is the login/name of the repository without .git. For example "lf-edge/eve-performance", and the result will be as follows: "github.com/lf-edge/eve-performance".
- GIT_LOGIN - Username on GitHub, where the repository specified in GIT_REPO is located.
- GIT_TOKEN - GitHub token for authorization and adding a branch with results to your repository.
- GIT_BRANCH - Branch name for results pushing. Optional parameter.
- GIT_PATH - Path for placing results in the git repository. The path must already exist in the repository. Optional parameter.
- GIT_FOLDER - Folder name for results on GitHub. Optional parameter.
- EVE_VERSION - EVE version. This parameter is required for naming a folder in GitHub. Optional parameter.
- GIT_LOCAL - Allows you to save test results to the volume passed to the container, via the -v parameter, without publishing the results to GitHub. This parameter can take the value - true. It is an optional parameter.
If you want to upload results to GitHub.com, the GIT_REPO GIT_LOGIN GIT_TOKEN environment variables will be required. All other environment variables for GitHub are optional. Before starting the container, you need to get a token on GitHub.com.
In this configuration, the test results will be posted to the GitHub repository (based on the specified parameters for the environment variables GIT_REPO, GIT_LOGIN, GIT_TOKEN, and others). The results catalog has the following structure:
- FIO-tests-%date-eve-version
- README.md
- SUMMARY.csv
- Configs
- config.fio
- Test-results
- fio-results
- Iostat
- FIO_OPTYPE - Determining the type of operation. Default=read,write. Optional parameter. For example: read,write,randread
- FIO_BS - Determining the block size. Default=4k,64k,1m. Optional parameter. For example: 4k,1m
- FIO_JOBS - Determining the count jobs in test. Optional parameter. Default=1,8. For example: 1
- FIO_DEPTH - Determining the io depth in test. Optional parameter. Default=1,8,16. For example: 1,8,32
- FIO_TIME - Duration of each test in sec. Default=60. Optional parameter. For example: 60
- FIO_CHECKSUMM - Checking the integrity of the recorded data. It takes only one of the following parameters: md5, crc64, crc32c, crc32, crc16, crc7, xxhash, sha512, sha256, sha1. For example: md5. When setting this parameter, you should use only one pattern - write or randwrite. And also one value of the iodepth, block size, and the count of threads. For instance: (FIO_OPTYPE=write, FIO_BS=4k, FIO_JOBS=1, FIO_DEPTH=32, FIO_CHECKSUMM=md5).
According to these variables, the container generates a configuration file for the FIO utility. If no variables are set, a configuration file with default settings will be compiled.
To run the test without specifying additional parameters, run the following command (In this case, the output of the results will be displayed in the container console):
docker run lfedge/eden-fio-tests:83cfe07
To run tests and upload results to GitHub, or configure the FIO utility, you need to start the container by passing the necessary environment variables to it:
sudo docker run -e GIT_REPO='git_repository_name' -e GIT_LOGIN='your_git_login' -e GIT_TOKEN='your_git_token' -e GIT_BRANCH='fio_results' lfedge/eden-fio-tests:83cfe07
You can also write all the environment variables you need to a file and pass them to the container via the --env-file option. You can find more information at docs.docker.com.
If you want to store the test results on the volume passed to the container, you need:
- Specify the -v parameter, which will take 2 values: the path to a directory or file that will act as a volume in the container, and the mount point in the container itself. The mount point must always be located along the path - /data.
- You also need to pass the GIT_LOCAL environment variable (with the value true), it will save the result.
- All other environment variables are added optionally.
docker run -v ~/home/fio_results:/data -e GIT_LOCAL=true lfedge/eden-fio-tests:83cfe07
After executing this command, the test results will be saved in the directory - ~/home/fio_results
Over time, the version of the container may be updated
./eden pod deploy --metadata="EVE_VERSION=$(./eden config get --key=eve.tag)\nGIT_REPO=<git repository name>\nGIT_LOGIN=<your git login>\nGIT_TOKEN=<your git token>" -p 8029:80 docker://lfedge/eden-fio-tests:83cfe07
Note that the environment variables were also specified here.
This test creates a virtual machine and starts testing.
GIT_REPO=<git repository name> GIT_LOGIN=<your git login> GIT_TOKEN=<your git token> ./eden test ./tests/io_performance
Before running the test, you need to add environmental variables: GIT_REPO, GIT_LOGIN, GIT_TOKEN.