Whamcloud - gitweb
LU-14739 quota: nodemap squashed root cannot bypass quota
authorSebastien Buisson <sbuisson@ddn.com>
Fri, 11 Jun 2021 14:49:47 +0000 (16:49 +0200)
committerAndreas Dilger <adilger@whamcloud.com>
Wed, 10 Nov 2021 15:58:59 +0000 (15:58 +0000)
commiteb6dfb5fdbe3c06e325ea11fad1a16d6a992de81
tree500bd8fdd805c3cce0294e36c09d42b69c23f681
parent1407c5692b88a54ab666f5535d31322fda487577
LU-14739 quota: nodemap squashed root cannot bypass quota

When root on client is squashed via a nodemap's squash_uid/squash_gid,
its IOs must not bypass quota enforcement as it normally does without
squashing.
So on client side, do not set OBD_BRW_FROM_GRANT for every page being
used by root. And on server side, check if root is squashed via a
nodemap and remove OBD_BRW_NOQUOTA.

Lustre-change: https://review.whamcloud.com/43988
Lustre-commit: a4fbe7341baf12c00c6048bb290f8aa26c05cbac

Signed-off-by: Sebastien Buisson <sbuisson@ddn.com>
Change-Id: I95b31277273589e363193cba8b84870f008bb07a
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Bobi Jam <bobijam@hotmail.com>
Reviewed-on: https://review.whamcloud.com/45485
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
lustre/ofd/ofd_io.c
lustre/osc/osc_cache.c
lustre/tests/sanity-quota.sh