Whamcloud - gitweb
EX-3741 pcc: add pcc_mode parameter for permission check
authorQian Yingjin <qian@ddn.com>
Wed, 1 Sep 2021 13:45:47 +0000 (21:45 +0800)
committerAndreas Dilger <adilger@whamcloud.com>
Thu, 9 Sep 2021 07:40:35 +0000 (07:40 +0000)
commit819ae3a993456fccd9952a0aa84ca32946cca563
tree68ffc2dc9fc57cb532b67260374eda0a04f0e89b
parent7e76a6d6b521777006f2903116df5f7c6883c184
EX-3741 pcc: add pcc_mode parameter for permission check

This patch introduced a "llite.*.pcc_mode" parameter for PCC.
By this parameter, administrator can determine what file access
permissions should be allowed to bring files into PCC device for
caching.
This paramter is set with 0 by default.
Add sanity-pcc test_46 to verify it.

In this patch, it also ignores the EEXIST error when found that the
file had already attached into PCC during the manual attach.

Signed-off-by: Qian Yingjin <qian@ddn.com>
Change-Id: I1e006e4f723c1c177ae84c64ad32c6049a57110f
Reviewed-on: https://review.whamcloud.com/44804
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: Yang Sheng <ys@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
lustre/llite/dir.c
lustre/llite/file.c
lustre/llite/lproc_llite.c
lustre/llite/pcc.c
lustre/llite/pcc.h
lustre/tests/sanity-pcc.sh