diff options
author | Maciej Kisielewski <maciej.kisielewski@canonical.com> | 2021-04-07 14:59:08 +0200 |
---|---|---|
committer | Maciej Kisielewski <maciej.kisielewski@canonical.com> | 2021-04-07 15:05:18 +0200 |
commit | 5c5f374c17d74c7a749d64c61cf4a6ae6e10d617 (patch) | |
tree | ee0d2cc543a3aa8ea88aab7d8e62bfe70eedb5c3 | |
parent | d6368d8712e8106902c7f9a9a8bf8cb0eecaf596 (diff) |
Add: configurable SSD disk read threshold
Instead of hardcoded 200 (MB/s) the disk_read_performance_test now checks for DISK_SSD_READ_PERF environment variable and uses that as a threshold for the read performance. If the variable is not present it will default to 200MB/s.
-rwxr-xr-x | bin/disk_read_performance_test.sh | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/bin/disk_read_performance_test.sh b/bin/disk_read_performance_test.sh index 48f25c0..f416466 100755 --- a/bin/disk_read_performance_test.sh +++ b/bin/disk_read_performance_test.sh @@ -7,6 +7,7 @@ DEFAULT_BUF_READ=${DISK_READ_PERF:-15} DEFAULT_NVME_READ=${DISK_NVME_READ_PERF:-200} DEFAULT_MDADM_READ=${DISK_MDADM_READ_PERF:-80} +DEFAULT_SSD_READ=${DISK_SSD_READ_PERF:-200} for disk in "$@"; do @@ -69,7 +70,7 @@ for disk in "$@"; do "mdadm" ) MIN_BUF_READ=$DEFAULT_MDADM_READ;; "ata" ) MIN_BUF_READ=80;; "scsi" ) MIN_BUF_READ=100;; - "ssd" ) MIN_BUF_READ=200;; + "ssd" ) MIN_BUF_READ=$DEFAULT_SSD_READ;; * ) MIN_BUF_READ=$DEFAULT_BUF_READ;; esac echo "INFO: $disk_type: Using $MIN_BUF_READ MB/sec as the minimum throughput speed" |