The RT Container Test Framework is designed to validate runtime stability and deterministic execution behavior of containers running on a Linux PREEMPT_RT patched kernel.
This framework enables:
- Validation of container runtime behavior in RT environments
- Repeated execution stability testing
- Comparative testing between Docker and Podman
A Linux kernel patched with PREEMPT_RT is required for meaningful real-time performance validation.
uname -aExpected output should include:
PREEMPT_RTIf the RT flag is not present, the real-time test results will not be valid.
If you need an RT kernel image for Raspberry Pi, refer to:
https://github.com/ros-realtime/ros-realtime-rpi4-image
CPU isolation improves test reliability by reducing interference from system processes.
Edit GRUB configuration:
sudo vi /etc/default/grubModify the following line:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash threadirqs isolcpus=3 nohz_full=3 rcu_nocbs=3 irqaffinity=0-2"Apply changes:
sudo update-grub
sudo rebootsudo vi /boot/firmware/cmdline.txtconsole=serial0,115200 dwc_otg.lpm_enable=0 console=tty1 root=LABEL=writable rootfstype=ext4 rootwait fixrtc quiet splash isolcpus=3 nohz_full=3 rcu_nocbs=3 irqaffinity=0-2 threadirqssudo vi /etc/security/limits.d/20-ubuntu-rt.conf* - rtprio 99
* - memlock unlimitedAt least one container engine must be installed:
- Docker
- Podman
Verify installation:
docker --versionor
podman --versionhost
container
├── dockerfiles
│ └── rt_test
│ └── Dockerfile.rt_test
├── scripts
│ ├── env
│ │ └── env_build.sh
│ ├── run.sh
│ ├── setup
│ │ ├── docker.sh
│ │ └── podman.sh
│ └── test
│ ├── entry
│ │ └── rt_test.sh
│ └── test.sh
└── test.sh
./test.sh <test-count> <engine1> <engine2> ..../test.sh 3 docker podmanMeaning:
- Run 3 iterations per engine
- Execute tests for Docker and Podman
./scripts/run.sh <engine> rt_test ./dockerfiles/rt_test <result-dir> <cyclic-test-loop-count> rt_test.sh [cpu-list]| Parameter | Description |
|---|---|
| engine | docker or podman |
| image-name | Container image name |
| dockerfile-path | Path to Dockerfile directory |
| result-path | Directory for storing results |
| loop | Number of internal RT test iterations |
| test_script | Script executed inside the container |
Test results are stored per engine:
~/rt/test/container/results/docker/
~/rt/test/container/results/podman/