2019-11-13 17:21:07 +00:00
|
|
|
.\"
|
|
|
|
.\" CDDL HEADER START
|
|
|
|
.\"
|
|
|
|
.\" The contents of this file are subject to the terms of the
|
|
|
|
.\" Common Development and Distribution License (the "License").
|
|
|
|
.\" You may not use this file except in compliance with the License.
|
|
|
|
.\"
|
|
|
|
.\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
|
|
|
|
.\" or http://www.opensolaris.org/os/licensing.
|
|
|
|
.\" See the License for the specific language governing permissions
|
|
|
|
.\" and limitations under the License.
|
|
|
|
.\"
|
|
|
|
.\" When distributing Covered Code, include this CDDL HEADER in each
|
|
|
|
.\" file and include the License file at usr/src/OPENSOLARIS.LICENSE.
|
|
|
|
.\" If applicable, add the following below this CDDL HEADER, with the
|
|
|
|
.\" fields enclosed by brackets "[]" replaced with your own identifying
|
|
|
|
.\" information: Portions Copyright [yyyy] [name of copyright owner]
|
|
|
|
.\"
|
|
|
|
.\" CDDL HEADER END
|
|
|
|
.\"
|
|
|
|
.\" 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.
|
|
|
|
.\"
|
2020-07-03 18:05:50 +00:00
|
|
|
.Dd May 15, 2020
|
2019-11-13 17:21:07 +00:00
|
|
|
.Dt ZPOOL-ATTACH 8
|
2020-08-21 18:55:47 +00:00
|
|
|
.Os
|
2021-05-27 00:46:40 +00:00
|
|
|
.
|
2019-11-13 17:21:07 +00:00
|
|
|
.Sh NAME
|
2020-10-22 18:28:10 +00:00
|
|
|
.Nm zpool-attach
|
2021-05-27 00:46:40 +00:00
|
|
|
.Nd attach new device to existing ZFS vdev
|
2019-11-13 17:21:07 +00:00
|
|
|
.Sh SYNOPSIS
|
2020-10-22 18:28:10 +00:00
|
|
|
.Nm zpool
|
2019-11-13 17:21:07 +00:00
|
|
|
.Cm attach
|
2020-07-03 18:05:50 +00:00
|
|
|
.Op Fl fsw
|
2019-11-13 17:21:07 +00:00
|
|
|
.Oo Fl o Ar property Ns = Ns Ar value Oc
|
|
|
|
.Ar pool device new_device
|
2021-05-27 00:46:40 +00:00
|
|
|
.
|
2019-11-13 17:21:07 +00:00
|
|
|
.Sh DESCRIPTION
|
|
|
|
Attaches
|
|
|
|
.Ar new_device
|
|
|
|
to the existing
|
|
|
|
.Ar device .
|
|
|
|
The existing device cannot be part of a raidz configuration.
|
|
|
|
If
|
|
|
|
.Ar device
|
|
|
|
is not currently part of a mirrored configuration,
|
|
|
|
.Ar device
|
|
|
|
automatically transforms into a two-way mirror of
|
|
|
|
.Ar device
|
|
|
|
and
|
|
|
|
.Ar new_device .
|
|
|
|
If
|
|
|
|
.Ar device
|
|
|
|
is part of a two-way mirror, attaching
|
|
|
|
.Ar new_device
|
|
|
|
creates a three-way mirror, and so on.
|
|
|
|
In either case,
|
|
|
|
.Ar new_device
|
2020-07-03 18:05:50 +00:00
|
|
|
begins to resilver immediately and any running scrub is cancelled.
|
2019-11-13 17:21:07 +00:00
|
|
|
.Bl -tag -width Ds
|
|
|
|
.It Fl f
|
|
|
|
Forces use of
|
|
|
|
.Ar new_device ,
|
|
|
|
even if it appears to be in use.
|
|
|
|
Not all devices can be overridden in this manner.
|
|
|
|
.It Fl o Ar property Ns = Ns Ar value
|
2021-05-27 00:46:40 +00:00
|
|
|
Sets the given pool properties.
|
|
|
|
See the
|
2021-06-04 20:29:26 +00:00
|
|
|
.Xr zpoolprops 7
|
2021-05-27 00:46:40 +00:00
|
|
|
manual page for a list of valid properties that can be set.
|
|
|
|
The only property supported at the moment is
|
|
|
|
.Sy ashift .
|
2020-07-03 18:05:50 +00:00
|
|
|
.It Fl s
|
|
|
|
The
|
|
|
|
.Ar new_device
|
|
|
|
is reconstructed sequentially to restore redundancy as quickly as possible.
|
|
|
|
Checksums are not verfied during sequential reconstruction so a scrub is
|
|
|
|
started when the resilver completes.
|
|
|
|
Sequential reconstruction is not supported for raidz configurations.
|
|
|
|
.It Fl w
|
|
|
|
Waits until
|
|
|
|
.Ar new_device
|
|
|
|
has finished resilvering before returning.
|
2019-11-13 17:21:07 +00:00
|
|
|
.El
|
2021-05-27 00:46:40 +00:00
|
|
|
.
|
2019-11-13 17:21:07 +00:00
|
|
|
.Sh SEE ALSO
|
|
|
|
.Xr zpool-add 8 ,
|
2021-05-27 00:46:40 +00:00
|
|
|
.Xr zpool-detach 8 ,
|
2019-11-13 17:21:07 +00:00
|
|
|
.Xr zpool-import 8 ,
|
|
|
|
.Xr zpool-initialize 8 ,
|
|
|
|
.Xr zpool-online 8 ,
|
|
|
|
.Xr zpool-replace 8 ,
|
|
|
|
.Xr zpool-resilver 8
|