2 # Copyright (C) 2008 Red Hat, Inc. All rights reserved.
4 # This copyrighted material is made available to anyone wishing to use,
5 # modify, copy, or redistribute it subject to the terms and conditions
6 # of the GNU General Public License v.2.
8 # You should have received a copy of the GNU General Public License
9 # along with this program; if not, write to the Free Software Foundation,
10 # Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
12 # 'Ensure that pvmove diagnoses PE-range values 2^32 and larger.'
18 lvcreate
-L4 -n"$lv" $vg
20 # Test for the bogus diagnostic reported in BZ 284771
21 # http://bugzilla.redhat.com/284771.
22 # 'run pvmove with an unrecognized LV name to show bad diagnostic'
23 not pvmove
-v -nbogus $dev1 $dev2 2> err
24 grep " Logical volume bogus not found." err
26 # With lvm-2.02.28 and earlier, on a system with 64-bit "long int",
27 # the PE range parsing code would accept values up to 2^64-1, but would
28 # silently truncate them to int32_t. I.e., $dev1:$(echo 2^32|bc) would be
29 # treated just like $dev1:0.
30 # 'run the offending pvmove command'
31 not pvmove
-v -n$lv $dev1:4294967296 $dev2