Print this page
NEX-4934 Add capability to remove special vdev
Reviewed by: Alex Aizman <alex.aizman@nexenta.com>
Reviewed by: Alek Pinchuk <alek.pinchuk@nexenta.com>

*** 19,28 **** --- 19,29 ---- * CDDL HEADER END */ /* * Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2012 by Delphix. All rights reserved. + * Copyright 2015 Nexenta Systems, Inc. All rights reserved. */ #include <libzfs.h> #include <sys/zfs_context.h>
*** 459,469 **** if ((zhp = zpool_open(g_zfs, pool)) == NULL) return (-1); record->zi_guid = strtoull(device, &end, 16); if (record->zi_guid == 0 || *end != '\0') { ! tgt = zpool_find_vdev(zhp, device, &isspare, &iscache, NULL); if (tgt == NULL) { (void) fprintf(stderr, "cannot find device '%s' in " "pool '%s'\n", device, pool); return (-1); --- 460,471 ---- if ((zhp = zpool_open(g_zfs, pool)) == NULL) return (-1); record->zi_guid = strtoull(device, &end, 16); if (record->zi_guid == 0 || *end != '\0') { ! tgt = zpool_find_vdev(zhp, device, &isspare, &iscache, NULL, ! NULL); if (tgt == NULL) { (void) fprintf(stderr, "cannot find device '%s' in " "pool '%s'\n", device, pool); return (-1);