The disk performance of an Avamar client determines whether backups and restores complete in good time.
Various tools and utilities are available to check disk performance depending in Linux, some examples of which are provided below.
The iostat command
Iostat shows levels of disk activity on a system.
Use the
-x flag to give extended information as shown in the output below.
admin@linux:~/>: iostat -x
Linux 2.6.32.59-0.19.1.8590.0.PTF-default (linux) 02/13/16 _x86_64_
avg-cpu: %user %nice %system %iowait %steal %idle
2.53 0.57 1.11 1.35 0.00 94.45
Device: rrqm/s wrqm/s r/s w/s rsec/s wsec/s avgrq-sz avgqu-sz await svctm %util
sda 0.58 2.37 10.81 3.89 5159.38 584.63 390.61 0.16 10.76 1.59 2.34
sdb 0.04 0.00 10.04 0.43 4969.08 157.55 489.83 0.09 8.72 1.91 2.00
sdc 0.04 0.01 10.12 0.44 5006.44 161.46 489.32 0.10 9.16 1.88 1.99
The
%iowait and
%idle,
await and
%util values may be examined to learn if the I/O bandwidth of any disk is saturated.
- %iowait - Shows the percentage of time that the CPU or CPUs were idle during which the system had an outstanding disk I/O request.
- %idle - Shows the percentage of time that the CPU or CPUs were idle and the system did not have an outstanding disk I/O request
- await - The average time (in milliseconds) for I/O requests issued to the device to be served. This includes the time spent by the requests in queue, and the time spent servicing them.
- %util - Percentage of CPU time during which I/O requests were issued to the device (bandwidth utilization for the device). Device saturation occurs when this value is close to 100%.
The hdparm command: hdparm can be used for simple read performance testing. Below is an example where we run the command against the hardware device
/dev/sdc1.
#: hdparm -Tt /dev/sdc1
/dev/sdc1:
Timing cached reads: 12136 MB in 2.00 seconds = 6073.44 MB/sec
Timing buffered disk reads: 420 MB in 3.01 seconds = 139.69 MB/sec
Disk write performance testing with dd:
Here we use the "
dd" command to test how quickly data can be written to a target disk.
time sync; dd if=/dev/zero of=tempfile bs=1M count=4096; sync;rm tempfile
What does this command do?
a) Synchronize outstanding writes to the disk to ensure no data information interferes with the results.
b) Take zeroes from
/dev/zero and write them to the file
tempfile until the file is 4 GB in size.
c) Synchronize any outstanding writes to the disk.
d) Remove the file that we created.
The command output shows how quickly the system can write to disk. Example below.
real 0m1.435s
user 0m0.000s
sys 0m0.132s
4096+0 records in
4096+0 records out
4294967296 bytes (4.3 GB) copied, 3.0865 s, 1.4 GB/s