summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGiuseppe Di Natale <[email protected]>2017-04-06 08:25:47 -0700
committerBrian Behlendorf <[email protected]>2017-04-10 10:24:17 -0700
commit42db43e982a243342a38e13f513513bb164d45e3 (patch)
tree9e7ca999d5cdbd30dbf04f4f610d7ee4c7c37cb8
parenta8d6ae1e16b253ac2bdb362b9a76945627faa7db (diff)
OpenZFS 2932 - support crash dumps to raidz, etc. pools
Authored by: Bill Pijewski <[email protected]> Reviewed by: Jerry Jelinek <[email protected]> Reviewed by: Matthew Ahrens <[email protected]> Approved by: Dan McDonald <[email protected]> Reviewed-by: George Melikov <[email protected]> Reviewed-by: Brian Behlendorf <[email protected]> Ported-by: Giuseppe Di Natale <[email protected]> OpenZFS-issue: https://www.illumos.org/issues/2932 OpenZFS-commit: https://github.com/openzfs/openzfs/commit/810e43b Closes #5984 Closes #5216
-rw-r--r--include/zfeature_common.h2
-rw-r--r--man/man5/zpool-features.528
-rw-r--r--module/zfs/zfeature_common.c6
-rw-r--r--tests/zfs-tests/tests/functional/cli_root/zpool_get/zpool_get.cfg2
4 files changed, 37 insertions, 1 deletions
diff --git a/include/zfeature_common.h b/include/zfeature_common.h
index acf76381b..25d680ffc 100644
--- a/include/zfeature_common.h
+++ b/include/zfeature_common.h
@@ -22,6 +22,7 @@
/*
* Copyright (c) 2011, 2015 by Delphix. All rights reserved.
* Copyright (c) 2013 by Saso Kiselkov. All rights reserved.
+ * Copyright (c) 2013, Joyent, Inc. All rights reserved.
*/
#ifndef _ZFEATURE_COMMON_H
@@ -42,6 +43,7 @@ typedef enum spa_feature {
SPA_FEATURE_ASYNC_DESTROY,
SPA_FEATURE_EMPTY_BPOBJ,
SPA_FEATURE_LZ4_COMPRESS,
+ SPA_FEATURE_MULTI_VDEV_CRASH_DUMP,
SPA_FEATURE_SPACEMAP_HISTOGRAM,
SPA_FEATURE_ENABLED_TXG,
SPA_FEATURE_HOLE_BIRTH,
diff --git a/man/man5/zpool-features.5 b/man/man5/zpool-features.5
index ccc7ab47e..e70af7695 100644
--- a/man/man5/zpool-features.5
+++ b/man/man5/zpool-features.5
@@ -279,6 +279,34 @@ an existing space map is upgraded to the new format. Once the feature is
.sp
.ne 2
.na
+\fB\fBmulti_vdev_crash_dump\fR\fR
+.ad
+.RS 4n
+.TS
+l l .
+GUID com.joyent:multi_vdev_crash_dump
+READ\-ONLY COMPATIBLE no
+DEPENDENCIES none
+.TE
+
+This feature allows a dump device to be configured with a pool comprised
+of multiple vdevs. Those vdevs may be arranged in any mirrored or raidz
+configuration.
+
+When the \fBmulti_vdev_crash_dump\fR feature is set to \fBenabled\fR,
+the administrator can use the \fBdumpadm\fR(1M) command to configure a
+dump device on a pool comprised of multiple vdevs.
+
+Under Linux this feature is registered for compatibility but not used.
+New pools created under Linux will have the feature \fBenabled\fR but
+will never transition to \fB\fBactive\fR. This functionality is not
+required in order to support crash dumps under Linux. Existing pools
+where this feature is \fB\fBactive\fR can be imported.
+.RE
+
+.sp
+.ne 2
+.na
\fB\fBextensible_dataset\fR\fR
.ad
.RS 4n
diff --git a/module/zfs/zfeature_common.c b/module/zfs/zfeature_common.c
index 768b77843..73abcb236 100644
--- a/module/zfs/zfeature_common.c
+++ b/module/zfs/zfeature_common.c
@@ -22,6 +22,7 @@
/*
* Copyright (c) 2011, 2015 by Delphix. All rights reserved.
* Copyright (c) 2013 by Saso Kiselkov. All rights reserved.
+ * Copyright (c) 2013, Joyent, Inc. All rights reserved.
* Copyright (c) 2014, Nexenta Systems, Inc. All rights reserved.
*/
@@ -192,6 +193,11 @@ zpool_feature_init(void)
"LZ4 compression algorithm support.",
ZFEATURE_FLAG_ACTIVATE_ON_ENABLE, NULL);
+ zfeature_register(SPA_FEATURE_MULTI_VDEV_CRASH_DUMP,
+ "com.joyent:multi_vdev_crash_dump", "multi_vdev_crash_dump",
+ "Crash dumps to multiple vdev pools.",
+ 0, NULL);
+
zfeature_register(SPA_FEATURE_SPACEMAP_HISTOGRAM,
"com.delphix:spacemap_histogram", "spacemap_histogram",
"Spacemaps maintain space histograms.",
diff --git a/tests/zfs-tests/tests/functional/cli_root/zpool_get/zpool_get.cfg b/tests/zfs-tests/tests/functional/cli_root/zpool_get/zpool_get.cfg
index 699229fef..f07f68abb 100644
--- a/tests/zfs-tests/tests/functional/cli_root/zpool_get/zpool_get.cfg
+++ b/tests/zfs-tests/tests/functional/cli_root/zpool_get/zpool_get.cfg
@@ -39,7 +39,7 @@ typeset -a properties=("size" "capacity" "altroot" "health" "guid" "version"
"feature@spacemap_histogram" "feature@enabled_txg" "feature@hole_birth"
"feature@extensible_dataset" "feature@bookmarks" "feature@embedded_data"
"feature@sha512" "feature@skein" "feature@edonr"
- "feature@userobj_accounting")
+ "feature@userobj_accounting" "feature@multi_vdev_crash_dump")
else
typeset -a properties=("size" "capacity" "altroot" "health" "guid" "version"
"bootfs" ""leaked" delegation" "autoreplace" "cachefile" "dedupditto" "dedupratio"