root@freenas:~ # smartctl -AHijl error /dev/da12
{
"json_format_version": [
1,
0
],
"smartctl": {
"version": [
7,
2
],
"svn_revision": "5155",
"platform_info": "FreeBSD 12.2-RELEASE-p14 amd64",
"build_info": "(local build)",
"argv": [
"smartctl",
"-AHijl",
"error",
"/dev/da12"
],
"exit_status": 0
},
"device": {
"name": "/dev/da12",
"info_name": "/dev/da12",
"type": "scsi",
"protocol": "SCSI" #Note that this can be used to identify 'SCSI', 'ATA' and 'NVMe' devices to determine what kind of parsing to do next
},
"vendor": "HITACHI",
"product": "HUS72303CLAR3000",
"model_name": "HITACHI HUS72303CLAR3000", #This is essentially the "Model Family" that many scripts parse.
"revision": "C442",
"scsi_version": "SPC-4",
"user_capacity": {
"blocks": 5860533168,
"bytes": 3000592982016
},
"logical_block_size": 512,
"rotation_rate": 7200, #Just like SATA, this will tell you if it's an SSD (0) or HDD (!0)
"form_factor": {
"scsi_value": 2,
"name": "3.5 inches"
},
"serial_number": "YXGKV08K", # Self Explanatory
"device_type": {
"scsi_value": 0,
"name": "disk"
},
"local_time": {
"time_t": 1651375013,
"asctime": "Sat Apr 30 23:16:53 2022 EDT"
},
"smart_status": {
"passed": true # Self Explanatory
},
"temperature": {
"current": 37, # Self Explanatory
"drive_trip": 85
},
"power_on_time": {
"hours": 6929, # Self Explanatory
"minutes": 34
},
"scsi_grown_defect_list": 0, # Essentially the same as SATA's "Reallocated Sectors", this is the most important value to parse.
"scsi_error_counter_log": {
"read": {
"errors_corrected_by_eccfast": 0, #These corrected errors don't really matter, I see drives with thousands of them routinely
"errors_corrected_by_eccdelayed": 0,
"errors_corrected_by_rereads_rewrites": 0,
"total_errors_corrected": 0,
"correction_algorithm_invocations": 38430822,
"gigabytes_processed": "169980.507", # Total GB read, if you want it. See below for writes and verifies
"total_uncorrected_errors": 0 # These are the other important error counters (uncorrected read, write & verify) to parse
}, # While they're not quite the same, consider these like the CRC and Offline Unc errors most
"write": { # scripts report for SATA drives.
"errors_corrected_by_eccfast": 0,
"errors_corrected_by_eccdelayed": 0,
"errors_corrected_by_rereads_rewrites": 0,
"total_errors_corrected": 0,
"correction_algorithm_invocations": 735266,
"gigabytes_processed": "110098.841", # See note above
"total_uncorrected_errors": 0 # See note above
},
"verify": {
"errors_corrected_by_eccfast": 0,
"errors_corrected_by_eccdelayed": 0,
"errors_corrected_by_rereads_rewrites": 0,
"total_errors_corrected": 0,
"correction_algorithm_invocations": 3672791,
"gigabytes_processed": "27237.958", # See note above
"total_uncorrected_errors": 0 # See note above
}
}
}