Some of the test assume the file system name is lustre
which is not always the case.
Change-Id: I582aa81fce5d1a881837dfa28bb0d6d84cfb5547
Signed-off-by: James Simmons <uja.ornl@gmail.com>
Reviewed-on: http://review.whamcloud.com/253
Tested-by: Hudson
Reviewed-by: Brian J. Murrell <brian@whamcloud.com>
Reviewed-by: Yu Jian <yujian@whamcloud.com>
Tested-by: Yu Jian <yujian@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
do_facet $SINGLEMDS lctl pool_remove $FSNAME.$POOL OST0000
drain_pool $POOL
do_facet $SINGLEMDS lctl pool_remove $FSNAME.$POOL OST0000
drain_pool $POOL
do_facet $SINGLEMDS lctl pool_add $FSNAME.$POOL $FSNAME-OST0000
RC=$?; [[ $RC -eq 0 ]] || \
error "pool_add failed. $FSNAME $POOL $FSNAME-OST0000: $RC"
do_facet $SINGLEMDS lctl pool_remove $FSNAME.$POOL $FSNAME-OST0000
drain_pool $POOL
do_facet $SINGLEMDS lctl pool_add $FSNAME.$POOL $FSNAME-OST0000
RC=$?; [[ $RC -eq 0 ]] || \
error "pool_add failed. $FSNAME $POOL $FSNAME-OST0000: $RC"
do_facet $SINGLEMDS lctl pool_remove $FSNAME.$POOL $FSNAME-OST0000
drain_pool $POOL
- # 3. lustre-OST0000_UUID
+ # 3. $FSNAME-OST0000_UUID
do_facet $SINGLEMDS lctl pool_add $FSNAME.$POOL $FSNAME-OST0000_UUID
RC=$?; [[ $RC -eq 0 ]] || \
error "pool_add failed. $FSNAME $POOL $FSNAME-OST0000_UUID: $RC"
do_facet $SINGLEMDS lctl pool_remove $FSNAME.$POOL $FSNAME-OST0000_UUID
drain_pool $POOL
do_facet $SINGLEMDS lctl pool_add $FSNAME.$POOL $FSNAME-OST0000_UUID
RC=$?; [[ $RC -eq 0 ]] || \
error "pool_add failed. $FSNAME $POOL $FSNAME-OST0000_UUID: $RC"
do_facet $SINGLEMDS lctl pool_remove $FSNAME.$POOL $FSNAME-OST0000_UUID
drain_pool $POOL
- # 4. lustre-OST[0,1,2,3,]
+ # 4. $FSNAME-OST[0,1,2,3,]
TGT="$FSNAME-OST["
for i in $TGT_LIST; do TGT=${TGT}$(printf "$i," $i); done
TGT="${TGT}]"
TGT="$FSNAME-OST["
for i in $TGT_LIST; do TGT=${TGT}$(printf "$i," $i); done
TGT="${TGT}]"
do_facet $SINGLEMDS lctl pool_remove $FSNAME.$POOL $TGT
drain_pool $POOL
do_facet $SINGLEMDS lctl pool_remove $FSNAME.$POOL $TGT
drain_pool $POOL
+ # 5. $FSNAME-OST[0-5/1]
do_facet $SINGLEMDS lctl pool_add $FSNAME.$POOL $TGT_ALL
RC=$?; [[ $RC -eq 0 ]] || \
error "pool_add failed. $FSNAME $POOL" "$TGT_ALL $RC"
do_facet $SINGLEMDS lctl pool_add $FSNAME.$POOL $TGT_ALL
RC=$?; [[ $RC -eq 0 ]] || \
error "pool_add failed. $FSNAME $POOL" "$TGT_ALL $RC"
for ostnum in $(seq $OSTCOUNT); do
# test-framework's OST numbering is one-based, while Lustre's
# is zero-based
for ostnum in $(seq $OSTCOUNT); do
# test-framework's OST numbering is one-based, while Lustre's
# is zero-based
- ostname=$(printf "lustre-OST%.4d" $((ostnum - 1)))
+ ostname=$(printf "$FSNAME-OST%.4d" $((ostnum - 1)))
# Parsing llobdstat's output sucks; we could grep the /proc
# path, but that's likely to not be as portable as using the
# llobdstat utility. So we parse lctl output instead.
# Parsing llobdstat's output sucks; we could grep the /proc
# path, but that's likely to not be as portable as using the
# llobdstat utility. So we parse lctl output instead.
# Total up write_bytes after writing. We'd better find non-zeros.
for ostnum in $(seq $OSTCOUNT); do
# Total up write_bytes after writing. We'd better find non-zeros.
for ostnum in $(seq $OSTCOUNT); do
- ostname=$(printf "lustre-OST%.4d" $((ostnum - 1)))
+ ostname=$(printf "$FSNAME-OST%.4d" $((ostnum - 1)))
write_bytes=$(do_facet ost$ostnum lctl get_param -n \
obdfilter/$ostname/stats |
awk '/^write_bytes/ {print $7}' )
write_bytes=$(do_facet ost$ostnum lctl get_param -n \
obdfilter/$ostname/stats |
awk '/^write_bytes/ {print $7}' )
if $all_zeros
then
for ostnum in $(seq $OSTCOUNT); do
if $all_zeros
then
for ostnum in $(seq $OSTCOUNT); do
- ostname=$(printf "lustre-OST%.4d" $((ostnum - 1)))
+ ostname=$(printf "$FSNAME-OST%.4d" $((ostnum - 1)))
echo "Check that write_bytes is present in obdfilter/*/stats:"
do_facet ost$ostnum lctl get_param -n \
obdfilter/$ostname/stats
echo "Check that write_bytes is present in obdfilter/*/stats:"
do_facet ost$ostnum lctl get_param -n \
obdfilter/$ostname/stats