Whamcloud - gitweb
LU-3703 tests: skip test for getfattr 2.4.44-6 or less 67/10867/3
authorAndreas Dilger <andreas.dilger@intel.com>
Fri, 27 Jun 2014 06:15:27 +0000 (00:15 -0600)
committerOleg Drokin <oleg.drokin@intel.com>
Mon, 6 Oct 2014 00:44:36 +0000 (00:44 +0000)
Non-SLES distros may also have an older version of getfattr,
so sanity.sh test_234 should also be skipped on those systems.

Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Change-Id: I012554dd840715d336d3286cc46c56f53d500c1e
Reviewed-on: http://review.whamcloud.com/10867
Tested-by: Jenkins
Reviewed-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/tests/sanity.sh

index 8de0173..f1a4f87 100644 (file)
@@ -12460,11 +12460,16 @@ test_234() {
        touch $DIR/$tdir/$tfile || error "touch failed"
        # OBD_FAIL_LLITE_XATTR_ENOMEM
        $LCTL set_param fail_loc=0x1405
-       if [ ! -f /etc/SuSE-release ]; then
+       # output of the form: attr 2 4 44 3 fc13 x86_64
+       V=($(IFS=".-" rpm -q attr))
+       if [[ ${V[1]} > 2 || ${V[2]} > 4 || ${V[3]} > 44 ||
+             ${V[1]} = 2 && ${V[2]} = 4 && ${V[3]} = 44 && ${V[4]} > 6 ]]; then
                # attr pre-2.4.44-7 had a bug with rc
-               # LU-3703 - SLES clients have older attr
+               # LU-3703 - SLES 11 and FC13 clients have older attr
                getfattr -n user.attr $DIR/$tdir/$tfile &&
                        error "getfattr should have failed with ENOMEM"
+       else
+               skip "LU-3703: attr version $(getfattr --version) too old"
        fi
        $LCTL set_param fail_loc=0x0
        rm -rf $DIR/$tdir