From 3500a145952e0dfb7b7efe1c6b7856319815628c Mon Sep 17 00:00:00 2001 From: LOLi Date: Thu, 22 Dec 2016 19:39:00 +0100 Subject: Don't persist temporary pool name on devices Fix a regression accidentally introduced by e0ab3ab. Additionally, add a new script zpool_import_014_pos.ksh to the ZFS test suite to exercise 'zpool import -t' functionality. Reviewed-by: Brian Behlendorf Signed-off-by: loli10K Closes #5466 Closes #5515 --- module/zfs/spa_config.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module') diff --git a/module/zfs/spa_config.c b/module/zfs/spa_config.c index a813dfbd0..4f5d16543 100644 --- a/module/zfs/spa_config.c +++ b/module/zfs/spa_config.c @@ -426,7 +426,7 @@ spa_config_generate(spa_t *spa, vdev_t *vd, uint64_t txg, int getstats) config = fnvlist_alloc(); fnvlist_add_uint64(config, ZPOOL_CONFIG_VERSION, spa_version(spa)); - fnvlist_add_string(config, ZPOOL_CONFIG_POOL_NAME, spa_name(spa)); + fnvlist_add_string(config, ZPOOL_CONFIG_POOL_NAME, pool_name); fnvlist_add_uint64(config, ZPOOL_CONFIG_POOL_STATE, spa_state(spa)); fnvlist_add_uint64(config, ZPOOL_CONFIG_POOL_TXG, txg); fnvlist_add_uint64(config, ZPOOL_CONFIG_POOL_GUID, spa_guid(spa)); -- cgit v1.2.3