zfs_snapshot_009_pos.ksh revision d583b39bfb4e2571d3e41097c5c357ffe353ad45
#
# This file and its contents are supplied under the terms of the
# Common Development and Distribution License ("CDDL"), version 1.0.
# You may only use this file in accordance with the terms of version
# 1.0 of the CDDL.
#
# A full copy of the text of the CDDL should have accompanied this
# source. A copy of the CDDL is also available via the Internet at
#
#
# Copyright (c) 2012 by Delphix. All rights reserved.
#
#
# DESCRIPTION
# verify 'zfs snapshot <list of snapshots>' works correctly
#
# STRATEGY
# 1. Create multiple datasets
# 2. Create mutiple snapshots with a list of valid and invalid
# snapshot names
# 3. Verify the valid snpashot creation
function cleanup
{
done
}
log_assert "verify zfs supports multiple consistent snapshots"
typeset -i i=1
log_note "destroy a list of valid snapshots"
done
i=0
while (( i < ${#valid_args[*]} )); do
log_must $ZFS snapshot ${valid_args[i]}
for token in ${valid_args[i]}; do
log_must snapexists $token && \
done
((i = i + 1))
done
log_note "destroy a list of invalid snapshots"
i=0
while (( i < ${#invalid_args[*]} )); do
log_mustnot $ZFS snapshot ${invalid_args[i]}
for token in ${invalid_args[i]}; do
done
((i = i + 1))
done
log_note "verify multiple snapshot transaction group"
for i in 1 2 3; do
&& log_fail "snapshots belong to differnt transaction groups"
done
log_note "verify snapshot contents"
"the filesystem"
done
log_note "verify multiple snapshot with -r option"
log_pass "zfs multiple snapshot verified correctly"