Whamcloud - gitweb
LU-9228 nrs: TBF realtime policies under congestion 87/26087/8
authorQian Yingjin <qian@ddn.com>
Mon, 6 Mar 2017 07:05:01 +0000 (15:05 +0800)
committerOleg Drokin <oleg.drokin@intel.com>
Thu, 25 Jan 2018 04:47:01 +0000 (04:47 +0000)
commitd11fa2c279593634cf6c4196b413a6d285b24e10
treeace0979a0fc7543b7a6f6c397f5ac4dd1684f86d
parent00c4bd85b372f68c3e75fdab9658c8f0074113be
LU-9228 nrs: TBF realtime policies under congestion

During TBF evaluation, we find that when the sum of I/O bandwidth
requirements for all classes exceeds the system capacity, the
classes with same rate limits get less bandwidth than preconfigured
evenly.

The reason is as follows: under heavy load on a congested server,
it will result in some missed deadlines for some classes. The
calculated tokens may larger than 1 during dequeuing. In the original
implementation, all classes are equally handled to simply discard
exceeding tokens.

Thus, a Hard Token Compensation (HTC) strategy is proposed. A class
can be configured with HTC feature by the rule it matches. This
feature means that requests in this kind of class queues have high
real-time requirements and that the bandwidth assignment must be
satisfied as good as possible. When deadline misses happen, the
class keeps the deadline unchanged and the time residue (the
remainder of elapsed time divided by 1/r) is compensated to the
next round. This ensures that the next idle I/O thread will always
select this class to serve until all accumulated exceeding tokens
are handled or there are no pending requests in the class queue.

A new command format is added to enable realtime feature for a rule:
start $ruleName jobid={dd.0} rate=100 realtime=1

Change-Id: I3c867052c27e57a30ccdfe649e0905d141792663
Signed-off-by: Qian Yingjin <qian@ddn.com>
Reviewed-on: https://review.whamcloud.com/26087
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Emoly Liu <emoly.liu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/include/lustre_nrs_tbf.h
lustre/ptlrpc/nrs_tbf.c