Whamcloud - gitweb
LU-4505 quota: race of edquot updating 54/8954/2
authorNiu Yawei <yawei.niu@intel.com>
Wed, 22 Jan 2014 04:24:00 +0000 (23:24 -0500)
committerNiu Yawei <yawei.niu@intel.com>
Fri, 7 Feb 2014 10:11:09 +0000 (05:11 -0500)
commit109fef5b053490549726f7b5abc9ba840d3a4ae0
tree9cf6a00a2a6a1cd03ebcaddfb513d50875e81411
parent905c06d12d7027dada2e16da37c108d467a5324c
LU-4505 quota: race of edquot updating

The slave edquot flag could be set mistakenly as following:

- slave A acquires quota from master, master found that the
  user is running out of quota, set edquot in reply;
- another slave deletes files and release quota to master,
  master clears edquot and notify all slaves by glimpse;
- glimpse reaches slave A before the reply of dqacq, so
  edquot flag will be set on slave A at the end.

Given that edquot can't be fully trusted, it should only be
revalidated every 5 seconds on the sync acquire path.

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: Id4db47462bdf620a42cd31f75726fbcaff869179
lustre/quota/lquota_internal.h
lustre/quota/qsd_handler.c
lustre/quota/qsd_internal.h
lustre/quota/qsd_lock.c