Skip to content

Commit

Permalink
Executing a first run without ignoring the output on disk tests (Bugf…
Browse files Browse the repository at this point in the history
…ix) (canonical#1592)

Executing a first run without ignoring the output on disk tests
  • Loading branch information
fernando79513 authored and eugene-yujinwu committed Dec 31, 2024
1 parent f27713b commit e9a2c14
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions providers/base/bin/disk_read_performance_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,12 @@ DEFAULT_SSD_READ=${DISK_SSD_READ_PERF:-200}
# Minimum size threshold in bytes (2MB)
MIN_SIZE_THRESHOLD=$((2 * 1024 * 1024))

# Check if there is at least one disk to test
if [ "$#" -lt 1 ]; then
echo "ERROR: No disks to test!"
exit 1
fi

for disk in "$@"; do

echo "Beginning $0 test for $disk"
Expand Down Expand Up @@ -86,6 +92,9 @@ for disk in "$@"; do
esac
echo "INFO: $disk_type: Using $MIN_BUF_READ MB/sec as the minimum throughput speed"
# Perform a test run of hdparm without hiding the output and exit if it fails
hdparm -t /dev/"$disk" || exit 1
max_speed=0
echo ""
echo "Beginning hdparm timing runs"
Expand Down

0 comments on commit e9a2c14

Please sign in to comment.