aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorArkadiusz Bubała <[email protected]>2017-10-26 21:26:09 +0200
committerBrian Behlendorf <[email protected]>2017-10-26 12:26:09 -0700
commitd3f2cd7e3b70679f127dd471ea6d37ece27463f2 (patch)
treec83555f629c501dd5742272c62888caa785b7468 /include
parent3ad59c015dce45965fa309a0364a46c6f8bdda9f (diff)
Added no_scrub_restart flag to zpool reopen
Added -n flag to zpool reopen that allows a running scrub operation to continue if there is a device with Dirty Time Log. By default if a component device has a DTL and zpool reopen is executed all running scan operations will be restarted. Added functional tests for `zpool reopen` Tests covers following scenarios: * `zpool reopen` without arguments, * `zpool reopen` with pool name as argument, * `zpool reopen` while scrubbing, * `zpool reopen -n` while scrubbing, * `zpool reopen -n` while resilvering, * `zpool reopen` with bad arguments. Reviewed-by: Brian Behlendorf <[email protected]> Reviewed-by: Tom Caputi <[email protected]> Signed-off-by: Arkadiusz Bubała <[email protected]> Closes #6076 Closes #6746
Diffstat (limited to 'include')
-rw-r--r--include/libzfs.h3
-rw-r--r--include/libzfs_core.h2
2 files changed, 4 insertions, 1 deletions
diff --git a/include/libzfs.h b/include/libzfs.h
index 7ef250f02..1244bf0e4 100644
--- a/include/libzfs.h
+++ b/include/libzfs.h
@@ -27,6 +27,7 @@
* Copyright (c) 2016, Intel Corporation.
* Copyright 2016 Nexenta Systems, Inc.
* Copyright (c) 2017 Datto Inc.
+ * Copyright (c) 2017 Open-E, Inc. All Rights Reserved.
*/
#ifndef _LIBZFS_H
@@ -266,7 +267,7 @@ typedef struct splitflags {
extern int zpool_scan(zpool_handle_t *, pool_scan_func_t, pool_scrub_cmd_t);
extern int zpool_clear(zpool_handle_t *, const char *, nvlist_t *);
extern int zpool_reguid(zpool_handle_t *);
-extern int zpool_reopen(zpool_handle_t *);
+extern int zpool_reopen_one(zpool_handle_t *, void *);
extern int zpool_sync_one(zpool_handle_t *, void *);
diff --git a/include/libzfs_core.h b/include/libzfs_core.h
index 46e9641d3..9f914e54f 100644
--- a/include/libzfs_core.h
+++ b/include/libzfs_core.h
@@ -23,6 +23,7 @@
* Copyright (c) 2012, 2014 by Delphix. All rights reserved.
* Copyright (c) 2017 Datto Inc.
* Copyright 2017 RackTop Systems.
+ * Copyright (c) 2017 Open-E, Inc. All Rights Reserved.
*/
#ifndef _LIBZFS_CORE_H
@@ -101,6 +102,7 @@ int lzc_rollback(const char *, char *, int);
int lzc_rollback_to(const char *, const char *);
int lzc_sync(const char *, nvlist_t *, nvlist_t **);
+int lzc_reopen(const char *, boolean_t);
#ifdef __cplusplus
}