Drive failing? Advice to turn off?

ttommy

Cadet
Joined
Jan 4, 2017
Messages
5
Hi all,

it seems that I have a failing drive? And I would like to ask for your advice on the safest way to proceed.
A new drive is on the way but it will take 3 days. Is it safer to turn off the server or keep it running until the drive arrives?

Help is much appreciated. In the following further information (let me know if there is any more info needed):

I received following alert and noticed that read/write access on the network drives are very slow now:
Code:
CRITICAL
Device: /dev/ada3, Self-Test Log error count increased from 0 to 1.


running:
zpool status
Code:
pool: nasdata0
 state: ONLINE
  scan: scrub repaired 0 in 0 days 09:32:42 with 0 errors on Sun Jan  9 09:32:43 2022
config:

        NAME                                            STATE     READ WRITE CKSUM
        nasdata0                                        ONLINE       0     0     0
          mirror-0                                      ONLINE       0     0     0
            gptid/fa24bf44-2780-11e7-b83f-1c98ec0e86cc  ONLINE       0     0     0
            gptid/fac6b6d3-2780-11e7-b83f-1c98ec0e86cc  ONLINE       0     0     0
          mirror-1                                      ONLINE       0     0     0
            gptid/fb70c825-2780-11e7-b83f-1c98ec0e86cc  ONLINE       0     0     0
            gptid/f9718802-8394-11e8-a1d5-1c98ec0e86cc  ONLINE       0     0     0

errors: No known data errors


running:
smartctl -t long /dev/ada3 (estimation was that it should take 700mins)
smartctl -a /dev/ada3 (I accidently aborted it after half a day)
Code:
smartctl 7.0 2018-12-30 r4883 [FreeBSD 11.3-RELEASE-p14 amd64] (local build)
Copyright (C) 2002-18, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Model Family:     Western Digital Red
Device Model:     WDC WD60EFRX-68L0BN1
Serial Number:    WD-WXB1HB4M4USZ
LU WWN Device Id: 5 0014ee 2b7f72650
Firmware Version: 82.00A82
User Capacity:    6,001,175,126,016 bytes [6.00 TB]
Sector Sizes:     512 bytes logical, 4096 bytes physical
Rotation Rate:    5700 rpm
Device is:        In smartctl database [for details use: -P show]
ATA Version is:   ACS-2, ACS-3 T13/2161-D revision 3b
SATA Version is:  SATA 3.1, 6.0 Gb/s (current: 3.0 Gb/s)
Local Time is:    Fri Feb 11 21:28:50 2022 CET
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

General SMART Values:
Offline data collection status:  (0x00) Offline data collection activity
                                        was never started.
                                        Auto Offline Data Collection: Disabled.
Self-test execution status:      ( 120) The previous self-test completed having
                                        the read element of the test failed.
Total time to complete Offline
data collection:                ( 4604) seconds.
Offline data collection
capabilities:                    (0x7b) SMART execute Offline immediate.
                                        Auto Offline data collection on/off support.
                                        Suspend Offline collection upon new
                                        command.
                                        Offline surface scan supported.
                                        Self-test supported.
                                        Conveyance Self-test supported.
                                        Selective Self-test supported.
SMART capabilities:            (0x0003) Saves SMART data before entering
                                        power-saving mode.
                                        Supports SMART auto save timer.
Error logging capability:        (0x01) Error logging supported.
                                        General Purpose Logging supported.
