Re: [Gluster-devel] Spurious failure in tests/basic/bd.t [22, 23, 24, 25]
- Original Message - > From: "Bharata B Rao" > To: "Pranith Kumar Karampuri" > Cc: "jGluster Devel" , "M. Mohan Kumar" > > Sent: Friday, May 30, 2014 8:28:15 AM > Subject: Re: [Gluster-devel] Spurious failure in tests/basic/bd.t [22, 23, > 24, 25] > > CC'ing to the correct ID of Mohan Thanks! Pranith > > > On Fri, May 30, 2014 at 5:45 AM, Pranith Kumar Karampuri < > pkara...@redhat.com> wrote: > > > hi Mohan, > >Could you please look into this: > > Patch ==> http://review.gluster.com/#/c/7926/1 > > Author==> Avra Sengupta aseng...@redhat.com > > Build triggered by==> amarts > > Build-url ==> > > http://build.gluster.org/job/regression/4615/consoleFull > > Download-log-at ==> > > http://build.gluster.org:443/logs/regression/glusterfs-logs-20140529:10:51:46.tgz > > Test written by ==> Author: M. Mohan Kumar > > > > ./tests/basic/bd.t [22, 23, 24, 25] > > 0 #!/bin/bash > > 1 > > 2 . $(dirname $0)/../include.rc > > 3 > > 4 function execute() > > 5 { > > 6 cmd=$1 > > 7 shift > > 8 ${cmd} $@ >/dev/null 2>&1 > > 9 } > >10 > >11 function bd_cleanup() > >12 { > >13 execute vgremove -f ${V0} > >14 execute pvremove ${ld} > >15 execute losetup -d ${ld} > >16 execute rm ${BD_DISK} > >17 cleanup > >18 } > >19 > >20 function check() > >21 { > >22 if [ $? -ne 0 ]; then > >23 echo prerequsite $@ failed > >24 bd_cleanup > >25 exit > >26 fi > >27 } > >28 > >29 SIZE=256 #in MB > >30 > >31 bd_cleanup; > >32 > >33 ## Configure environment needed for BD backend volumes > >34 ## Create a file with configured size and > >35 ## set it as a temporary loop device to create > >36 ## physical volume & VG. These are basic things needed > >37 ## for testing BD xlator if anyone of these steps fail, > >38 ## test script exits > >39 function configure() > >40 { > >41 GLDIR=`$CLI system:: getwd` > >42 BD_DISK=${GLDIR}/bd_disk > >43 > >44 execute truncate -s${SIZE}M ${BD_DISK} > >45 check ${BD_DISK} creation > >46 > >47 execute losetup -f > >48 check losetup > >49 ld=`losetup -f` > >50 > >51 execute losetup ${ld} ${BD_DISK} > >52 check losetup ${BD_DISK} > >53 execute pvcreate -f ${ld} > >54 check pvcreate ${ld} > >55 execute vgcreate ${V0} ${ld} > >56 check vgcreate ${V0} > >57 execute lvcreate --thin ${V0}/pool --size 128M > >58 } > >59 > >60 function volinfo_field() > >61 { > >62 local vol=$1; > >63 local field=$2; > >64 $CLI volume info $vol | grep "^$field: " | sed 's/.*: //'; > >65 } > >66 > >67 function volume_type() > >68 { > >69 getfattr -n volume.type $M0/. --only-values --absolute-names > > -e text > >70 } > >71 > >72 TEST glusterd > >73 TEST pidof glusterd > >74 configure > >75 > >76 TEST $CLI volume create $V0 ${H0}:/$B0/$V0?${V0} > >77 EXPECT "$V0" volinfo_field $V0 'Volume Name'; > >78 EXPECT 'Created' volinfo_field $V0 'Status'; > >79 > >80 ## Start volume and verify > >81 TEST $CLI volume start $V0; > >82 EXPECT 'Started' volinfo_field $V0 'Status' > >83 > >84 TEST glusterfs --volfile-id=/$V0 --volfile-server=$H0 $M0 > >85 EXPECT '1' volume_type > >86 > >87 ## Create posix file > >88 TEST touch $M0/posix > >89 > >90 TEST touch $M0/lv > >91 gfid=`getfattr -n glusterfs.gfid.string $M0/lv --only-values > > --absolute-names` > >92 TEST setfattr -n user.glusterfs.bd -v "lv:4MB" $M0/lv > >93 # Check if LV is created > >94 TEST stat /dev/$V0/${gfid} > >95 > >96 ## Create filesystem > >97 sleep 1 > >98 TEST mkfs.ext4 -qF $M0/lv > >99 # Cl
Re: [Gluster-devel] Spurious failure in tests/basic/bd.t [22, 23, 24, 25]
CC'ing to the correct ID of Mohan On Fri, May 30, 2014 at 5:45 AM, Pranith Kumar Karampuri < pkara...@redhat.com> wrote: > hi Mohan, >Could you please look into this: > Patch ==> http://review.gluster.com/#/c/7926/1 > Author==> Avra Sengupta aseng...@redhat.com > Build triggered by==> amarts > Build-url ==> > http://build.gluster.org/job/regression/4615/consoleFull > Download-log-at ==> > http://build.gluster.org:443/logs/regression/glusterfs-logs-20140529:10:51:46.tgz > Test written by ==> Author: M. Mohan Kumar > > ./tests/basic/bd.t [22, 23, 24, 25] > 0 #!/bin/bash > 1 > 2 . $(dirname $0)/../include.rc > 3 > 4 function execute() > 5 { > 6 cmd=$1 > 7 shift > 8 ${cmd} $@ >/dev/null 2>&1 > 9 } >10 >11 function bd_cleanup() >12 { >13 execute vgremove -f ${V0} >14 execute pvremove ${ld} >15 execute losetup -d ${ld} >16 execute rm ${BD_DISK} >17 cleanup >18 } >19 >20 function check() >21 { >22 if [ $? -ne 0 ]; then >23 echo prerequsite $@ failed >24 bd_cleanup >25 exit >26 fi >27 } >28 >29 SIZE=256 #in MB >30 >31 bd_cleanup; >32 >33 ## Configure environment needed for BD backend volumes >34 ## Create a file with configured size and >35 ## set it as a temporary loop device to create >36 ## physical volume & VG. These are basic things needed >37 ## for testing BD xlator if anyone of these steps fail, >38 ## test script exits >39 function configure() >40 { >41 GLDIR=`$CLI system:: getwd` >42 BD_DISK=${GLDIR}/bd_disk >43 >44 execute truncate -s${SIZE}M ${BD_DISK} >45 check ${BD_DISK} creation >46 >47 execute losetup -f >48 check losetup >49 ld=`losetup -f` >50 >51 execute losetup ${ld} ${BD_DISK} >52 check losetup ${BD_DISK} >53 execute pvcreate -f ${ld} >54 check pvcreate ${ld} >55 execute vgcreate ${V0} ${ld} >56 check vgcreate ${V0} >57 execute lvcreate --thin ${V0}/pool --size 128M >58 } >59 >60 function volinfo_field() >61 { >62 local vol=$1; >63 local field=$2; >64 $CLI volume info $vol | grep "^$field: " | sed 's/.*: //'; >65 } >66 >67 function volume_type() >68 { >69 getfattr -n volume.type $M0/. --only-values --absolute-names > -e text >70 } >71 >72 TEST glusterd >73 TEST pidof glusterd >74 configure >75 >76 TEST $CLI volume create $V0 ${H0}:/$B0/$V0?${V0} >77 EXPECT "$V0" volinfo_field $V0 'Volume Name'; >78 EXPECT 'Created' volinfo_field $V0 'Status'; >79 >80 ## Start volume and verify >81 TEST $CLI volume start $V0; >82 EXPECT 'Started' volinfo_field $V0 'Status' >83 >84 TEST glusterfs --volfile-id=/$V0 --volfile-server=$H0 $M0 >85 EXPECT '1' volume_type >86 >87 ## Create posix file >88 TEST touch $M0/posix >89 >90 TEST touch $M0/lv >91 gfid=`getfattr -n glusterfs.gfid.string $M0/lv --only-values > --absolute-names` >92 TEST setfattr -n user.glusterfs.bd -v "lv:4MB" $M0/lv >93 # Check if LV is created >94 TEST stat /dev/$V0/${gfid} >95 >96 ## Create filesystem >97 sleep 1 >98 TEST mkfs.ext4 -qF $M0/lv >99 # Cloning > 100 TEST touch $M0/lv_clone > 101 gfid=`getfattr -n glusterfs.gfid.string $M0/lv_clone --only-values > --absolute-names` > 102 TEST setfattr -n clone -v ${gfid} $M0/lv > 103 TEST stat /dev/$V0/${gfid} > 104 > 105 sleep 1 > 106 ## Check mounting > 107 TEST mount -o loop $M0/lv $M1 > 108 umount $M1 > 109 > 110 # Snapshot > 111 TEST touch $M0/lv_sn > 112 gfid=`getfattr -n glusterfs.gfid.string $M0/lv_sn --only-values > --absolute-names` > 113 TEST setfattr -n snapshot -v ${gfid} $M0/lv > 114 TEST stat /dev/$V0/${gfid} > 115 > 116 # Merge > 117 sleep 1 > **118 TEST setfattr -n merge -v "$M0/lv_sn" $M0/lv_sn > **119 TEST ! stat $M0/lv_sn > **120 TEST ! stat /dev/$V0/${gfid} > 121 > 122 > 123 rm $M0/* -f > 124 > **125 TEST umount $M0 > 126 TEST $CLI volume stop ${V0} > 127 EXPECT 'Stopped' volinfo_field $V0 'Status'; > 128 TEST $CLI volume delete ${V0} > 129 > 130 bd_cleanup > > Pranith > ___ > Gluster-devel mailing list > Gluster-devel@gluster.org > http://supercolony.gluster.org/mailman/listinfo/gluster-devel > -- http://raobharata.wordpress.com/ ___ Gluster-devel mailing list Gluster-devel@gluster.org http://supercolony.gluster.org/mailman/listinfo/gluster-devel
[Gluster-devel] Spurious failure in tests/basic/bd.t [22, 23, 24, 25]
hi Mohan, Could you please look into this: Patch ==> http://review.gluster.com/#/c/7926/1 Author==> Avra Sengupta aseng...@redhat.com Build triggered by==> amarts Build-url ==> http://build.gluster.org/job/regression/4615/consoleFull Download-log-at ==> http://build.gluster.org:443/logs/regression/glusterfs-logs-20140529:10:51:46.tgz Test written by ==> Author: M. Mohan Kumar ./tests/basic/bd.t [22, 23, 24, 25] 0 #!/bin/bash 1 2 . $(dirname $0)/../include.rc 3 4 function execute() 5 { 6 cmd=$1 7 shift 8 ${cmd} $@ >/dev/null 2>&1 9 } 10 11 function bd_cleanup() 12 { 13 execute vgremove -f ${V0} 14 execute pvremove ${ld} 15 execute losetup -d ${ld} 16 execute rm ${BD_DISK} 17 cleanup 18 } 19 20 function check() 21 { 22 if [ $? -ne 0 ]; then 23 echo prerequsite $@ failed 24 bd_cleanup 25 exit 26 fi 27 } 28 29 SIZE=256 #in MB 30 31 bd_cleanup; 32 33 ## Configure environment needed for BD backend volumes 34 ## Create a file with configured size and 35 ## set it as a temporary loop device to create 36 ## physical volume & VG. These are basic things needed 37 ## for testing BD xlator if anyone of these steps fail, 38 ## test script exits 39 function configure() 40 { 41 GLDIR=`$CLI system:: getwd` 42 BD_DISK=${GLDIR}/bd_disk 43 44 execute truncate -s${SIZE}M ${BD_DISK} 45 check ${BD_DISK} creation 46 47 execute losetup -f 48 check losetup 49 ld=`losetup -f` 50 51 execute losetup ${ld} ${BD_DISK} 52 check losetup ${BD_DISK} 53 execute pvcreate -f ${ld} 54 check pvcreate ${ld} 55 execute vgcreate ${V0} ${ld} 56 check vgcreate ${V0} 57 execute lvcreate --thin ${V0}/pool --size 128M 58 } 59 60 function volinfo_field() 61 { 62 local vol=$1; 63 local field=$2; 64 $CLI volume info $vol | grep "^$field: " | sed 's/.*: //'; 65 } 66 67 function volume_type() 68 { 69 getfattr -n volume.type $M0/. --only-values --absolute-names -e text 70 } 71 72 TEST glusterd 73 TEST pidof glusterd 74 configure 75 76 TEST $CLI volume create $V0 ${H0}:/$B0/$V0?${V0} 77 EXPECT "$V0" volinfo_field $V0 'Volume Name'; 78 EXPECT 'Created' volinfo_field $V0 'Status'; 79 80 ## Start volume and verify 81 TEST $CLI volume start $V0; 82 EXPECT 'Started' volinfo_field $V0 'Status' 83 84 TEST glusterfs --volfile-id=/$V0 --volfile-server=$H0 $M0 85 EXPECT '1' volume_type 86 87 ## Create posix file 88 TEST touch $M0/posix 89 90 TEST touch $M0/lv 91 gfid=`getfattr -n glusterfs.gfid.string $M0/lv --only-values --absolute-names` 92 TEST setfattr -n user.glusterfs.bd -v "lv:4MB" $M0/lv 93 # Check if LV is created 94 TEST stat /dev/$V0/${gfid} 95 96 ## Create filesystem 97 sleep 1 98 TEST mkfs.ext4 -qF $M0/lv 99 # Cloning 100 TEST touch $M0/lv_clone 101 gfid=`getfattr -n glusterfs.gfid.string $M0/lv_clone --only-values --absolute-names` 102 TEST setfattr -n clone -v ${gfid} $M0/lv 103 TEST stat /dev/$V0/${gfid} 104 105 sleep 1 106 ## Check mounting 107 TEST mount -o loop $M0/lv $M1 108 umount $M1 109 110 # Snapshot 111 TEST touch $M0/lv_sn 112 gfid=`getfattr -n glusterfs.gfid.string $M0/lv_sn --only-values --absolute-names` 113 TEST setfattr -n snapshot -v ${gfid} $M0/lv 114 TEST stat /dev/$V0/${gfid} 115 116 # Merge 117 sleep 1 **118 TEST setfattr -n merge -v "$M0/lv_sn" $M0/lv_sn **119 TEST ! stat $M0/lv_sn **120 TEST ! stat /dev/$V0/${gfid} 121 122 123 rm $M0/* -f 124 **125 TEST umount $M0 126 TEST $CLI volume stop ${V0} 127 EXPECT 'Stopped' volinfo_field $V0 'Status'; 128 TEST $CLI volume delete ${V0} 129 130 bd_cleanup Pranith ___ Gluster-devel mailing list Gluster-devel@gluster.org http://supercolony.gluster.org/mailman/listinfo/gluster-devel