0x0i.phoronix
Ansible Role: Phoronix
Table of Contents
- Supported Platforms
- Requirements
- Role Variables
- Dependencies
- Example Playbook
- License
- Author Information
This Ansible role sets up and configures the Phoronix Test Suite (PTS), a flexible platform for testing and benchmarking various hardware and software.
Supported Platforms:
* Redhat (CentOS/Fedora)
* Ubuntu
Requirements
You need to have the unzip/gtar
tool installed on the target machine. For more info, check the ansible unarchive
module notes.
Role Variables
Variables are sorted by the following software installation steps:
- install
- config
- launch
- uninstall
Install
You can customize the following variables to control the installation process, such as the package version or the type of software to install:
install_type: <package | archive>
(default: archive)
- package: Installs PTS from the package management repository on Debian or Redhat systems.
package_name: <package-name-and-version>
(default: phoronix-test-suite[-latest])
- Specify the phoronix-test-suite package name and version to install. You can find available packages by checking online or using the terminal command
dnf --showduplicates list phoronix-test-suite
.
install_dir: </path/to/installation/dir>
(default: /opt/phoronix
)
- The directory where
PTS
will be installed. This is important when using archive.
archive_url: <path-or-url-to-archive>
(default: check defaults/main.yml
)
- The location of the compressed archive containing
ansible
binaries for installation. This is used only wheninstall_type
is set to archive.
inspect_system: <true | false>
(default: true)
- Whether to collect system information about the target host, including system details, sensor capabilities, and network settings.
Config
...description of configuration related vars...
Launch
In autopilot
mode ONLY, you can run PTS test suites using the systemd service management tool. Each test can run in the background based on configurations and can operate either simultaneously or in order.
You can adjust these variables to manage how tests are run.
default_run_asynchronous: <true | false>
(default: false)
- If set to true, tests will run in parallel by default; otherwise, they will run one after the other.
default_autopilot: <true | false>
(default: false)
- Automatically runs tests and reports results by default if set to true.
[user_configs: <config-entry>: test_runs: <test-entry>:] unit_properties: <hash>
(default: {}
)
- Defines settings to customize how the
test run
interacts with thesystemd
service.
Example
user_configs:
- user: devops
config:
BatchMode:
SaveResults: true
test_runs:
- name: pts/compress-gzip
runtime_config:
test_results_name: test-compress-results
unit_properties:
Restart: on-failure
ExecReload: phoronix-test-suite finish-run test-compress-results
ExecStopPre: /usr/bin/test_post_exec.sh test-compress-results
ExecStopPost: "aws s3 cp /opt/phoronix/test-compress-results.results.json s3://benchmark_results/"
Uninstall
You can uninstall PTS and clean up your system with the following variable:
perform_uninstall: <true | false>
(default: false
)
- Set this to true to remove all traces of the
phoronix-test-suite
installation.
Dependencies
0x0i.systemd
Example Playbook
default example:
- hosts: benchmark-nodes
roles:
- role: 0x0I.phoronix
License
MIT
Author Information
This role was created in 2019 by O1.IO.
phoronix-test-suite, a comprehensive testing and benchmarking platform
ansible-galaxy install 0x0i.phoronix