ZPOOL-REPLACE(8)
π NAME π
zpool-replace β swap one device out for another in a ZFS storage pool. bestie, it's a glow-up for your vdev β¨
πΈ SYNOPSIS πΈ
zpool replace [-fsw] [-o property=value] pool device [new-device]
π¦ DESCRIPTION π¦
okay so picture this: you take device, and you replace it with new-device. that's it, that's the vibe. π
it's literally equivalent to attaching new-device, waiting for it to resilver, and then detaching device. and heads up β any in progress scrub will be canceled. gone. not invited to the afterparty. π
the size of new-device must be greater than or equal to the minimum size of all the devices in a mirror or raidz configuration. no shrinking, we don't do that here π«Ά
new-device is required if the pool is not redundant. if you don't specify new-device, it just defaults to device. and that form of replacement is genuinely so useful after an existing disk has failed and has been physically replaced β in this case, the new disk may have the same /dev path as the old device, even though it is actually a different disk. ZFS recognizes this. main character energy fr fr π
β¨ the flags β¨
-fβ Forces use ofnew-device, even if it appears to be in use. ngl, not all devices can be overridden in this manner β so don't count on it for everything π-o property=valueβ Sets the given pool properties. see thezpoolprops(7)manual page for a list of valid properties that can be set. and the only property supported at the moment isashift. that's the whole menu bestie π-sβ Thenew-deviceis reconstructed sequentially to restore redundancy as quickly as possible. checksums are not verified during sequential reconstruction, so a scrub is started when the resilver completes. Sequential reconstruction is not supported for raidz configurations. not a single one. π-wβ Waits until the replacement has completed before returning. she's patient, she's committed, she stays till the job is done π
π SEE ALSO π
go read them, they're all iconic in their own way iykyk π
this page came from OpenZFS, dated July 11, 2022 β mwah, slay, no notes πβ¨
π¦ where this page comes from
- alpine 3.23: zfs-doc 2.4.4-r0 Β· CDDL-1.0
- alpine 3.24: zfs-doc 2.4.4-r0 Β· CDDL-1.0
- nixos 26.05: zfs-user 2.4.4
- nixpkgs unstable: zfs-user 2.4.4
- ubuntu resolute: zfsutils-linux 2.4.1-1ubuntu5 Β· CDDL-1.0
- ubuntu resolute: zfsutils-linux 2.4.1-1ubuntu5.1 Β· CDDL-1.0
- ubuntu stonking: zfsutils-linux 2.4.4-1ubuntu4 Β· CDDL-1.0
- π the page's license: CDDL-1.0
- Copyright (c) 2007, Sun Microsystems, Inc. All Rights Reserved
- Copyright (c) 2012, 2018 by Delphix. All rights reserved
- Copyright (c) 2012 Cyril Plisko. All Rights Reserved
- Copyright (c) 2017 Datto Inc
- Copyright (c) 2018 George Melikov. All Rights Reserved
- Copyright 2017 Nexenta Systems, Inc
- Copyright (c) 2017 Open-E, Inc. All Rights Reserved
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms