From faa291ac25b0893a796d2623d2196e6029bf6921 Mon Sep 17 00:00:00 2001 From: dzogin Date: Sat, 12 Sep 2009 01:44:10 +0000 Subject: [PATCH] Branch b1_8 b=20200 i=grev ---------------------------------------------------------------------- Modified Files: Tag: b1_8 lustre/ChangeLog lustre/tests/sanity-quota.sh ---------------------------------------------------------------------- Description: Added sanity-quota test to for lfs(1) to work with numeric uid/gid. =================================================================== --- lustre/ChangeLog | 4 ++++ lustre/tests/sanity-quota.sh | 19 +++++++++++++++++-- 2 files changed, 21 insertions(+), 2 deletions(-) diff --git a/lustre/ChangeLog b/lustre/ChangeLog index f5c8fd8..13adf69 100644 --- a/lustre/ChangeLog +++ b/lustre/ChangeLog @@ -14,6 +14,10 @@ tbd Sun Microsystems, Inc. of Lustre filesystem with 4K stack may cause a stack overflow. For more information, please refer to bugzilla 17630. +Severity : enhancement +Bugzilla : 20200 +Description: Added sanity-quota test to for lfs(1) to work with numeric uid/gid. + Severity : major Bugzilla : 20560 Description: File checksum failures with OST read cache on diff --git a/lustre/tests/sanity-quota.sh b/lustre/tests/sanity-quota.sh index 4ae1102..293b07d 100644 --- a/lustre/tests/sanity-quota.sh +++ b/lustre/tests/sanity-quota.sh @@ -70,8 +70,10 @@ LOVNAME=`lctl get_param -n llite.*.lov.common_name | tail -n 1` OSTCOUNT=`lctl get_param -n lov.$LOVNAME.numobd` SHOW_QUOTA_USER="$LFS quota -v -u $TSTUSR $DIR" +SHOW_QUOTA_USERID="$LFS quota -v -u $TSTID $DIR" SHOW_QUOTA_USER2="$LFS quota -v -u $TSTUSR2 $DIR" SHOW_QUOTA_GROUP="$LFS quota -v -g $TSTUSR $DIR" +SHOW_QUOTA_GROUPID="$LFS quota -v -g $TSTID $DIR" SHOW_QUOTA_GROUP2="$LFS quota -v -g $TSTUSR2 $DIR" SHOW_QUOTA_INFO_USER="$LFS quota -t -u $DIR" SHOW_QUOTA_INFO_GROUP="$LFS quota -t -g $DIR" @@ -2107,12 +2109,25 @@ test_26() { } run_test_with_stat 26 "test for false quota error(bz18491) ======================================" -test_27() { +test_27a() { $LFS quota $TSTUSR $DIR && error "lfs succeeded with no type, but should have failed" $LFS setquota $TSTUSR $DIR && error "lfs succeeded with no type, but should have failed" return 0 } -run_test_with_stat 27 "lfs quota/setquota should handle wrong arguments (19612) =================" +run_test_with_stat 27a "lfs quota/setquota should handle wrong arguments (19612) =================" + +test_27b() { + $LFS setquota -u $TSTID -b 1000 -B 1000 -i 1000 -I 1000 $DIR || \ + error "lfs setquota failed with uid argument" + $LFS setquota -g $TSTID -b 1000 -B 1000 -i 1000 -I 1000 $DIR || \ + error "lfs stequota failed with gid argument" + $SHOW_QUOTA_USERID || error "lfs quota failed with uid argument" + $SHOW_QUOTA_GROUPID || error "lfs quota failed with gid argument" + resetquota -u $TSTUSR + resetquota -g $TSTUSR + return 0 +} +run_test 27b "lfs quota/setquota should handle user/group ID (20200) =================" test_28() { BLK_LIMIT=$((100 * 1024 * 1024)) # 100G -- 1.8.3.1