2013-04-20

Notes To Self: FreeNAS / ZFS Settings / BSD Commands

Commands and output...

 /# camcontrol devlist
<ATA SAMSUNG HD502HJ 00E4>         at scbus0 target 0 lun 0 (pass0,da0)
<ATA SAMSUNG HD502HJ 00E4>         at scbus0 target 1 lun 0 (pass1,da1)
<ATA SAMSUNG HD502HJ 00E4>         at scbus0 target 2 lun 0 (pass2,da2)
<KINGSTON SH103S3120G 502ABBF0>    at scbus1 target 0 lun 0 (pass3,ada0)
<ST3000DM001-1CH166 CC43>          at scbus2 target 0 lun 0 (pass4,ada1)
<ST3000DM001-1CH166 CC24>          at scbus3 target 0 lun 0 (pass5,ada2)
<ST3000DM001-9YN166 CC4B>          at scbus4 target 0 lun 0 (pass6,ada3)
<ST3000DM001-9YN166 CC4B>          at scbus5 target 0 lun 0 (pass7,ada4)
<ST3000DM001-1CH166 CC43>          at scbus6 target 0 lun 0 (pass8,ada5)
<SanDisk U3 Cruzer Micro 3.27>     at scbus7 target 0 lun 0 (pass9,da3)

[root@afarstor /mnt/durance]# for i in $(sysctl -n kern.disks); do smartctl -a /dev/$i >>`date +%Y.%m.%d`-afarstor_smart_dump.txt; done;

Example output:

=== START OF INFORMATION SECTION ===
Model Family:     Seagate Barracuda (SATA 3Gb/s, 4K Sectors)
Device Model:     ST3000DM001-1CH166
Device Id: 5 000c50 04e0962ff
Firmware Version: CC43
User Capacity:    3,000,592,982,016 bytes [3.00 TB]
Sector Sizes:     512 bytes logical, 4096 bytes physical
Device is:        In smartctl database [for details use: -P show]
ATA Version is:   8
ATA Standard is:  ATA-8-ACS revision 4
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

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

SMART Attributes Data Structure revision number: 10
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  1 Raw_Read_Error_Rate     0x000f   100   100   006    Pre-fail  Always       -       121624
  3 Spin_Up_Time            0x0003   091   091   000    Pre-fail  Always       -       0
  4 Start_Stop_Count        0x0032   100   100   020    Old_age   Always       -       19
  5 Reallocated_Sector_Ct   0x0033   100   100   036    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x000f   100   253   030    Pre-fail  Always       -       1335
  9 Power_On_Hours          0x0032   100   100   000    Old_age   Always       -       25
 10 Spin_Retry_Count        0x0013   100   100   097    Pre-fail  Always       -       0
 12 Power_Cycle_Count       0x0032   100   100   020    Old_age   Always       -       6
183 Runtime_Bad_Block       0x0032   100   100   000    Old_age   Always       -       0
184 End-to-End_Error        0x0032   100   100   099    Old_age   Always       -       0
187 Reported_Uncorrect      0x0032   100   100   000    Old_age   Always       -       0
188 Command_Timeout         0x0032   100   100   000    Old_age   Always       -       0
189 High_Fly_Writes         0x003a   100   100   000    Old_age   Always       -       0
190 Airflow_Temperature_Cel 0x0022   076   068   045    Old_age   Always       -       24 (Min/Max 23/26)
191 G-Sense_Error_Rate      0x0032   100   100   000    Old_age   Always       -       0
192 Power-Off_Retract_Count 0x0032   100   100   000    Old_age   Always       -       5
193 Load_Cycle_Count        0x0032   100   100   000    Old_age   Always       -       19
194 Temperature_Celsius     0x0022   024   040   000    Old_age   Always       -       24 (0 21 0 0 0)
197 Current_Pending_Sector  0x0012   100   100   000    Old_age   Always       -       0
198 Offline_Uncorrectable   0x0010   100   100   000    Old_age   Offline      -       0
199 UDMA_CRC_Error_Count    0x003e   200   200   000    Old_age   Always       -       0
240 Head_Flying_Hours       0x0000   100   253   000    Old_age   Offline      -       40956808134661
241 Total_LBAs_Written      0x0000   100   253   000    Old_age   Offline      -       21788
242 Total_LBAs_Read         0x0000   100   253   000    Old_age   Offline      -       60760

 /# zpool status
  pool: chelestra
 state: ONLINE
  scan: none requested
config:

        NAME                                            STATE     READ WRITE CKSUM
        chelestra                                       ONLINE       0     0     0
          raidz2-0                                      ONLINE       0     0     0
            gptid/981738af-cd71-11e2-949a-3085a93e10c7  ONLINE       0     0     0
            gptid/98dab7a8-cd71-11e2-949a-3085a93e10c7  ONLINE       0     0     0
            gptid/9a179f3c-cd71-11e2-949a-3085a93e10c7  ONLINE       0     0     0
            gptid/9ae54d94-cd71-11e2-949a-3085a93e10c7  ONLINE       0     0     0
            gptid/9ba55256-cd71-11e2-949a-3085a93e10c7  ONLINE       0     0     0
        cache
          gptid/9c3aab11-cd71-11e2-949a-3085a93e10c7    ONLINE       0     0     0

errors: No known data errors

  pool: durance
 state: ONLINE
  scan: none requested
config:

        NAME                                            STATE     READ WRITE CKSUM
        durance                                         ONLINE       0     0     0
          mirror-0                                      ONLINE       0     0     0
            gptid/e1f271a9-cc1b-11e2-a9a2-3085a93e10c7  ONLINE       0     0     0
            gptid/e2a6eb5f-cc1b-11e2-a9a2-3085a93e10c7  ONLINE       0     0     0
            gptid/e3541d6e-cc1b-11e2-a9a2-3085a93e10c7  ONLINE       0     0     0

errors: No known data errors

 /# df -h
Filesystem             Size    Used   Avail Capacity  Mounted on
/dev/ufs/FreeNASs2a    926M    381M    470M    45%    /
devfs                  1.0k    1.0k      0B   100%    /dev
/dev/md0               4.6M    3.2M    973k    77%    /etc
/dev/md1               823k    2.5k    755k     0%    /mnt
/dev/md2               149M     15M    121M    11%    /var
/dev/ufs/FreeNASs4      19M    973k     17M     5%    /data
durance                452G     88G    364G    20%    /mnt/durance
chelestra                8T    255k      8T     0%    /mnt/chelestra

Useful Ref:
FreeNAS Docs
[ HOW TO ] Manage Automatic Daily Email Reports  - Deal with retarded daily emails. (FreeNAS devs took a lesson from Microsoft; no configurable option, and no trace of logic; instead of sending on an error or condition requiring attention, FreeNAS insists on telling you everything's okay... )

No comments: