1185029Spjd#!/bin/sh 2185029Spjd# $FreeBSD: releng/10.3/tools/regression/zfs/zpool/add/option-f_replication_level_mismatch_1.t 185029 2008-11-17 20:49:29Z pjd $ 3185029Spjd 4185029Spjddir=`dirname $0` 5185029Spjd. ${dir}/../../misc.sh 6185029Spjd 7185029Spjdecho "1..182" 8185029Spjd 9185029Spjddisks_create 9 10185029Spjdnames_create 1 11185029Spjd 12185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} 13185029Spjdexpect_fl ${ZPOOL} add ${name0} mirror ${disk2} ${disk3} ${disk4} 14185029Spjdexp=`( 15185029Spjd echo " pool: ${name0}" 16185029Spjd echo " state: ONLINE" 17185029Spjd echo " scrub: none requested" 18185029Spjd echo "config:" 19185029Spjd echo " NAME STATE READ WRITE CKSUM" 20185029Spjd echo " ${name0} ONLINE 0 0 0" 21185029Spjd echo " mirror ONLINE 0 0 0" 22185029Spjd echo " ${disk0} ONLINE 0 0 0" 23185029Spjd echo " ${disk1} ONLINE 0 0 0" 24185029Spjd echo "errors: No known data errors" 25185029Spjd)` 26185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 27185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 28185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 29185029Spjd 30185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} 31185029Spjdexpect_ok ${ZPOOL} add -f ${name0} mirror ${disk2} ${disk3} ${disk4} 32185029Spjdexp=`( 33185029Spjd echo " pool: ${name0}" 34185029Spjd echo " state: ONLINE" 35185029Spjd echo " scrub: none requested" 36185029Spjd echo "config:" 37185029Spjd echo " NAME STATE READ WRITE CKSUM" 38185029Spjd echo " ${name0} ONLINE 0 0 0" 39185029Spjd echo " mirror ONLINE 0 0 0" 40185029Spjd echo " ${disk0} ONLINE 0 0 0" 41185029Spjd echo " ${disk1} ONLINE 0 0 0" 42185029Spjd echo " mirror ONLINE 0 0 0" 43185029Spjd echo " ${disk2} ONLINE 0 0 0" 44185029Spjd echo " ${disk3} ONLINE 0 0 0" 45185029Spjd echo " ${disk4} ONLINE 0 0 0" 46185029Spjd echo "errors: No known data errors" 47185029Spjd)` 48185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 49185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 50185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 51185029Spjd 52185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} ${disk2} 53185029Spjdexpect_fl ${ZPOOL} add ${name0} mirror ${disk3} ${disk4} 54185029Spjdexp=`( 55185029Spjd echo " pool: ${name0}" 56185029Spjd echo " state: ONLINE" 57185029Spjd echo " scrub: none requested" 58185029Spjd echo "config:" 59185029Spjd echo " NAME STATE READ WRITE CKSUM" 60185029Spjd echo " ${name0} ONLINE 0 0 0" 61185029Spjd echo " mirror ONLINE 0 0 0" 62185029Spjd echo " ${disk0} ONLINE 0 0 0" 63185029Spjd echo " ${disk1} ONLINE 0 0 0" 64185029Spjd echo " ${disk2} ONLINE 0 0 0" 65185029Spjd echo "errors: No known data errors" 66185029Spjd)` 67185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 68185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 69185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 70185029Spjd 71185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} ${disk2} 72185029Spjdexpect_ok ${ZPOOL} add -f ${name0} mirror ${disk3} ${disk4} 73185029Spjdexp=`( 74185029Spjd echo " pool: ${name0}" 75185029Spjd echo " state: ONLINE" 76185029Spjd echo " scrub: none requested" 77185029Spjd echo "config:" 78185029Spjd echo " NAME STATE READ WRITE CKSUM" 79185029Spjd echo " ${name0} ONLINE 0 0 0" 80185029Spjd echo " mirror ONLINE 0 0 0" 81185029Spjd echo " ${disk0} ONLINE 0 0 0" 82185029Spjd echo " ${disk1} ONLINE 0 0 0" 83185029Spjd echo " ${disk2} ONLINE 0 0 0" 84185029Spjd echo " mirror ONLINE 0 0 0" 85185029Spjd echo " ${disk3} ONLINE 0 0 0" 86185029Spjd echo " ${disk4} ONLINE 0 0 0" 87185029Spjd echo "errors: No known data errors" 88185029Spjd)` 89185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 90185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 91185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 92185029Spjd 93185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz1 ${disk0} ${disk1} ${disk2} 94185029Spjdexpect_fl ${ZPOOL} add ${name0} raidz1 ${disk3} ${disk4} ${disk5} ${disk6} 95185029Spjdexp=`( 96185029Spjd echo " pool: ${name0}" 97185029Spjd echo " state: ONLINE" 98185029Spjd echo " scrub: none requested" 99185029Spjd echo "config:" 100185029Spjd echo " NAME STATE READ WRITE CKSUM" 101185029Spjd echo " ${name0} ONLINE 0 0 0" 102185029Spjd echo " raidz1 ONLINE 0 0 0" 103185029Spjd echo " ${disk0} ONLINE 0 0 0" 104185029Spjd echo " ${disk1} ONLINE 0 0 0" 105185029Spjd echo " ${disk2} ONLINE 0 0 0" 106185029Spjd echo "errors: No known data errors" 107185029Spjd)` 108185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 109185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 110185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 111185029Spjd 112185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz1 ${disk0} ${disk1} ${disk2} 113185029Spjdexpect_ok ${ZPOOL} add -f ${name0} raidz1 ${disk3} ${disk4} ${disk5} ${disk6} 114185029Spjdexp=`( 115185029Spjd echo " pool: ${name0}" 116185029Spjd echo " state: ONLINE" 117185029Spjd echo " scrub: none requested" 118185029Spjd echo "config:" 119185029Spjd echo " NAME STATE READ WRITE CKSUM" 120185029Spjd echo " ${name0} ONLINE 0 0 0" 121185029Spjd echo " raidz1 ONLINE 0 0 0" 122185029Spjd echo " ${disk0} ONLINE 0 0 0" 123185029Spjd echo " ${disk1} ONLINE 0 0 0" 124185029Spjd echo " ${disk2} ONLINE 0 0 0" 125185029Spjd echo " raidz1 ONLINE 0 0 0" 126185029Spjd echo " ${disk3} ONLINE 0 0 0" 127185029Spjd echo " ${disk4} ONLINE 0 0 0" 128185029Spjd echo " ${disk5} ONLINE 0 0 0" 129185029Spjd echo " ${disk6} ONLINE 0 0 0" 130185029Spjd echo "errors: No known data errors" 131185029Spjd)` 132185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 133185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 134185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 135185029Spjd 136185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz1 ${disk0} ${disk1} ${disk2} ${disk3} 137185029Spjdexpect_fl ${ZPOOL} add ${name0} raidz1 ${disk4} ${disk5} ${disk6} 138185029Spjdexp=`( 139185029Spjd echo " pool: ${name0}" 140185029Spjd echo " state: ONLINE" 141185029Spjd echo " scrub: none requested" 142185029Spjd echo "config:" 143185029Spjd echo " NAME STATE READ WRITE CKSUM" 144185029Spjd echo " ${name0} ONLINE 0 0 0" 145185029Spjd echo " raidz1 ONLINE 0 0 0" 146185029Spjd echo " ${disk0} ONLINE 0 0 0" 147185029Spjd echo " ${disk1} ONLINE 0 0 0" 148185029Spjd echo " ${disk2} ONLINE 0 0 0" 149185029Spjd echo " ${disk3} ONLINE 0 0 0" 150185029Spjd echo "errors: No known data errors" 151185029Spjd)` 152185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 153185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 154185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 155185029Spjd 156185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz1 ${disk0} ${disk1} ${disk2} ${disk3} 157185029Spjdexpect_ok ${ZPOOL} add -f ${name0} raidz1 ${disk4} ${disk5} ${disk6} 158185029Spjdexp=`( 159185029Spjd echo " pool: ${name0}" 160185029Spjd echo " state: ONLINE" 161185029Spjd echo " scrub: none requested" 162185029Spjd echo "config:" 163185029Spjd echo " NAME STATE READ WRITE CKSUM" 164185029Spjd echo " ${name0} ONLINE 0 0 0" 165185029Spjd echo " raidz1 ONLINE 0 0 0" 166185029Spjd echo " ${disk0} ONLINE 0 0 0" 167185029Spjd echo " ${disk1} ONLINE 0 0 0" 168185029Spjd echo " ${disk2} ONLINE 0 0 0" 169185029Spjd echo " ${disk3} ONLINE 0 0 0" 170185029Spjd echo " raidz1 ONLINE 0 0 0" 171185029Spjd echo " ${disk4} ONLINE 0 0 0" 172185029Spjd echo " ${disk5} ONLINE 0 0 0" 173185029Spjd echo " ${disk6} ONLINE 0 0 0" 174185029Spjd echo "errors: No known data errors" 175185029Spjd)` 176185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 177185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 178185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 179185029Spjd 180185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz2 ${disk0} ${disk1} ${disk2} ${disk3} 181185029Spjdexpect_fl ${ZPOOL} add ${name0} raidz2 ${disk4} ${disk5} ${disk6} ${disk7} ${disk8} 182185029Spjdexp=`( 183185029Spjd echo " pool: ${name0}" 184185029Spjd echo " state: ONLINE" 185185029Spjd echo " scrub: none requested" 186185029Spjd echo "config:" 187185029Spjd echo " NAME STATE READ WRITE CKSUM" 188185029Spjd echo " ${name0} ONLINE 0 0 0" 189185029Spjd echo " raidz2 ONLINE 0 0 0" 190185029Spjd echo " ${disk0} ONLINE 0 0 0" 191185029Spjd echo " ${disk1} ONLINE 0 0 0" 192185029Spjd echo " ${disk2} ONLINE 0 0 0" 193185029Spjd echo " ${disk3} ONLINE 0 0 0" 194185029Spjd echo "errors: No known data errors" 195185029Spjd)` 196185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 197185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 198185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 199185029Spjd 200185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz2 ${disk0} ${disk1} ${disk2} ${disk3} 201185029Spjdexpect_ok ${ZPOOL} add -f ${name0} raidz2 ${disk4} ${disk5} ${disk6} ${disk7} ${disk8} 202185029Spjdexp=`( 203185029Spjd echo " pool: ${name0}" 204185029Spjd echo " state: ONLINE" 205185029Spjd echo " scrub: none requested" 206185029Spjd echo "config:" 207185029Spjd echo " NAME STATE READ WRITE CKSUM" 208185029Spjd echo " ${name0} ONLINE 0 0 0" 209185029Spjd echo " raidz2 ONLINE 0 0 0" 210185029Spjd echo " ${disk0} ONLINE 0 0 0" 211185029Spjd echo " ${disk1} ONLINE 0 0 0" 212185029Spjd echo " ${disk2} ONLINE 0 0 0" 213185029Spjd echo " ${disk3} ONLINE 0 0 0" 214185029Spjd echo " raidz2 ONLINE 0 0 0" 215185029Spjd echo " ${disk4} ONLINE 0 0 0" 216185029Spjd echo " ${disk5} ONLINE 0 0 0" 217185029Spjd echo " ${disk6} ONLINE 0 0 0" 218185029Spjd echo " ${disk7} ONLINE 0 0 0" 219185029Spjd echo " ${disk8} ONLINE 0 0 0" 220185029Spjd echo "errors: No known data errors" 221185029Spjd)` 222185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 223185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 224185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 225185029Spjd 226185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz2 ${disk0} ${disk1} ${disk2} ${disk3} ${disk4} 227185029Spjdexpect_fl ${ZPOOL} add ${name0} raidz2 ${disk5} ${disk6} ${disk7} ${disk8} 228185029Spjdexp=`( 229185029Spjd echo " pool: ${name0}" 230185029Spjd echo " state: ONLINE" 231185029Spjd echo " scrub: none requested" 232185029Spjd echo "config:" 233185029Spjd echo " NAME STATE READ WRITE CKSUM" 234185029Spjd echo " ${name0} ONLINE 0 0 0" 235185029Spjd echo " raidz2 ONLINE 0 0 0" 236185029Spjd echo " ${disk0} ONLINE 0 0 0" 237185029Spjd echo " ${disk1} ONLINE 0 0 0" 238185029Spjd echo " ${disk2} ONLINE 0 0 0" 239185029Spjd echo " ${disk3} ONLINE 0 0 0" 240185029Spjd echo " ${disk4} ONLINE 0 0 0" 241185029Spjd echo "errors: No known data errors" 242185029Spjd)` 243185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 244185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 245185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 246185029Spjd 247185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz2 ${disk0} ${disk1} ${disk2} ${disk3} ${disk4} 248185029Spjdexpect_ok ${ZPOOL} add -f ${name0} raidz2 ${disk5} ${disk6} ${disk7} ${disk8} 249185029Spjdexp=`( 250185029Spjd echo " pool: ${name0}" 251185029Spjd echo " state: ONLINE" 252185029Spjd echo " scrub: none requested" 253185029Spjd echo "config:" 254185029Spjd echo " NAME STATE READ WRITE CKSUM" 255185029Spjd echo " ${name0} ONLINE 0 0 0" 256185029Spjd echo " raidz2 ONLINE 0 0 0" 257185029Spjd echo " ${disk0} ONLINE 0 0 0" 258185029Spjd echo " ${disk1} ONLINE 0 0 0" 259185029Spjd echo " ${disk2} ONLINE 0 0 0" 260185029Spjd echo " ${disk3} ONLINE 0 0 0" 261185029Spjd echo " ${disk4} ONLINE 0 0 0" 262185029Spjd echo " raidz2 ONLINE 0 0 0" 263185029Spjd echo " ${disk5} ONLINE 0 0 0" 264185029Spjd echo " ${disk6} ONLINE 0 0 0" 265185029Spjd echo " ${disk7} ONLINE 0 0 0" 266185029Spjd echo " ${disk8} ONLINE 0 0 0" 267185029Spjd echo "errors: No known data errors" 268185029Spjd)` 269185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 270185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 271185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 272185029Spjd 273185029Spjd 274185029Spjd 275185029Spjd 276185029Spjd 277185029Spjd 278185029Spjd 279185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} 280185029Spjdexpect_fl ${ZPOOL} add ${name0} raidz ${disk2} ${disk3} 281185029Spjdexp=`( 282185029Spjd echo " pool: ${name0}" 283185029Spjd echo " state: ONLINE" 284185029Spjd echo " scrub: none requested" 285185029Spjd echo "config:" 286185029Spjd echo " NAME STATE READ WRITE CKSUM" 287185029Spjd echo " ${name0} ONLINE 0 0 0" 288185029Spjd echo " mirror ONLINE 0 0 0" 289185029Spjd echo " ${disk0} ONLINE 0 0 0" 290185029Spjd echo " ${disk1} ONLINE 0 0 0" 291185029Spjd echo "errors: No known data errors" 292185029Spjd)` 293185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 294185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 295185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 296185029Spjd 297185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} 298185029Spjdexpect_ok ${ZPOOL} add -f ${name0} raidz ${disk2} ${disk3} 299185029Spjdexp=`( 300185029Spjd echo " pool: ${name0}" 301185029Spjd echo " state: ONLINE" 302185029Spjd echo " scrub: none requested" 303185029Spjd echo "config:" 304185029Spjd echo " NAME STATE READ WRITE CKSUM" 305185029Spjd echo " ${name0} ONLINE 0 0 0" 306185029Spjd echo " mirror ONLINE 0 0 0" 307185029Spjd echo " ${disk0} ONLINE 0 0 0" 308185029Spjd echo " ${disk1} ONLINE 0 0 0" 309185029Spjd echo " raidz1 ONLINE 0 0 0" 310185029Spjd echo " ${disk2} ONLINE 0 0 0" 311185029Spjd echo " ${disk3} ONLINE 0 0 0" 312185029Spjd echo "errors: No known data errors" 313185029Spjd)` 314185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 315185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 316185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 317185029Spjd 318185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz ${disk0} ${disk1} 319185029Spjdexpect_fl ${ZPOOL} add ${name0} mirror ${disk2} ${disk3} 320185029Spjdexp=`( 321185029Spjd echo " pool: ${name0}" 322185029Spjd echo " state: ONLINE" 323185029Spjd echo " scrub: none requested" 324185029Spjd echo "config:" 325185029Spjd echo " NAME STATE READ WRITE CKSUM" 326185029Spjd echo " ${name0} ONLINE 0 0 0" 327185029Spjd echo " raidz1 ONLINE 0 0 0" 328185029Spjd echo " ${disk0} ONLINE 0 0 0" 329185029Spjd echo " ${disk1} ONLINE 0 0 0" 330185029Spjd echo "errors: No known data errors" 331185029Spjd)` 332185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 333185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 334185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 335185029Spjd 336185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz ${disk0} ${disk1} 337185029Spjdexpect_ok ${ZPOOL} add -f ${name0} mirror ${disk2} ${disk3} 338185029Spjdexp=`( 339185029Spjd echo " pool: ${name0}" 340185029Spjd echo " state: ONLINE" 341185029Spjd echo " scrub: none requested" 342185029Spjd echo "config:" 343185029Spjd echo " NAME STATE READ WRITE CKSUM" 344185029Spjd echo " ${name0} ONLINE 0 0 0" 345185029Spjd echo " raidz1 ONLINE 0 0 0" 346185029Spjd echo " ${disk0} ONLINE 0 0 0" 347185029Spjd echo " ${disk1} ONLINE 0 0 0" 348185029Spjd echo " mirror ONLINE 0 0 0" 349185029Spjd echo " ${disk2} ONLINE 0 0 0" 350185029Spjd echo " ${disk3} ONLINE 0 0 0" 351185029Spjd echo "errors: No known data errors" 352185029Spjd)` 353185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 354185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 355185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 356185029Spjd 357185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} ${disk2} 358185029Spjdexpect_fl ${ZPOOL} add ${name0} raidz ${disk3} ${disk4} 359185029Spjdexp=`( 360185029Spjd echo " pool: ${name0}" 361185029Spjd echo " state: ONLINE" 362185029Spjd echo " scrub: none requested" 363185029Spjd echo "config:" 364185029Spjd echo " NAME STATE READ WRITE CKSUM" 365185029Spjd echo " ${name0} ONLINE 0 0 0" 366185029Spjd echo " mirror ONLINE 0 0 0" 367185029Spjd echo " ${disk0} ONLINE 0 0 0" 368185029Spjd echo " ${disk1} ONLINE 0 0 0" 369185029Spjd echo " ${disk2} ONLINE 0 0 0" 370185029Spjd echo "errors: No known data errors" 371185029Spjd)` 372185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 373185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 374185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 375185029Spjd 376185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} ${disk2} 377185029Spjdexpect_ok ${ZPOOL} add -f ${name0} raidz ${disk3} ${disk4} 378185029Spjdexp=`( 379185029Spjd echo " pool: ${name0}" 380185029Spjd echo " state: ONLINE" 381185029Spjd echo " scrub: none requested" 382185029Spjd echo "config:" 383185029Spjd echo " NAME STATE READ WRITE CKSUM" 384185029Spjd echo " ${name0} ONLINE 0 0 0" 385185029Spjd echo " mirror ONLINE 0 0 0" 386185029Spjd echo " ${disk0} ONLINE 0 0 0" 387185029Spjd echo " ${disk1} ONLINE 0 0 0" 388185029Spjd echo " ${disk2} ONLINE 0 0 0" 389185029Spjd echo " raidz1 ONLINE 0 0 0" 390185029Spjd echo " ${disk3} ONLINE 0 0 0" 391185029Spjd echo " ${disk4} ONLINE 0 0 0" 392185029Spjd echo "errors: No known data errors" 393185029Spjd)` 394185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 395185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 396185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 397185029Spjd 398185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} 399185029Spjdexpect_fl ${ZPOOL} add ${name0} raidz ${disk2} ${disk3} ${disk4} 400185029Spjdexp=`( 401185029Spjd echo " pool: ${name0}" 402185029Spjd echo " state: ONLINE" 403185029Spjd echo " scrub: none requested" 404185029Spjd echo "config:" 405185029Spjd echo " NAME STATE READ WRITE CKSUM" 406185029Spjd echo " ${name0} ONLINE 0 0 0" 407185029Spjd echo " mirror ONLINE 0 0 0" 408185029Spjd echo " ${disk0} ONLINE 0 0 0" 409185029Spjd echo " ${disk1} ONLINE 0 0 0" 410185029Spjd echo "errors: No known data errors" 411185029Spjd)` 412185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 413185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 414185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 415185029Spjd 416185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} 417185029Spjdexpect_ok ${ZPOOL} add -f ${name0} raidz ${disk2} ${disk3} ${disk4} 418185029Spjdexp=`( 419185029Spjd echo " pool: ${name0}" 420185029Spjd echo " state: ONLINE" 421185029Spjd echo " scrub: none requested" 422185029Spjd echo "config:" 423185029Spjd echo " NAME STATE READ WRITE CKSUM" 424185029Spjd echo " ${name0} ONLINE 0 0 0" 425185029Spjd echo " mirror ONLINE 0 0 0" 426185029Spjd echo " ${disk0} ONLINE 0 0 0" 427185029Spjd echo " ${disk1} ONLINE 0 0 0" 428185029Spjd echo " raidz1 ONLINE 0 0 0" 429185029Spjd echo " ${disk2} ONLINE 0 0 0" 430185029Spjd echo " ${disk3} ONLINE 0 0 0" 431185029Spjd echo " ${disk4} ONLINE 0 0 0" 432185029Spjd echo "errors: No known data errors" 433185029Spjd)` 434185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 435185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 436185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 437185029Spjd 438185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} 439185029Spjdexpect_fl ${ZPOOL} add ${name0} raidz2 ${disk2} ${disk3} ${disk4} 440185029Spjdexp=`( 441185029Spjd echo " pool: ${name0}" 442185029Spjd echo " state: ONLINE" 443185029Spjd echo " scrub: none requested" 444185029Spjd echo "config:" 445185029Spjd echo " NAME STATE READ WRITE CKSUM" 446185029Spjd echo " ${name0} ONLINE 0 0 0" 447185029Spjd echo " mirror ONLINE 0 0 0" 448185029Spjd echo " ${disk0} ONLINE 0 0 0" 449185029Spjd echo " ${disk1} ONLINE 0 0 0" 450185029Spjd echo "errors: No known data errors" 451185029Spjd)` 452185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 453185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 454185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 455185029Spjd 456185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} 457185029Spjdexpect_ok ${ZPOOL} add -f ${name0} raidz2 ${disk2} ${disk3} ${disk4} 458185029Spjdexp=`( 459185029Spjd echo " pool: ${name0}" 460185029Spjd echo " state: ONLINE" 461185029Spjd echo " scrub: none requested" 462185029Spjd echo "config:" 463185029Spjd echo " NAME STATE READ WRITE CKSUM" 464185029Spjd echo " ${name0} ONLINE 0 0 0" 465185029Spjd echo " mirror ONLINE 0 0 0" 466185029Spjd echo " ${disk0} ONLINE 0 0 0" 467185029Spjd echo " ${disk1} ONLINE 0 0 0" 468185029Spjd echo " raidz2 ONLINE 0 0 0" 469185029Spjd echo " ${disk2} ONLINE 0 0 0" 470185029Spjd echo " ${disk3} ONLINE 0 0 0" 471185029Spjd echo " ${disk4} ONLINE 0 0 0" 472185029Spjd echo "errors: No known data errors" 473185029Spjd)` 474185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 475185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 476185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 477185029Spjd 478185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} ${disk2} 479185029Spjdexpect_fl ${ZPOOL} add ${name0} raidz2 ${disk3} ${disk4} ${disk5} 480185029Spjdexp=`( 481185029Spjd echo " pool: ${name0}" 482185029Spjd echo " state: ONLINE" 483185029Spjd echo " scrub: none requested" 484185029Spjd echo "config:" 485185029Spjd echo " NAME STATE READ WRITE CKSUM" 486185029Spjd echo " ${name0} ONLINE 0 0 0" 487185029Spjd echo " mirror ONLINE 0 0 0" 488185029Spjd echo " ${disk0} ONLINE 0 0 0" 489185029Spjd echo " ${disk1} ONLINE 0 0 0" 490185029Spjd echo " ${disk2} ONLINE 0 0 0" 491185029Spjd echo "errors: No known data errors" 492185029Spjd)` 493185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 494185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 495185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 496185029Spjd 497185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} ${disk2} 498185029Spjdexpect_ok ${ZPOOL} add -f ${name0} raidz2 ${disk3} ${disk4} ${disk5} 499185029Spjdexp=`( 500185029Spjd echo " pool: ${name0}" 501185029Spjd echo " state: ONLINE" 502185029Spjd echo " scrub: none requested" 503185029Spjd echo "config:" 504185029Spjd echo " NAME STATE READ WRITE CKSUM" 505185029Spjd echo " ${name0} ONLINE 0 0 0" 506185029Spjd echo " mirror ONLINE 0 0 0" 507185029Spjd echo " ${disk0} ONLINE 0 0 0" 508185029Spjd echo " ${disk1} ONLINE 0 0 0" 509185029Spjd echo " ${disk2} ONLINE 0 0 0" 510185029Spjd echo " raidz2 ONLINE 0 0 0" 511185029Spjd echo " ${disk3} ONLINE 0 0 0" 512185029Spjd echo " ${disk4} ONLINE 0 0 0" 513185029Spjd echo " ${disk5} ONLINE 0 0 0" 514185029Spjd echo "errors: No known data errors" 515185029Spjd)` 516185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 517185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 518185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 519185029Spjd 520185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} ${disk2} ${disk3} 521185029Spjdexpect_fl ${ZPOOL} add ${name0} raidz2 ${disk4} ${disk5} ${disk6} 522185029Spjdexp=`( 523185029Spjd echo " pool: ${name0}" 524185029Spjd echo " state: ONLINE" 525185029Spjd echo " scrub: none requested" 526185029Spjd echo "config:" 527185029Spjd echo " NAME STATE READ WRITE CKSUM" 528185029Spjd echo " ${name0} ONLINE 0 0 0" 529185029Spjd echo " mirror ONLINE 0 0 0" 530185029Spjd echo " ${disk0} ONLINE 0 0 0" 531185029Spjd echo " ${disk1} ONLINE 0 0 0" 532185029Spjd echo " ${disk2} ONLINE 0 0 0" 533185029Spjd echo " ${disk3} ONLINE 0 0 0" 534185029Spjd echo "errors: No known data errors" 535185029Spjd)` 536185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 537185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 538185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 539185029Spjd 540185029Spjdexpect_ok ${ZPOOL} create ${name0} mirror ${disk0} ${disk1} ${disk2} ${disk3} 541185029Spjdexpect_ok ${ZPOOL} add -f ${name0} raidz2 ${disk4} ${disk5} ${disk6} 542185029Spjdexp=`( 543185029Spjd echo " pool: ${name0}" 544185029Spjd echo " state: ONLINE" 545185029Spjd echo " scrub: none requested" 546185029Spjd echo "config:" 547185029Spjd echo " NAME STATE READ WRITE CKSUM" 548185029Spjd echo " ${name0} ONLINE 0 0 0" 549185029Spjd echo " mirror ONLINE 0 0 0" 550185029Spjd echo " ${disk0} ONLINE 0 0 0" 551185029Spjd echo " ${disk1} ONLINE 0 0 0" 552185029Spjd echo " ${disk2} ONLINE 0 0 0" 553185029Spjd echo " ${disk3} ONLINE 0 0 0" 554185029Spjd echo " raidz2 ONLINE 0 0 0" 555185029Spjd echo " ${disk4} ONLINE 0 0 0" 556185029Spjd echo " ${disk5} ONLINE 0 0 0" 557185029Spjd echo " ${disk6} ONLINE 0 0 0" 558185029Spjd echo "errors: No known data errors" 559185029Spjd)` 560185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 561185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 562185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 563185029Spjd 564185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz1 ${disk0} ${disk1} 565185029Spjdexpect_fl ${ZPOOL} add ${name0} raidz2 ${disk2} ${disk3} ${disk4} 566185029Spjdexp=`( 567185029Spjd echo " pool: ${name0}" 568185029Spjd echo " state: ONLINE" 569185029Spjd echo " scrub: none requested" 570185029Spjd echo "config:" 571185029Spjd echo " NAME STATE READ WRITE CKSUM" 572185029Spjd echo " ${name0} ONLINE 0 0 0" 573185029Spjd echo " raidz1 ONLINE 0 0 0" 574185029Spjd echo " ${disk0} ONLINE 0 0 0" 575185029Spjd echo " ${disk1} ONLINE 0 0 0" 576185029Spjd echo "errors: No known data errors" 577185029Spjd)` 578185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 579185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 580185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 581185029Spjd 582185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz1 ${disk0} ${disk1} 583185029Spjdexpect_ok ${ZPOOL} add -f ${name0} raidz2 ${disk2} ${disk3} ${disk4} 584185029Spjdexp=`( 585185029Spjd echo " pool: ${name0}" 586185029Spjd echo " state: ONLINE" 587185029Spjd echo " scrub: none requested" 588185029Spjd echo "config:" 589185029Spjd echo " NAME STATE READ WRITE CKSUM" 590185029Spjd echo " ${name0} ONLINE 0 0 0" 591185029Spjd echo " raidz1 ONLINE 0 0 0" 592185029Spjd echo " ${disk0} ONLINE 0 0 0" 593185029Spjd echo " ${disk1} ONLINE 0 0 0" 594185029Spjd echo " raidz2 ONLINE 0 0 0" 595185029Spjd echo " ${disk2} ONLINE 0 0 0" 596185029Spjd echo " ${disk3} ONLINE 0 0 0" 597185029Spjd echo " ${disk4} ONLINE 0 0 0" 598185029Spjd echo "errors: No known data errors" 599185029Spjd)` 600185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 601185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 602185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 603185029Spjd 604185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz1 ${disk0} ${disk1} ${disk2} 605185029Spjdexpect_fl ${ZPOOL} add ${name0} raidz2 ${disk3} ${disk4} ${disk5} 606185029Spjdexp=`( 607185029Spjd echo " pool: ${name0}" 608185029Spjd echo " state: ONLINE" 609185029Spjd echo " scrub: none requested" 610185029Spjd echo "config:" 611185029Spjd echo " NAME STATE READ WRITE CKSUM" 612185029Spjd echo " ${name0} ONLINE 0 0 0" 613185029Spjd echo " raidz1 ONLINE 0 0 0" 614185029Spjd echo " ${disk0} ONLINE 0 0 0" 615185029Spjd echo " ${disk1} ONLINE 0 0 0" 616185029Spjd echo " ${disk2} ONLINE 0 0 0" 617185029Spjd echo "errors: No known data errors" 618185029Spjd)` 619185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 620185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 621185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 622185029Spjd 623185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz1 ${disk0} ${disk1} ${disk2} 624185029Spjdexpect_ok ${ZPOOL} add -f ${name0} raidz2 ${disk3} ${disk4} ${disk5} 625185029Spjdexp=`( 626185029Spjd echo " pool: ${name0}" 627185029Spjd echo " state: ONLINE" 628185029Spjd echo " scrub: none requested" 629185029Spjd echo "config:" 630185029Spjd echo " NAME STATE READ WRITE CKSUM" 631185029Spjd echo " ${name0} ONLINE 0 0 0" 632185029Spjd echo " raidz1 ONLINE 0 0 0" 633185029Spjd echo " ${disk0} ONLINE 0 0 0" 634185029Spjd echo " ${disk1} ONLINE 0 0 0" 635185029Spjd echo " ${disk2} ONLINE 0 0 0" 636185029Spjd echo " raidz2 ONLINE 0 0 0" 637185029Spjd echo " ${disk3} ONLINE 0 0 0" 638185029Spjd echo " ${disk4} ONLINE 0 0 0" 639185029Spjd echo " ${disk5} ONLINE 0 0 0" 640185029Spjd echo "errors: No known data errors" 641185029Spjd)` 642185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 643185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 644185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 645185029Spjd 646185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz1 ${disk0} ${disk1} ${disk2} ${disk3} 647185029Spjdexpect_fl ${ZPOOL} add ${name0} raidz2 ${disk4} ${disk5} ${disk6} 648185029Spjdexp=`( 649185029Spjd echo " pool: ${name0}" 650185029Spjd echo " state: ONLINE" 651185029Spjd echo " scrub: none requested" 652185029Spjd echo "config:" 653185029Spjd echo " NAME STATE READ WRITE CKSUM" 654185029Spjd echo " ${name0} ONLINE 0 0 0" 655185029Spjd echo " raidz1 ONLINE 0 0 0" 656185029Spjd echo " ${disk0} ONLINE 0 0 0" 657185029Spjd echo " ${disk1} ONLINE 0 0 0" 658185029Spjd echo " ${disk2} ONLINE 0 0 0" 659185029Spjd echo " ${disk3} ONLINE 0 0 0" 660185029Spjd echo "errors: No known data errors" 661185029Spjd)` 662185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 663185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 664185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 665185029Spjd 666185029Spjdexpect_ok ${ZPOOL} create ${name0} raidz1 ${disk0} ${disk1} ${disk2} ${disk3} 667185029Spjdexpect_ok ${ZPOOL} add -f ${name0} raidz2 ${disk4} ${disk5} ${disk6} 668185029Spjdexp=`( 669185029Spjd echo " pool: ${name0}" 670185029Spjd echo " state: ONLINE" 671185029Spjd echo " scrub: none requested" 672185029Spjd echo "config:" 673185029Spjd echo " NAME STATE READ WRITE CKSUM" 674185029Spjd echo " ${name0} ONLINE 0 0 0" 675185029Spjd echo " raidz1 ONLINE 0 0 0" 676185029Spjd echo " ${disk0} ONLINE 0 0 0" 677185029Spjd echo " ${disk1} ONLINE 0 0 0" 678185029Spjd echo " ${disk2} ONLINE 0 0 0" 679185029Spjd echo " ${disk3} ONLINE 0 0 0" 680185029Spjd echo " raidz2 ONLINE 0 0 0" 681185029Spjd echo " ${disk4} ONLINE 0 0 0" 682185029Spjd echo " ${disk5} ONLINE 0 0 0" 683185029Spjd echo " ${disk6} ONLINE 0 0 0" 684185029Spjd echo "errors: No known data errors" 685185029Spjd)` 686185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 687185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 688185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 689185029Spjd 690185029Spjdexpect_ok ${ZPOOL} create ${name0} ${disk0} log mirror ${disk1} ${disk2} 691185029Spjdadd_msg="# TODO Sun CR 6726091, Lustre bug 16873" 692185029Spjdexpect_fl ${ZPOOL} add ${name0} log mirror ${disk3} ${disk4} ${disk5} 693185029Spjdexp=`( 694185029Spjd echo " pool: ${name0}" 695185029Spjd echo " state: ONLINE" 696185029Spjd echo " scrub: none requested" 697185029Spjd echo "config:" 698185029Spjd echo " NAME STATE READ WRITE CKSUM" 699185029Spjd echo " ${name0} ONLINE 0 0 0" 700185029Spjd echo " ${disk0} ONLINE 0 0 0" 701185029Spjd echo " logs ONLINE 0 0 0" 702185029Spjd echo " mirror ONLINE 0 0 0" 703185029Spjd echo " ${disk1} ONLINE 0 0 0" 704185029Spjd echo " ${disk2} ONLINE 0 0 0" 705185029Spjd echo "errors: No known data errors" 706185029Spjd)` 707185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 708185029Spjdadd_msg="" 709185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 710185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 711185029Spjd 712185029Spjdexpect_ok ${ZPOOL} create ${name0} ${disk0} log mirror ${disk1} ${disk2} 713185029Spjdexpect_ok ${ZPOOL} add -f ${name0} log mirror ${disk3} ${disk4} ${disk5} 714185029Spjdexp=`( 715185029Spjd echo " pool: ${name0}" 716185029Spjd echo " state: ONLINE" 717185029Spjd echo " scrub: none requested" 718185029Spjd echo "config:" 719185029Spjd echo " NAME STATE READ WRITE CKSUM" 720185029Spjd echo " ${name0} ONLINE 0 0 0" 721185029Spjd echo " ${disk0} ONLINE 0 0 0" 722185029Spjd echo " logs ONLINE 0 0 0" 723185029Spjd echo " mirror ONLINE 0 0 0" 724185029Spjd echo " ${disk1} ONLINE 0 0 0" 725185029Spjd echo " ${disk2} ONLINE 0 0 0" 726185029Spjd echo " mirror ONLINE 0 0 0" 727185029Spjd echo " ${disk3} ONLINE 0 0 0" 728185029Spjd echo " ${disk4} ONLINE 0 0 0" 729185029Spjd echo " ${disk5} ONLINE 0 0 0" 730185029Spjd echo "errors: No known data errors" 731185029Spjd)` 732185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 733185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 734185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 735185029Spjdexpect_fl ${ZPOOL} destroy ${name0} 736185029Spjd 737185029Spjdexpect_ok ${ZPOOL} create ${name0} ${disk0} log mirror ${disk1} ${disk2} ${disk3} 738185029Spjdadd_msg="# TODO Sun CR 6726091, Lustre bug 16873" 739185029Spjdexpect_fl ${ZPOOL} add ${name0} log mirror ${disk4} ${disk5} 740185029Spjdexp=`( 741185029Spjd echo " pool: ${name0}" 742185029Spjd echo " state: ONLINE" 743185029Spjd echo " scrub: none requested" 744185029Spjd echo "config:" 745185029Spjd echo " NAME STATE READ WRITE CKSUM" 746185029Spjd echo " ${name0} ONLINE 0 0 0" 747185029Spjd echo " ${disk0} ONLINE 0 0 0" 748185029Spjd echo " logs ONLINE 0 0 0" 749185029Spjd echo " mirror ONLINE 0 0 0" 750185029Spjd echo " ${disk1} ONLINE 0 0 0" 751185029Spjd echo " ${disk2} ONLINE 0 0 0" 752185029Spjd echo " ${disk3} ONLINE 0 0 0" 753185029Spjd echo "errors: No known data errors" 754185029Spjd)` 755185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 756185029Spjdadd_msg="" 757185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 758185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 759185029Spjd 760185029Spjdexpect_ok ${ZPOOL} create ${name0} ${disk0} log mirror ${disk1} ${disk2} ${disk3} 761185029Spjdexpect_ok ${ZPOOL} add -f ${name0} log mirror ${disk4} ${disk5} 762185029Spjdexp=`( 763185029Spjd echo " pool: ${name0}" 764185029Spjd echo " state: ONLINE" 765185029Spjd echo " scrub: none requested" 766185029Spjd echo "config:" 767185029Spjd echo " NAME STATE READ WRITE CKSUM" 768185029Spjd echo " ${name0} ONLINE 0 0 0" 769185029Spjd echo " ${disk0} ONLINE 0 0 0" 770185029Spjd echo " logs ONLINE 0 0 0" 771185029Spjd echo " mirror ONLINE 0 0 0" 772185029Spjd echo " ${disk1} ONLINE 0 0 0" 773185029Spjd echo " ${disk2} ONLINE 0 0 0" 774185029Spjd echo " ${disk3} ONLINE 0 0 0" 775185029Spjd echo " mirror ONLINE 0 0 0" 776185029Spjd echo " ${disk4} ONLINE 0 0 0" 777185029Spjd echo " ${disk5} ONLINE 0 0 0" 778185029Spjd echo "errors: No known data errors" 779185029Spjd)` 780185029Spjdexpect "${exp}" ${ZPOOL} status ${name0} 781185029Spjdexpect_ok ${ZPOOL} destroy ${name0} 782185029Spjdexpect_fl ${ZPOOL} status -x ${name0} 783185029Spjdexpect_fl ${ZPOOL} destroy ${name0} 784185029Spjd 785185029Spjddisks_destroy 786