ZFS: How can I stop a zpool replace that's currently in progress?

So, I just recently had an issue where I was replacing a drive, and as soon as reslivering started, the new drive bombed out.

I yanked and replaced w/ the previous drive (still worked, just was increasing capacity), but still had the "replacing" bits when I ran zpool status.

Here's what got me back to normal:

zpool detach mypoolname /dev/disk/by-id/scsi-SATA_XYZ

All seems well now.


I just did a detach like this and it worked !

zpool detach storage c9t24d1

And c9t24d1 was a hot spare that I just add to one of my mirror because I tough we had no drive available to replace a failed one.

After putting a new drive in my spool before the hot spare finish resilvering, I just detach my spare to stop the silvering process and it work.

After that I replace my bad drive with the new one. For us one silvering process is the max that we can have in our pool of 24 drives. With 2 silvering process happening simultaneously its hurting to much our users.

Hope this can help others in the same situation.


According the docs:

An in-progress spare replacement can be cancelled by detaching the hot spare.

It sounds like you did a manual replace but detching the new disk might work the same.