Short self-test routine
recommended polling time:        (   2) minutes.
Extended self-test routine
recommended polling time:        ( 700) minutes.
Conveyance self-test routine
recommended polling time:        (   5) minutes.
SCT capabilities:              (0x303d) 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     0x002f   200   200   051    Pre-fail  Always       -       0
  3 Spin_Up_Time            0x0027   233   198   021    Pre-fail  Always       -       7316
  4 Start_Stop_Count        0x0032   100   100   000    Old_age   Always       -       88
  5 Reallocated_Sector_Ct   0x0033   200   200   140    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x002e   001   001   000    Old_age   Always       -       65535
  9 Power_On_Hours          0x0032   042   042   000    Old_age   Always       -       43031
 10 Spin_Retry_Count        0x0032   100   253   000    Old_age   Always       -       0
 11 Calibration_Retry_Count 0x0032   100   253   000    Old_age   Always       -       0
 12 Power_Cycle_Count       0x0032   100   100   000    Old_age   Always       -       88
192 Power-Off_Retract_Count 0x0032   200   200   000    Old_age   Always       -       8
193 Load_Cycle_Count        0x0032   200   200   000    Old_age   Always       -       573
194 Temperature_Celsius     0x0022   117   109   000    Old_age   Always       -       35
196 Reallocated_Event_Count 0x0032   200   200   000    Old_age   Always       -       0
197 Current_Pending_Sector  0x0032   200   200   000    Old_age   Always       -       0
198 Offline_Uncorrectable   0x0030   100   253   000    Old_age   Offline      -       0
199 UDMA_CRC_Error_Count    0x0032   200   200   000    Old_age   Always       -       0
200 Multi_Zone_Error_Rate   0x0008   200   200   000    Old_age   Offline      -       2

SMART Error Log Version: 1
No Errors Logged

SMART Self-test log structure revision number 1
Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error
# 1  Extended offline    Completed: read failure       80%     43012         646572264
# 2  Extended offline    Aborted by host               90%     43005         -
# 3  Short offline       Completed without error       00%     43005         -
# 4  Extended offline    Completed: read failure       90%     42919         1166801824
# 5  Extended offline    Completed without error       00%     42691         -
# 6  Extended offline    Completed without error       00%     42523         -
# 7  Extended offline    Completed without error       00%     42355         -
# 8  Extended offline    Completed without error       00%     42188         -
# 9  Extended offline    Completed without error       00%     41948         -
#10  Extended offline    Completed without error       00%     41780         -
#11  Extended offline    Completed without error       00%     41612         -
#12  Extended offline    Completed without error       00%     41444         -
#13  Extended offline    Completed without error       00%     41236         -
#14  Extended offline    Completed without error       00%     41061         -
#15  Extended offline    Completed without error       00%     40726         -
#16  Extended offline    Completed without error       00%     40484         -
#17  Extended offline    Completed without error       00%     40317         -
#18  Extended offline    Completed without error       00%     40149         -
#19  Extended offline    Completed without error       00%     39981         -
#20  Extended offline    Completed without error       00%     39765         -
#21  Extended offline    Completed without error       00%     39597         -

SMART Selective self-test log data structure revision number 1
 SPAN  MIN_LBA  MAX_LBA  CURRENT_TEST_STATUS
    1        0        0  Not_testing
    2        0        0  Not_testing
    3        0        0  Not_testing
    4        0        0  Not_testing
    5        0        0  Not_testing
Selective self-test flags (0x0):
  After scanning selected spans, do NOT read-scan remainder of disk.
If Selective self-test is pending on power-up, resume after 0 minute delay.


FreeNAS-11.3-U5
HP Microserver Gen8
4x 6TB WD Red EFRX
Xeon E3-1220L V5 2.30GHz, 16GB RAM
 

Samuel Tai

Never underestimate your own stupidity
Moderator
Joined
Apr 24, 2020
Messages
5,399
You should be OK to let the server run until the replacement drive arrives. You can run the disk replacement procedure up to the point of removing the failing drive, and this should restore your IO speed. When the new drive arrives, you can complete the disk replacement procedure, and let the resilver go to completion.
 

ttommy

Cadet
Joined
Jan 4, 2017
Messages
5
Thank you for the guide.
I have received the new drive now, but when trying to replace it I messed up with a stupid mistake.
Instead of choosing "offline" for the faulty drive I have selected "detach". Now it seems that I have lost the mirror and I can't find any "attach" button to add the new drive.

