d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# CDDL HEADER START
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# The contents of this file are subject to the terms of the
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# Common Development and Distribution License (the "License").
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# You may not use this file except in compliance with the License.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# or http://www.opensolaris.org/os/licensing.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# See the License for the specific language governing permissions
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# and limitations under the License.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# When distributing Covered Code, include this CDDL HEADER in each
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# If applicable, add the following below this CDDL HEADER, with the
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# fields enclosed by brackets "[]" replaced with your own identifying
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# information: Portions Copyright [yyyy] [name of copyright owner]
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# CDDL HEADER END
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# Copyright 2009 Sun Microsystems, Inc. All rights reserved.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# Use is subject to license terms.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# Copyright (c) 2012 by Delphix. All rights reserved.
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankov# Copyright 2015 Nexenta Systems, Inc. All rights reserved.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy#
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# The following variable names describe files, stored as gzip compressed files
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# in the test directory which can be used to construct a pool of a given
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# version. The variable names are important, in that the construction
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# ZPOOL_VERSION_$var_FILES describes the files the pool is made from, and
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# ZPOOL_VERSION_$var_NAME describes the pool name.
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankov# v1 pools
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_1_FILES="zfs-pool-v1.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_1_NAME="v1-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v1 stripe
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_1stripe_FILES="zfs-pool-v1stripe1.dat \
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedyzfs-pool-v1stripe2.dat zfs-pool-v1stripe3.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_1stripe_NAME="pool-v1stripe"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v1 raidz
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_1raidz_FILES="zfs-pool-v1raidz1.dat zfs-pool-v1raidz2.dat \
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedyzfs-pool-v1raidz3.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_1raidz_NAME="pool-v1raidz"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v1 mirror
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_1mirror_FILES="zfs-pool-v1mirror1.dat zfs-pool-v1mirror2.dat \
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankovzfs-pool-v1mirror3.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_1mirror_NAME="pool-v1mirror"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankov# v2 pools
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_2_FILES="zfs-pool-v2.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_2_NAME="v2-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v2 stripe
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_2stripe_FILES="zfs-pool-v2stripe1.dat zfs-pool-v2stripe2.dat \
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankovzfs-pool-v2stripe3.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_2stripe_NAME="pool-v2stripe"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v2 raidz
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_2raidz_FILES="zfs-pool-v2raidz1.dat zfs-pool-v2raidz2.dat \
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedyzfs-pool-v2raidz3.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_2raidz_NAME="pool-v2raidz"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v2 mirror
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_2mirror_FILES="zfs-pool-v2mirror1.dat zfs-pool-v2mirror2.dat \
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankovzfs-pool-v2mirror3.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_2mirror_NAME="pool-v2mirror"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankov# v3 pools
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_3_FILES="zfs-pool-v3.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_3_NAME="v3-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v3 stripe
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_3stripe_FILES="zfs-pool-v3stripe1.dat zfs-pool-v3stripe2.dat \
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankovzfs-pool-v3stripe3.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_3stripe_NAME="pool-v3stripe"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v3 raidz
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_3raidz_FILES="zfs-pool-v3raidz1.dat zfs-pool-v3raidz2.dat \
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedyzfs-pool-v3raidz3.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_3raidz_NAME="pool-v3raidz"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v3 mirror
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_3mirror_FILES="zfs-pool-v3mirror1.dat zfs-pool-v3mirror2.dat \
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankovzfs-pool-v3mirror3.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_3mirror_NAME="pool-v3mirror"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v3 raidz2
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_3dblraidz_FILES="zfs-pool-v3raidz21.dat zfs-pool-v3raidz22.dat \
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankovzfs-pool-v3raidz23.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_3dblraidz_NAME="pool-v3raidz2"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v3 hotspares
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_3hotspare_FILES="zfs-pool-v3hotspare1.dat \
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedyzfs-pool-v3hotspare2.dat zfs-pool-v3hotspare3.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_3hotspare_NAME="pool-v3hotspare"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v4 pool
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_4_FILES="zfs-pool-v4.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_4_NAME="v4-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v5 pool
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_5_FILES="zfs-pool-v5.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_5_NAME="v5-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v6 pool
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_6_FILES="zfs-pool-v6.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_6_NAME="v6-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v7 pool
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_7_FILES="zfs-pool-v7.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_7_NAME="v7-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v8 pool
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_8_FILES="zfs-pool-v8.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_8_NAME="v8-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v9 pool
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_9_FILES="zfs-pool-v9.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_9_NAME="v9-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v10 pool
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_10_FILES="zfs-pool-v10.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_10_NAME="v10-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v11 pool
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_11_FILES="zfs-pool-v11.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_11_NAME="v11-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v12 pool
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_12_FILES="zfs-pool-v12.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_12_NAME="v12-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v13 pool
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_13_FILES="zfs-pool-v13.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_13_NAME="v13-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v14 pool
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_14_FILES="zfs-pool-v14.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_14_NAME="v14-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# v15 pool
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_15_FILES="zfs-pool-v15.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_15_NAME="v15-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankov# v2 pool, with device problems on one side of the mirror
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# so that the pool appears as DEGRADED
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_2brokenmirror_FILES="zfs-broken-mirror1.dat \
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedyzfs-broken-mirror2.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_2brokenmirror_NAME="zfs-broken-mirror"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankov# v999 pool (an unknown version) which can be used to check whether upgrade,
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankov# import or other tests that should fail against unknown pool version.
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankov# It should not be listed in the CONFIGS variable below, as these are pool
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankov# versions that can be imported and upgraded.
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_9999_FILES="zfs-pool-v999.dat"
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovZPOOL_VERSION_9999_NAME="v999-pool"
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# This is a list of pool configurations we should be able to upgrade from,
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# each entry should have corresponding ZPOOL_VERSION_*_FILES and
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy# ZPOOL_VERSION_*_NAME variables defined above.
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri PankovCONFIGS="1 1stripe 1raidz 1mirror \
d583b39bfb4e2571d3e41097c5c357ffe353ad45John Wren Kennedy2 2stripe 2raidz 2mirror 2brokenmirror \
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankov3 3stripe 3raidz 3mirror 3dblraidz 3hotspare \
c2b09db8b5b01162dadf9205ddd83ccf4f7d5535Yuri Pankov4 5 6 7 8 9 10 11 12 13 14 15"