Skip to main content
  • Place orders quickly and easily
  • View orders and track your shipping status
  • Enjoy members-only rewards and discounts
  • Create and access a list of your products

Open Networking Hardware Diagnostic Guide October 2024

PDF

storagetool

The storagetool tests mounted storage media.

Tests

The tool searches for any device in /dev/hd*, sda, sdb, or sdc and tests using them. The tests are file-copy tests to the device in the mounted file system. The files are written, compared, and removed, leaving the file system as it was before the test. You can run more tests using the bonnie++ tool and the tool reads SMART data from the device using the smart option.

The standard test creates a directory on the file system, opens a file for write, copies the file, compares the files, and reports errors. The test repeats 10 times. After the test completes successfully, storagetool removes all the test files.

CLI options

DellEmc Diag - Storage Tool
version 1.1, x.xx.x.x-x
build, 2022/05/20,

Syntax: storagetool <option>
 Show the help-text:=
         storagetool --h                        (or)
         storagetool -h
 Mount usb device when inserted (mandatory):=
         storagetool --mountusb                 (or)
         storagetool -m
 Unmount usb device before removed (mandatory):=
         storagetool --unmountusb               (or)
         storagetool -u
 List devices:=
         storagetool --list                     (or)
         storagetool -l
 Test devices(empty for all):=
         storagetool --test [--dev=<device>]    (or)
         storagetool -t [-D <device>
 Get the smart status for a device
         storagetool --smart --dev=<device>     (or)
         storagetool -S -D <device>
 Execute repeatedly command by count:=
         storagetool --iteration=max/<count> [option1] [option2]...(or)
         storagetool -I max/<count> [option1] [option2]...
 Run the bonnie tools on the filesystems:=
         storagetool --bonnie                   (or)
         storagetool -B

Usage:
   -h, --h           Show the help text
   -m, --mountusb    Mount usb device when inserted (mandatory)
   -u, --unmountusb  Unmount usb device when inserted (mandatory)
   -l, --list        List all storage devices
   -S, --smart       Smart Status
   -D, --dev=        Device
   -T, --test        Test using the pre-programmed configuration or use supplied config
   -I, --iteration=  Iteration command execution
   -B, --bonnie      Run the bonnie tools on the filesystems

Output

root@dell-diag-os:~# storagetool --list
Mounted Filesystem Devices:
/dev/sda3 / ext4
root@dell-diag-os:~# 
root@dell-diag-os:~# storagetool --test --dev=/dev/sda3
Testing Storage Devices ....................... Passed
root@dell-diag-os:~#
root@dell-diag-os:~# storagetool --smart --dev=/dev/sda3
smartctl 6.2 2013-07-26 r3841 [x86_64-linux-3.15.10] (local build)
Copyright (C) 2002-13, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Device Model:     InnoDisk Corp. - mSATA 3IE
Serial Number:    20160119AA144700000F
Firmware Version: S141002c
User Capacity:    32,017,047,552 bytes [32.0 GB]
Sector Size:      512 bytes logical/physical
Rotation Rate:    Solid State Device
Device is:        Not in smartctl database [for details use: -P showall]
ATA Version is:   ACS-2 (minor revision not indicated)
SATA Version is:  SATA 3.0, 6.0 Gb/s (current: 6.0 Gb/s)
Local Time is:    Mon Jan  1 20:45:44 2001 UTC
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

=== START OF ENABLE/DISABLE COMMANDS SECTION ===
SMART Enabled.

=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED

General SMART Values:
Offline data collection status:  (0x00) Offline data collection activity
                                        was never started.
                                        Auto Offline Data Collection: Disabled.
Total time to complete Offline
data collection:                (   32) seconds.
Offline data collection
capabilities:                    (0x00)         Offline data collection not supported.
SMART capabilities:            (0x0003) Saves SMART data before entering
                                        power-saving mode.
                                        Supports SMART auto save timer.
Error logging capability:        (0x00) Error logging NOT supported.
                                        General Purpose Logging supported.
SCT capabilities:              (0x0039) SCT Status supported.
                                        SCT Error Recovery Control supported.
                                        SCT Feature Control supported.
                                        SCT Data Table supported.

SMART Attributes Data Structure revision number: 16
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  1 Raw_Read_Error_Rate     0x0000   000   000   000    Old_age   Offline      -       0
  2 Throughput_Performance  0x0000   000   000   000    Old_age   Offline      -       0
  3 Spin_Up_Time            0x0000   000   000   000    Old_age   Offline      -       0
  5 Reallocated_Sector_Ct   0x0002   100   100   000    Old_age   Always       -       0
  7 Unknown_SSD_Attribute   0x0000   000   000   000    Old_age   Offline      -       0
  8 Unknown_SSD_Attribute   0x0000   000   000   000    Old_age   Offline      -       0
  9 Power_On_Hours          0x0002   100   100   000    Old_age   Always       -       3289
 10 Unknown_SSD_Attribute   0x0000   000   000   000    Old_age   Offline      -       0
 12 Power_Cycle_Count       0x0002   100   100   000    Old_age   Always       -       205
168 Unknown_Attribute       0x0000   000   000   000    Old_age   Offline      -       0
169 Unknown_Attribute       0x0000   000   000   000    Old_age   Offline      -       0
175 Program_Fail_Count_Chip 0x0000   000   000   000    Old_age   Offline      -       0
192 Power-Off_Retract_Count 0x0000   000   000   000    Old_age   Offline      -       0
  1 Raw_Read_Error_Rate     0x0000   000   000   000    Old_age   Offline      -       2199023255552
197 Current_Pending_Sector  0x0000   000   000   000    Old_age   Offline      -       0
240 Unknown_SSD_Attribute   0x0000   000   000   000    Old_age   Offline      -       0
225 Unknown_SSD_Attribute   0x0000   000   000   000    Old_age   Offline      -       0
170 Unknown_Attribute       0x0003   100   100   ---    Pre-fail  Always       -       1966080
173 Unknown_Attribute       0x0002   100   100   ---    Old_age   Always       -       7602213
229 Unknown_Attribute       0x0002   100   100   ---    Old_age   Always       -       88470212370072
236 Unknown_Attribute       0x0002   100   100   ---    Old_age   Always       -       0
235 Unknown_Attribute       0x0002   100   000   ---    Old_age   Always       -       0
176 Erase_Fail_Count_Chip   0x0000   100   000   ---    Old_age   Offline      -       0

Read SMART Log Directory failed: scsi error aborted command

Read SMART Error Log failed: scsi error aborted command

Read SMART Self-test Log failed: scsi error aborted command

Selective Self-tests/Logging not supported

root@dell-diag-os:~#
root@dell-diag-os:~# storagetool --bonnie --dev=/dev/sda3
Using uid:0, gid:0.
Writing with putc()...done
Writing intelligently...done
Rewriting...done
Reading with getc()...done
Reading intelligently...done
start 'em...done...done...done...
Create files in sequential order...done.
Stat files in sequential order...done.
Delete files in sequential order...done.
Create files in random order...done.
Stat files in random order...done.
Delete files in random order...done.
Version  1.03       ------Sequential Output------ --Sequential Input- --Random-
                    -Per Chr- --Block-- -Rewrite- -Per Chr- --Block-- --Seeks--
Machine        Size K/sec %CP K/sec %CP K/sec %CP K/sec %CP K/sec %CP  /sec %CP
dell-diag-os   250M 27664  96 245045  62 +++++ +++ 31064 100 +++++ +++ +++++ +++
                    ------Sequential Create------ --------Random Create--------
                    -Create-- --Read--- -Delete-- -Create-- --Read--- -Delete--
              files  /sec %CP  /sec %CP  /sec %CP  /sec %CP  /sec %CP  /sec %CP
                 32 32494  97 +++++ +++ 31198  66 31739  92 +++++ +++ 26511  56
dell-diag-os,250M,27664,96,245045,62,+++++,+++,31064,100,+++++,+++,+++++,+++,32,32494,97,+++++,+++,31198,66,31739,92,+++++,+++,26511,56

smartctl

To get a usage summary, use the smartctl -h command.

root@dell-diag-os:/opt/dellemc/diag/bin# smartctl -h
smartctl 6.2 2013-07-26 r3841 [x86_64-linux-3.15.10] (local build)
Copyright (C) 2002-13, Bruce Allen, Christian Franke, www.smartmontools.org

Usage: smartctl [options] device

============================================ SHOW INFORMATION OPTIONS =====

  -h, --help, --usage
         Display this help and exit

  -V, --version, --copyright, --license
         Print license, copyright, and version information and exit

  -i, --info
         Show identity information for device

  --identify[=[w][nvb]]
         Show words and bits from IDENTIFY DEVICE data                (ATA)

  -g NAME, --get=NAME
        Get device setting: all, aam, apm, lookahead, security, wcache, rcache, wcreorder

  -a, --all
         Show all SMART information for device

  -x, --xall
         Show all information for device

  --scan
         Scan for devices

  --scan-open
         Scan for devices and try to open each device

================================== SMARTCTL RUN-TIME BEHAVIOR OPTIONS =====

  -q TYPE, --quietmode=TYPE                                           (ATA)
         Set smartctl quiet mode to one of: errorsonly, silent, noserial

  -d TYPE, --device=TYPE
         Specify device type to one of: ata, scsi, sat[,auto][,N][+TYPE], usbcypress[,X], usbjmicron[,p][,x][,N], usbsunplus, marvell, areca,N/E, 3ware,N, hpt,L/M/N, megaraid,N, cciss,N, auto, test

  -T TYPE, --tolerance=TYPE                                           (ATA)
         Tolerance: normal, conservative, permissive, verypermissive

  -b TYPE, --badsum=TYPE                                              (ATA)
         Set action on bad checksum to one of: warn, exit, ignore

  -r TYPE, --report=TYPE
         Report transactions (see man page)

  -n MODE, --nocheck=MODE                                             (ATA)
         No check if: never, sleep, standby, idle (see man page)

============================== DEVICE FEATURE ENABLE/DISABLE COMMANDS =====

  -s VALUE, --smart=VALUE
        Enable/disable SMART on device (on/off)

  -o VALUE, --offlineauto=VALUE                                       (ATA)
        Enable/disable automatic offline testing on device (on/off)

  -S VALUE, --saveauto=VALUE                                          (ATA)
        Enable/disable Attribute autosave on device (on/off)

  -s NAME[,VALUE], --set=NAME[,VALUE]
        Enable/disable/change device setting: aam,[N|off], apm,[N|off],
        lookahead,[on|off], security-freeze, standby,[N|off|now],
        wcache,[on|off], rcache,[on|off], wcreorder,[on|off]

======================================= READ AND DISPLAY DATA OPTIONS =====

  -H, --health
        Show device SMART health status

  -c, --capabilities                                                  (ATA)
        Show device SMART capabilities

  -A, --attributes
        Show device SMART vendor-specific Attributes and values

  -f FORMAT, --format=FORMAT                                          (ATA)
        Set output format for attributes: old, brief, hex[,id|val]

  -l TYPE, --log=TYPE
        Show device log. TYPE: error, selftest, selective, directory[,g|s],
                               xerror[,N][,error], xselftest[,N][,selftest],
                               background, sasphy[,reset], sataphy[,reset],
                               scttemp[sts,hist], scttempint,N[,p],
                               scterc[,N,M], devstat[,N], ssd,
                               gplog,N[,RANGE], smartlog,N[,RANGE]

  -v N,OPTION , --vendorattribute=N,OPTION                            (ATA)
        Set display OPTION for vendor Attribute N (see man page)

  -F TYPE, --firmwarebug=TYPE                                         (ATA)
        Use firmware bug workaround:
        none, nologdir, samsung, samsung2, samsung3, xerrorlba, swapid

  -P TYPE, --presets=TYPE                                             (ATA)
        Drive-specific presets: use, ignore, show, showall

  -B [+]FILE, --drivedb=[+]FILE                                       (ATA)
        Read and replace [add] drive database from FILE
        [default is +/usr/etc/smart_drivedb.h
         and then    /usr/share/smartmontools/drivedb.h]

============================================ DEVICE SELF-TEST OPTIONS =====

  -t TEST, --test=TEST
        Run test. TEST: offline, short, long, conveyance, force, vendor,N,
                        select,M-N, pending,N, afterselect,[on|off]

  -C, --captive
        Do test in captive mode (along with -t)

  -X, --abort
        Abort any non-captive test on device

=================================================== SMARTCTL EXAMPLES =====

  smartctl --all /dev/hda                    (Prints all SMART information)

  smartctl --smart=on --offlineauto=on --saveauto=on /dev/hda
                                              (Enables SMART on first disk)

  smartctl --test=long /dev/hda          (Executes extended disk self-test)

  smartctl --attributes --log=selftest --qu
MODE, --nocheck=MODE (ATA) No check if: never, sleep, standby, idle (see man page)
============== DEVICE FEATURE ENABLE/DISABLE COMMANDS =====

bonnie++

bonnie++ is a test suite for storage devices that runs more comprehensive tests than the standard file system tests using the storagetool. You can run bonnie++ outside of the storagetool, but for logging purposes, use bonnie++ within storagetool.

root@dell-diag-os:/opt/dellemc/diag/bin# bonnie++
You must use the "-u" switch when running as root.
usage: bonnie++ [-d scratch-dir] [-s size(Mb)[:chunk-size(b)]]
                [-n number-to-stat[:max-size[:min-size][:num-directories]]]
                [-m machine-name]
                [-r ram-size-in-Mb]
                [-x number-of-tests] [-u uid-to-use:gid-to-use] [-g gid-to-use]
                [-q] [-f] [-b] [-p processes | -y]

Version: 1.03
root@dell-diag-os:/opt/dellemc/diag/bin#

Rate this content

Accurate
Useful
Easy to understand
Was this article helpful?
0/3000 characters
  Please provide ratings (1-5 stars).
  Please provide ratings (1-5 stars).
  Please provide ratings (1-5 stars).
  Please select whether the article was helpful or not.
  Comments cannot contain these special characters: <>()\