Whamcloud - gitweb
LU-8163 hsm: user_request_mask can't be unset in test 24c 20/20320/4
authorFrank Zago <fzago@cray.com>
Wed, 18 May 2016 21:51:01 +0000 (17:51 -0400)
committerOleg Drokin <oleg.drokin@intel.com>
Tue, 14 Jun 2016 03:54:45 +0000 (03:54 +0000)
The following lines in sanity-hsm.sh test_24c

  set_hsm_param user_request_mask ""
  set_hsm_param group_request_mask ""
  set_hsm_param other_request_mask ""

generate the following errors in the test, which isn't caught:

  error: set_param: setting mdt.lustre-MDT0000.hsm.user_request_mask:
                    no value

This is because "lct set_param" cannot accept an empty value:

  $ lctl set_param -n mdt.lustre-MDT0000.hsm.user_request_mask=""
  error: set_param: setting mdt.lustre-MDT0000.hsm.user_request_mask:
                    no value

Since the test checked earlier that [user|group|other]_request_mask
was RESTORE, we don't actually need to change their values to
nothing. They just have to be not ARCHIVE.

Test-Parameters: trivial testlist=sanity-hsm,sanity-hsm

Signed-off-by: frank zago <fzago@cray.com>
Change-Id: I00622d93157e6577651996bf482ec8f710f86c9e
Reviewed-on: http://review.whamcloud.com/20320
Reviewed-by: Henri Doreau <henri.doreau@cea.fr>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/tests/sanity-hsm.sh

index e0960bb..fd2f711 100755 (executable)
@@ -2132,7 +2132,6 @@ test_24c() {
        chown $RUNAS_ID:nobody $file ||
                error "cannot chown '$file' to '$RUNAS_ID:nobody'"
 
        chown $RUNAS_ID:nobody $file ||
                error "cannot chown '$file' to '$RUNAS_ID:nobody'"
 
-       set_hsm_param user_request_mask ""
        $RUNAS $LFS hsm_$action $file &&
                error "$action by user should fail"
 
        $RUNAS $LFS hsm_$action $file &&
                error "$action by user should fail"
 
@@ -2146,7 +2145,6 @@ test_24c() {
        chown nobody:$RUNAS_GID $file ||
                error "cannot chown '$file' to 'nobody:$RUNAS_GID'"
 
        chown nobody:$RUNAS_GID $file ||
                error "cannot chown '$file' to 'nobody:$RUNAS_GID'"
 
-       set_hsm_param group_request_mask ""
        $RUNAS $LFS hsm_$action $file &&
                error "$action by group should fail"
 
        $RUNAS $LFS hsm_$action $file &&
                error "$action by group should fail"
 
@@ -2160,7 +2158,6 @@ test_24c() {
        chown nobody:nobody $file ||
                error "cannot chown '$file' to 'nobody:nobody'"
 
        chown nobody:nobody $file ||
                error "cannot chown '$file' to 'nobody:nobody'"
 
-       set_hsm_param other_request_mask ""
        $RUNAS $LFS hsm_$action $file &&
                error "$action by other should fail"
 
        $RUNAS $LFS hsm_$action $file &&
                error "$action by other should fail"