Can you please advice me how to bring in the new drive to the pool and mirror it?

zpool status
Code:
  pool: freenas-boot
 state: ONLINE
  scan: scrub repaired 0 in 0 days 00:42:44 with 0 errors on Mon Feb 14 04:27:44 2022
config:

        NAME        STATE     READ WRITE CKSUM
        freenas-boot  ONLINE       0     0     0
          mirror-0  ONLINE       0     0     0
            da1p2   ONLINE       0     0     0
            da0p2   ONLINE       0     0     0

errors: No known data errors

  pool: nasdata0
 state: ONLINE
  scan: scrub in progress since Sun Feb 13 00:17:36 2022
        1.64T scanned at 332M/s, 840G issued at 166M/s, 7.04T total
        0 repaired, 11.65% done, 0 days 10:55:29 to go
config:

        NAME                                            STATE     READ WRITE CKSUM
        nasdata0                                        ONLINE       0     0     0
          mirror-0                                      ONLINE       0     0     0
            gptid/fa24bf44-2780-11e7-b83f-1c98ec0e86cc  ONLINE       0     0     0
            gptid/fac6b6d3-2780-11e7-b83f-1c98ec0e86cc  ONLINE       0     0     0
          gptid/f9718802-8394-11e8-a1d5-1c98ec0e86cc    ONLINE       0     0     0


glabel status
Code:
                                      Name  Status  Components
gptid/f9718802-8394-11e8-a1d5-1c98ec0e86cc     N/A  ada0p2
gptid/fa24bf44-2780-11e7-b83f-1c98ec0e86cc     N/A  ada1p2
gptid/fac6b6d3-2780-11e7-b83f-1c98ec0e86cc     N/A  ada2p2
gptid/6b3a0037-f7e2-11e9-8fe4-1c98ec0e86cc     N/A  da0p1
gptid/6432d098-f6d5-11ea-9577-1c98ec0e86cc     N/A  da1p1
gptid/f961c15f-8394-11e8-a1d5-1c98ec0e86cc     N/A  ada0p1
 

Samuel Tai

Never underestimate your own stupidity
Moderator
Joined
Apr 24, 2020
Messages
5,399
First, let the scrub complete. In your case, you will need to extend the pool to include the new drive as a mirror of gptid/f9718802-8394-11e8-a1d5-1c98ec0e86cc.
 

ttommy

Cadet
Joined
Jan 4, 2017
Messages
5
Thanks for your help Samuel Tai.

While the scrub is running I am trying to figure out how to extend the pool later on, but I am not sure. Is it possible to do this in the WebUI?
When I go to the pool -> extend it will show me the following dialog with a warning. Is this the right dialog I will have to go?

a.png


I have found a video, but it seems this is only for TrueNAS Core (link). I don't have the extend button available when selecting the drive as shown in the video.

Can you please point me to a guide/thread which explains what steps I will have to do?
 

Samuel Tai

Never underestimate your own stupidity
Moderator
Joined
Apr 24, 2020
Messages
5,399
Sorry, I used the wrong terminology. Go to Storage->Pools, and click the gear. Pull down to Status. Does your detached drive appear here? If so, just complete the disk replacement by clicking the 3 dots next to it, and selecting Replace. Otherwise, please just attach a screen shot, so I can advise.
 

ttommy

Cadet
Joined
Jan 4, 2017
Messages
5
Scrub has finished now.
The detached drive does not appear under Storage -> Pools -> Status:
1644916724953.png


zpool status
Code:
  pool: nasdata0
 state: ONLINE
  scan: scrub repaired 0 in 2 days 09:26:43 with 0 errors on Tue Feb 15 09:44:19 2022
