SOLVED [Solved] Problem HDD, replaced but cannot resilver or add to pool

oneness

Cadet
Joined
Nov 29, 2014
Messages
9
Hi,
Firstly, due to personal reasons, my current NAS setup was never fully completed upon last rebuild, adding all the email stuff for alerts and scripts etc. That was my bad, but I just wasn't using it either, until recently. So I had undusted the box to try get a good working Plex setup again, and everything was going fine until i logged into the webUI this week and say an alert saying my pool was degreaded:

Code:
New alert:
* Pool store state is DEGRADED: One or more devices has been taken offline by the administrator. Sufficient replicas exist for the pool to continue functioning in a degraded state.

The following alert has been cleared:
* Pool store state is ONLINE: One or more devices has experienced an unrecoverable error. An attempt was made to correct the error. Applications are unaffected.

Current alerts:
* Pool store state is DEGRADED: One or more devices has been taken offline by the administrator. Sufficient replicas exist for the pool to continue functioning in a degraded state. 


I had a spare same model/size RED at hand and without really thinking (because I've done it once before a while back), i just shut down the box, removed the drive, replaced it and started the box back up thinking to just go into the webUI and choose replace/resilver like i remembered doing.
But that option wasn't available ANYWHERE I could see, including where the few guides online i could find mentioned it should be. Something I read said i should mark the problem drive as "offline" and then shutdown/replace, so I put old drive back and did that, although, there were no errors once i put the old drive back in and the pool was marked as healthy in the webUI (presumably because it does that until tests or whatever show it as problem again). But anyway i marked as offline, shutdown, put new drive back in, booted up, and still there was no replace/resilved option anywhere i could see.

Code:
# zpool status
  pool: freenas-boot
 state: ONLINE
  scan: scrub repaired 0 in 0 days 00:00:25 with 0 errors on Fri Nov  8 03:45:25 2019
config:

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

errors: No known data errors

  pool: store
 state: DEGRADED
status: One or more devices has been taken offline by the administrator.
        Sufficient replicas exist for the pool to continue functioning in a
        degraded state.
action: Online the device using 'zpool online' or replace the device with
        'zpool replace'.
  scan: scrub in progress since Thu Nov 14 20:28:14 2019
        2.64T scanned at 1022M/s, 1.20T issued at 464M/s, 7.52T total
        0 repaired, 15.96% done, 0 days 03:58:10 to go
config:

        NAME                                            STATE     READ WRITE CKSUM
        store                                           DEGRADED     0     0     0
          raidz1-0                                      DEGRADED     0     0     0
            12255453197370737536                        OFFLINE      0     0     0  was /dev/gptid/7f8fe6ab-6033-11e9-a8ab-7085c27b080f
            gptid/99ac35ed-9886-11e8-8e34-7085c27b080f  ONLINE       0     0     0
            gptid/2078e43f-c25b-11e2-a8b0-60a44cae968d  ONLINE       0     0     0
            gptid/210199da-c25b-11e2-a8b0-60a44cae968d  ONLINE       0     0     0
            gptid/218ba2d5-c25b-11e2-a8b0-60a44cae968d  ONLINE       0     0     0

errors: No known data errors


So, I did that and I see it says to mark it as online which I've done:
Code:
# zpool online store gptid/7f8fe6ab-6033-11e9-a8ab-7085c27b080f
warning: device 'gptid/7f8fe6ab-6033-11e9-a8ab-7085c27b080f' onlined, but remains in faulted state
use 'zpool replace' to replace devices that are no longer present


But now if I try the same format/syntax I get this:

Code:
# zpool replace
missing pool name argument
usage:
        replace [-f] <pool> <device> [new-device]

root@freenas[~]# zpool replace store gptid/7f8fe6ab-6033-11e9-a8ab-7085c27b080f
cannot open 'gptid/7f8fe6ab-6033-11e9-a8ab-7085c27b080f': no such GEOM provider
must be a full path or shorthand device name

root@freenas[~]# zpool replace store 7f8fe6ab-6033-11e9-a8ab-7085c27b080f
cannot open '7f8fe6ab-6033-11e9-a8ab-7085c27b080f': no such GEOM provider
must be a full path or shorthand device name

root@freenas[~]# zpool replace store /dev/gptid/7f8fe6ab-6033-11e9-a8ab-7085c27b080f
cannot open '/dev/gptid/7f8fe6ab-6033-11e9-a8ab-7085c27b080f': No such file or directory


I tried all three versions of the device name that I seemed to have and that had just worked to put the HDD online with, but none work.

Something isn't working as intended here, that much I know. I remember the process being much simpler and smoother when I did it in the 9.3 or so days.

Can someone point me in the right direction please?
Thanks, and I've tried the be as thorough as I can be, but let me know if you need more information.
 

oneness

Cadet
Joined
Nov 29, 2014
Messages
9
Actually, I think I was using the incorrect gptid as I copied the one from the zpool status that said "was" meaning the old HDDs gptid I guess. So I found the new one and tried to online it, but it's not added to the pool, nor does it show in the webUI in the pool.
I tried to zpool add it, but I'm not having much luck either.

Code:
]# ls /dev/gptid/
2078e43f-c25b-11e2-a8b0-60a44cae968d    77b00296-8a89-11e9-892d-7085c27b080f
210199da-c25b-11e2-a8b0-60a44cae968d    99ac35ed-9886-11e8-8e34-7085c27b080f
218ba2d5-c25b-11e2-a8b0-60a44cae968d


Code:
# zpool replace store /dev/gptid/77b00296-8a89-11e9-892d-7085c27b080f
cannot replace /dev/gptid/77b00296-8a89-11e9-892d-7085c27b080f with /dev/gptid/77b00296-8a89-11e9-892d-7085c27b080f: no such device in pool
root@freenas[~]# zpool attach store 77b00296-8a89-11e9-892d-7085c27b080f
missing <new_device> specification
usage:
        attach [-f] <pool> <device> <new-device>
root@freenas[~]# zpool attach store gptid/77b00296-8a89-11e9-892d-7085c27b080f
missing <new_device> specification
usage:
        attach [-f] <pool> <device> <new-device>
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,702
You may need to wipe the new disk first in the disks list in the GUI... then it should be visible in the replace process.
 

oneness

Cadet
Joined
Nov 29, 2014
Messages
9
You may need to wipe the new disk first in the disks list in the GUI... then it should be visible in the replace process.

Thanks for the response! Yes I only see "Edit" and "wipe" in the elipses menu on webUI>Storage>Disks>ad0.
I just tried a quick wipe and i still don't get replace in the elipses menu.
ad0 show "unused" under the Pool column.
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,702
You now go to the pool and on the bad disk, you use replace and then select the newly wiped disk. Use the settings cog-wheel at the right of the new GUI to see the disk layout of the pool.
 

oneness

Cadet
Joined
Nov 29, 2014
Messages
9
You now go to the pool and on the bad disk, you use replace and then select the newly wiped disk. Use the settings cog-wheel at the right of the new GUI to see the disk layout of the pool.

Thank you so much! It worked. I knew I was overcomplicating it, but I was really thrown by these instructions that I must have read without enough concentration as I ended up in the wrong place in the webUI :)
 
Top