Re: zpool query
- In reply to: Steve O'Hara-Smith : "Re: zpool query"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 25 Jul 2022 09:43:22 UTC
Hello
On Sun, 24 Jul 2022, at 15:06, Steve O'Hara-Smith wrote:
> Provided there is not too much data then you can use zpool remove
> to remove one drive from the stripe - this will take time because all the
> data has to be copied and it will fail if there isn't room for it all.
>
> Once the drive is removed you can use zpool attach to add it as a
> mirror of the other drive.
>
> Full disclosure - this is as documented I've never needed to do it.
Thank you Steve, this worked. It tells you progress of what it's doing like so:
remove: Evacuation of /dev/ada1 in progress since Mon Jul 25 00:35:56 2022
2.34G copied out of 7.24G at 100M/s, 32.38% done, 0h0m to go
(eventually)
remove: Removal of vdev 1 copied 7.24G in 0h1m, completed on Mon Jul 25 00:37:29 2022
221K memory used for removed device mappings
this was really painless; I'm very impressed. I was *sure* I'd have to shift
data, which would have been a pain. In the end, decided not to mirror as the removed disk was clocking errors (this was the reason I wanted to remove it from the striped array in the first place). Thought i might be able to remap the bad blocks with a dd read of the whole disk and then use it to make a mirror but there's like >10k already, so it's being junked. The other disk, which is the same make/vintage has 0 errors.
thanks again