Home
last modified time | relevance | path

Searched refs:nvroot (Results 1 – 17 of 17) sorted by relevance

/illumos-gate/usr/src/lib/libzfs/common/
H A Dlibzfs_status.c204 nvlist_t *nvroot; in check_status() local
219 &nvroot) == 0); in check_status()
220 verify(nvlist_lookup_uint64_array(nvroot, ZPOOL_CONFIG_VDEV_STATS, in check_status()
228 (void) nvlist_lookup_uint64_array(nvroot, ZPOOL_CONFIG_SCAN_STATS, in check_status()
318 find_vdev_problem(nvroot, vdev_faulted)) in check_status()
322 find_vdev_problem(nvroot, vdev_missing)) in check_status()
326 find_vdev_problem(nvroot, vdev_broken)) in check_status()
348 if (find_vdev_problem(nvroot, vdev_faulted)) in check_status()
350 if (find_vdev_problem(nvroot, vdev_missing)) in check_status()
352 if (find_vdev_problem(nvroot, vdev_broken)) in check_status()
[all …]
H A Dlibzfs_import.c296 nvlist_t *nvroot; in find_aux() local
299 &nvroot) == 0); in find_aux()
301 if (nvlist_lookup_nvlist_array(nvroot, cbp->cb_type, in find_aux()
404 nvlist_t *nvroot; in zpool_in_use() local
407 ZPOOL_CONFIG_VDEV_TREE, &nvroot) == 0); in zpool_in_use()
408 ret = find_guid(nvroot, vdev_guid); in zpool_in_use()
H A Dlibzfs_pool.c259 nvlist_t *nvroot; in zpool_get_prop() local
370 ZPOOL_CONFIG_VDEV_TREE, &nvroot) == 0); in zpool_get_prop()
371 verify(nvlist_lookup_uint64_array(nvroot, in zpool_get_prop()
1163 zpool_has_special_vdev(nvlist_t *nvroot) in zpool_has_special_vdev() argument
1168 if (nvlist_lookup_nvlist_array(nvroot, ZPOOL_CONFIG_CHILDREN, &child, in zpool_has_special_vdev()
1189 zpool_create(libzfs_handle_t *hdl, const char *pool, nvlist_t *nvroot, in zpool_create() argument
1207 if (zcmd_write_conf_nvlist(hdl, &zc, nvroot) != 0) in zpool_create()
1234 !zpool_has_special_vdev(nvroot)) { in zpool_create()
1440 zpool_add(zpool_handle_t *zhp, nvlist_t *nvroot) in zpool_add() argument
1454 nvlist_lookup_nvlist_array(nvroot, ZPOOL_CONFIG_SPARES, in zpool_add()
[all …]
/illumos-gate/usr/src/cmd/syseventd/modules/zfs_mod/
H A Dzfs_mod.c110 nvlist_t *nvroot; in zfs_toplevel_state() local
115 ZPOOL_CONFIG_VDEV_TREE, &nvroot) == 0); in zfs_toplevel_state()
116 verify(nvlist_lookup_uint64_array(nvroot, ZPOOL_CONFIG_VDEV_STATS, in zfs_toplevel_state()
155 nvlist_t *nvroot, *newvd; in zfs_process_add() local
246 if (nvlist_alloc(&nvroot, NV_UNIQUE_NAME, 0) != 0) in zfs_process_add()
250 nvlist_free(nvroot); in zfs_process_add()
259 nvlist_add_string(nvroot, ZPOOL_CONFIG_TYPE, VDEV_TYPE_ROOT) != 0 || in zfs_process_add()
260 nvlist_add_nvlist_array(nvroot, ZPOOL_CONFIG_CHILDREN, &newvd, in zfs_process_add()
263 nvlist_free(nvroot); in zfs_process_add()
269 (void) zpool_vdev_attach(zhp, fullpath, path, nvroot, B_TRUE); in zfs_process_add()
[all …]
/illumos-gate/usr/src/cmd/bhyve/test/tests/mevent/
H A Dvnode_zvol.c84 nvlist_t *nvroot, *props; in create_zpool() local
87 nvroot = fnvlist_alloc(); in create_zpool()
95 fnvlist_add_string(nvroot, ZPOOL_CONFIG_TYPE, VDEV_TYPE_ROOT); in create_zpool()
96 fnvlist_add_nvlist_array(nvroot, ZPOOL_CONFIG_CHILDREN, vdevs, 1); in create_zpool()
101 if (zpool_create(zfshdl, pool, nvroot, NULL, props) != 0) { in create_zpool()
/illumos-gate/usr/src/cmd/fm/modules/common/zfs-retire/
H A Dzfs_retire.c157 nvlist_t *config, *nvroot; in find_by_guid() local
169 &nvroot) != 0) { in find_by_guid()
175 if ((*vdevp = find_vdev(zhdl, nvroot, NULL, in find_by_guid()
190 nvlist_t *nvroot; in search_pool() local
194 &nvroot) != 0) { in search_pool()
199 if ((cbp->cb_vdev = find_vdev(zpool_get_handle(zhp), nvroot, in search_pool()
263 nvlist_t *config, *nvroot, *replacement; in replace_with_spare() local
274 &nvroot) != 0) { in replace_with_spare()
281 if (nvlist_lookup_nvlist_array(nvroot, ZPOOL_CONFIG_SPARES, in replace_with_spare()
/illumos-gate/usr/src/lib/libzpool/common/
H A Dutil.c135 nvlist_t *config, *nvroot; in show_pool_stats() local
141 &nvroot) == 0); in show_pool_stats()
145 show_vdev_stats(name, ZPOOL_CONFIG_CHILDREN, nvroot, 0); in show_pool_stats()
146 show_vdev_stats(NULL, ZPOOL_CONFIG_L2CACHE, nvroot, 0); in show_pool_stats()
147 show_vdev_stats(NULL, ZPOOL_CONFIG_SPARES, nvroot, 0); in show_pool_stats()
/illumos-gate/usr/src/cmd/zpool/
H A Dzpool_vdev.c591 get_replication(nvlist_t *nvroot, boolean_t fatal) in get_replication() argument
607 verify(nvlist_lookup_nvlist_array(nvroot, ZPOOL_CONFIG_CHILDREN, in get_replication()
886 nvlist_t *nvroot; in check_replication() local
889 &nvroot) == 0); in check_replication()
890 if ((current = get_replication(nvroot, B_FALSE)) == NULL) in check_replication()
1117 nvlist_t *nvroot; in is_spare() local
1140 &nvroot) == 0); in is_spare()
1141 if (nvlist_lookup_nvlist_array(nvroot, ZPOOL_CONFIG_SPARES, in is_spare()
1297 nvlist_t *nvroot, *nv, **top, **spares, **l2cache; in construct_spec() local
1518 verify(nvlist_alloc(&nvroot, NV_UNIQUE_NAME, 0) == 0); in construct_spec()
[all …]
H A Dzpool_main.c410 zpool_collect_leaves(zpool_handle_t *zhp, nvlist_t *nvroot, nvlist_t *res) in zpool_collect_leaves() argument
416 (void) nvlist_lookup_nvlist_array(nvroot, ZPOOL_CONFIG_CHILDREN, in zpool_collect_leaves()
420 char *path = zpool_vdev_name(g_zfs, zhp, nvroot, 0); in zpool_collect_leaves()
686 nvlist_t *nvroot; in zpool_do_add() local
783 nvroot = make_root_vdev(zhp, props, force, !force, B_FALSE, dryrun, in zpool_do_add()
785 if (nvroot == NULL) { in zpool_do_add()
802 print_vdev_tree(zhp, NULL, nvroot, 0, "", name_flags); in zpool_do_add()
807 print_vdev_tree(zhp, NULL, nvroot, 0, VDEV_ALLOC_BIAS_DEDUP, in zpool_do_add()
812 print_vdev_tree(zhp, NULL, nvroot, 0, VDEV_ALLOC_BIAS_SPECIAL, in zpool_do_add()
817 print_vdev_tree(zhp, NULL, nvroot, 0, VDEV_ALLOC_BIAS_LOG, in zpool_do_add()
[all …]
H A Dzpool_iter.c315 nvlist_t *config, *nvroot; in for_each_vdev() local
319 &nvroot) == 0); in for_each_vdev()
321 return (for_each_vdev_cb(zhp, nvroot, func, data)); in for_each_vdev()
/illumos-gate/usr/src/lib/libzutil/common/
H A Dzutil_import.c475 nvlist_t *ret = NULL, *config = NULL, *tmp = NULL, *nvtop, *nvroot; in get_configs() local
742 if (nvlist_alloc(&nvroot, NV_UNIQUE_NAME, 0) != 0) in get_configs()
744 if (nvlist_add_string(nvroot, ZPOOL_CONFIG_TYPE, in get_configs()
746 nvlist_add_uint64(nvroot, ZPOOL_CONFIG_ID, 0ULL) != 0 || in get_configs()
747 nvlist_add_uint64(nvroot, ZPOOL_CONFIG_GUID, guid) != 0 || in get_configs()
748 nvlist_add_nvlist_array(nvroot, ZPOOL_CONFIG_CHILDREN, in get_configs()
750 nvlist_free(nvroot); in get_configs()
764 if (fix_paths(nvroot, pl->names) != 0) { in get_configs()
765 nvlist_free(nvroot); in get_configs()
773 nvroot) != 0) { in get_configs()
[all …]
/illumos-gate/usr/src/cmd/fm/schemes/zfs/
H A Dscheme.c134 nvlist_t *config, *nvroot; in find_vdev() local
138 (void) nvlist_lookup_nvlist(config, ZPOOL_CONFIG_VDEV_TREE, &nvroot); in find_vdev()
140 return (find_vdev_iter(nvroot, guid)); in find_vdev()
/illumos-gate/usr/src/uts/common/fs/zfs/
H A Dspa_config.c366 nvlist_t *config, *nvroot; in spa_config_generate() local
469 nvroot = vdev_config_generate(spa, vd, getstats, config_gen_flags); in spa_config_generate()
470 fnvlist_add_nvlist(config, ZPOOL_CONFIG_VDEV_TREE, nvroot); in spa_config_generate()
471 nvlist_free(nvroot); in spa_config_generate()
H A Dspa.c4685 nvlist_t *nvroot; local
4697 ZPOOL_CONFIG_VDEV_TREE, &nvroot) == 0);
4701 VERIFY(nvlist_add_nvlist_array(nvroot,
4703 VERIFY(nvlist_lookup_nvlist_array(nvroot,
4734 nvlist_t *nvroot; local
4746 ZPOOL_CONFIG_VDEV_TREE, &nvroot) == 0);
4750 VERIFY(nvlist_add_nvlist_array(nvroot,
4752 VERIFY(nvlist_lookup_nvlist_array(nvroot,
4903 spa_validate_aux_devs(spa_t *spa, nvlist_t *nvroot, uint64_t crtxg, int mode, argument
4917 if (nvlist_lookup_nvlist_array(nvroot, config, &dev, &ndev) != 0)
[all …]
/illumos-gate/usr/src/cmd/ztest/
H A Dztest.c2601 nvlist_t *nvroot; in ztest_spa_create_destroy() local
2609 nvroot = make_vdev_root("/dev/bogus", NULL, NULL, 0, 0, NULL, 0, 0, 1); in ztest_spa_create_destroy()
2611 spa_create("ztest_bad_file", nvroot, NULL, NULL, NULL)); in ztest_spa_create_destroy()
2612 nvlist_free(nvroot); in ztest_spa_create_destroy()
2617 nvroot = make_vdev_root("/dev/bogus", NULL, NULL, 0, 0, NULL, 0, 2, 1); in ztest_spa_create_destroy()
2619 spa_create("ztest_bad_mirror", nvroot, NULL, NULL, NULL)); in ztest_spa_create_destroy()
2620 nvlist_free(nvroot); in ztest_spa_create_destroy()
2627 nvroot = make_vdev_root("/dev/bogus", NULL, NULL, 0, 0, NULL, 0, 0, 1); in ztest_spa_create_destroy()
2629 spa_create(zo->zo_pool, nvroot, NULL, NULL, NULL)); in ztest_spa_create_destroy()
2630 nvlist_free(nvroot); in ztest_spa_create_destroy()
[all …]
/illumos-gate/usr/src/cmd/power/
H A Dhandlers.c1006 nvlist_t *config, *nvroot; in ztop() local
1034 &nvroot) != 0) { in ztop()
1039 verify(nvlist_lookup_nvlist_array(nvroot, ZPOOL_CONFIG_CHILDREN, in ztop()
/illumos-gate/usr/src/uts/common/fs/zfs/sys/
H A Dspa.h725 extern int spa_create(const char *pool, nvlist_t *nvroot, nvlist_t *props,
768 extern int spa_vdev_add(spa_t *spa, nvlist_t *nvroot);
769 extern int spa_vdev_attach(spa_t *spa, uint64_t guid, nvlist_t *nvroot,