# Disk Checker Disk benchmarking and latency visualization tool for fio and badblocks output. ## Features - Parse fio JSON+ latency CSV files - Generate histogram and CDF plots - REST API for remote benchmarking - Async job management for long-running benchmarks ## Installation ```bash git clone cd disk-checker python -m venv venv source venv/bin/activate pip install -e ".[dev]" ``` ## CLI Usage ```bash # Basic usage python -m disk_checker scan_latency.csv # With options python -m disk_checker scan_latency.csv --metric read_clat --unit ms --log-x # Generate CDF python -m disk_checker scan_latency.csv --cdf # View all metrics python -m disk_checker scan_latency.csv --all-metrics ``` ## API Usage ```bash # Start the server python -m disk_checker.scripts.serve --host 0.0.0.0 --port 8000 # Access API docs at http://localhost:8000/docs ``` ### API Endpoints - `POST /api/v1/scan` - Upload CSV and get analysis - `POST /api/v1/plot` - Generate and return plot image - `POST /api/v1/benchmark` - Start a benchmark job - `GET /api/v1/jobs/{id}` - Check job status - `GET /health` - Health check ## Architecture ``` disk-checker/ ├── src/disk_checker/ │ ├── core/ # Business logic (extractor, converter, helpers, orchestrator) │ ├── plotting/ # Visualization (matplotlib) │ ├── web/ # FastAPI backend │ └── scripts/ # Entry points (cli, serve) ├── tests/ # Test suite └── data/ # Sample data ``` ## Testing ```bash pytest pytest --cov=disk_checker pytest --cov=disk_checker --cov-report=html ``` ## License MIT