config:

        NAME                                            STATE     READ WRITE CKSUM
        nasdata0                                        ONLINE       0     0     0
          mirror-0                                      ONLINE       0     0     0
            gptid/fa24bf44-2780-11e7-b83f-1c98ec0e86cc  ONLINE       0     0     0
            gptid/fac6b6d3-2780-11e7-b83f-1c98ec0e86cc  ONLINE       0     0     0
          gptid/f9718802-8394-11e8-a1d5-1c98ec0e86cc    ONLINE       0     0     0

errors: No known data errors


glabel status
Code:
 Name  Status  Components
gptid/f9718802-8394-11e8-a1d5-1c98ec0e86cc     N/A  ada0p2
gptid/fa24bf44-2780-11e7-b83f-1c98ec0e86cc     N/A  ada1p2
gptid/fac6b6d3-2780-11e7-b83f-1c98ec0e86cc     N/A  ada2p2
gptid/6b3a0037-f7e2-11e9-8fe4-1c98ec0e86cc     N/A  da0p1
gptid/6432d098-f6d5-11ea-9577-1c98ec0e86cc     N/A  da1p1
gptid/f961c15f-8394-11e8-a1d5-1c98ec0e86cc     N/A  ada0p1


Looking forward to your advice, thank you in advance!
 

Samuel Tai

Never underestimate your own stupidity
Moderator
Joined
Apr 24, 2020
Messages
5,399
OK, unfortunately, there doesn't seem to be a GUI option to repair this situation, so we must fall back to CLI commands. As this was caused by a detach, we'll need to perform the opposite action with an attach. However, be advised if you typo something here, it may not be possible to repair the damage. Have your data backed up externally, as the only recovery then is to destroy your original pool, rebuild it, and then move your data back.
  1. First, create a temporary 1-disk pool with your new drive ada3. You can do this from the GUI. Once the new pool appears, note the GUID of the ada3p2 partition. This step formats ada3 with the correct layout.
  2. Next, drop to a command line. The web shell will work in a pinch, but much better is to SSH in via PuTTY.
  3. Destroy the temporary pool by running zpool destroy <name of temp pool>.
  4. Check the GUID of ada3p2 didn't change with glabel status.
  5. Now, run zpool attach nasdata0 gptid/f9718802-8394-11e8-a1d5-1c98ec0e86cc <GUID of ada3p2>. This should attach ada3p2 to the singleton, and create a 2-way mirror. This will also start a resilver. If you use the wrong GUID from another member of the pool, this will have catastrophic consequences for your pool. I recommend using Notepad to cut-and-paste the GUIDs to check the command before running it.
As you've seen, ZFS expects you know what you're doing, and doesn't make many allowances for administrator error. Always be aware of what the correct procedure is.
 

ttommy

Cadet
Joined
Jan 4, 2017
Messages
5
Thank you!
It seems to work, resilvering right now.

zpool status
Code:
  pool: nasdata0
 state: ONLINE
status: One or more devices is currently being resilvered.  The pool will
        continue to function, possibly in a degraded state.
action: Wait for the resilver to complete.
  scan: resilver in progress since Tue Feb 15 14:58:38 2022
        1.54T scanned at 610M/s, 765G issued at 3.95G/s, 6.95T total
        1.84G resilvered, 10.74% done, 0 days 00:26:48 to go
config:

        NAME                                            STATE     READ WRITE CKSUM
        nasdata0                                        ONLINE       0     0     0
          mirror-0                                      ONLINE       0     0     0
            gptid/fa24bf44-2780-11e7-b83f-1c98ec0e86cc  ONLINE       0     0     0
            gptid/fac6b6d3-2780-11e7-b83f-1c98ec0e86cc  ONLINE       0     0     0
          mirror-1                                      ONLINE       0     0     0
            gptid/f9718802-8394-11e8-a1d5-1c98ec0e86cc  ONLINE       0     0     0
            gptid/a3eaf56b-8e66-11ec-8929-1c98ec0e86cc  ONLINE       0     0     0
 
Top