Preflight check tool
The preflight check tool is a collection of tests that can be run on a DataStax Enterprise node to detect and fix node configurations. The tool can detect and optionally fix many invalid or suboptimal configuration settings, such as user resource limits, swap, and disk settings.
The default location of the preflight check tool depends on the type of installation:
sudo ./preflight_check [-h] [-f] [--yaml=<yaml_location>] [--devices=<HDD_devices>] [--disk-duration=<disk_duration_in_seconds>] [--disk-threads=<disk_threads>] [--ssd=SSD_devices] [--nossd]
Run the preflight check without options to run all tests.
The short form and long form parameters are comma-separated.
Comma separated lists of HDDs: /dev/sda,/dev/sdb,…
Time (in seconds) for each test disk benchmark. Set to simulate a normal load.
Number of threads for each disk benchmark. Set to simulate a normal load.
- -f, -fix
Attempt to fix issues.
- -h, -help
Show help and exit.
The node does not have SSDs.
Comma separated lists of SSDs:
INFO Blockdev readahead values are within reason. INFO vm.max_map_count set correctly. INFO Limits were correctly setup. INFO '/etc/security/limits.d/90-nproc.conf' does not exist. Shouldn't need this fix. WARNING Use --ssd or --nossd to signal ssd usage. ERROR SSD check did not complete successfully. INFO Swap disabled. WARNING Please ensure '/var/lib/cassandra/data' and '/var/lib/cassandra/commitlog' are linked to seperate devices. ERROR Yaml check did not complete successfully. WARNING Use --device to signal devices to benchmark. ERROR Disk benchmarks check did not complete successfully.
Create a custom preflight check to detect and fix specified configuration settings on DataStax Enterprise nodes.
Create a new Python file in /checks:
Add the new test to the
allsection of /checks/init.py:
__all__ = ['my_test', 'disk', 'blockdev', ...]
Add your test to the preflight_check script.
Run the preflight check script with the new test:
sudo ./preflight_check [ options ]