diff options
author | Samuel Just <sam.just@inktank.com> | 2013-05-24 13:35:14 -0700 |
---|---|---|
committer | Samuel Just <sam.just@inktank.com> | 2013-05-28 10:41:57 -0700 |
commit | 1c35556b56dd531b584558e44eff3ea5e650cc30 (patch) | |
tree | 93ac5dbccfc24143d03e3a64cf98d3b5ea6e7cc1 | |
parent | 4d53e9c9409eb512c2e6f326d28fe12f788daaa7 (diff) | |
download | ceph-1c35556b56dd531b584558e44eff3ea5e650cc30.tar.gz |
doc/dev/osd_internals: add wbthrottle.rst
Signed-off-by: Samuel Just <sam.just@inktank.com>
-rw-r--r-- | doc/dev/osd_internals/wbthrottle.rst | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/doc/dev/osd_internals/wbthrottle.rst b/doc/dev/osd_internals/wbthrottle.rst new file mode 100644 index 00000000000..14ba0140d4d --- /dev/null +++ b/doc/dev/osd_internals/wbthrottle.rst @@ -0,0 +1,28 @@ +================== +Writeback Throttle +================== + +Previously, the filestore had a problem when handling large numbers of +small ios. We throttle dirty data implicitely via the journal, but +a large number of inodes can be dirtied without filling the journal +resulting in a very long sync time when the sync finally does happen. +The flusher was not an adequate solution to this problem since it +forced writeback of small writes too eagerly killing performance. + +WBThrottle tracks unflushed io per hobject_t and ::fsyncs in lru +order once the start_flusher threshhold is exceeded for any of +dirty bytes, dirty ios, or dirty inodes. While any of these exceed +the hard_limit, we block on throttle() in _do_op. + +See src/os/WBThrottle.h, src/osd/WBThrottle.cc + +To track the open FDs through the writeback process, there is now an +fdcache to cache open fds. lfn_open now returns a cached FDRef which +implicitely closes the fd once all references have expired. + +Filestore syncs have a sideeffect of flushing all outstanding objects +in the wbthrottle. + +lfn_unlink clears the cached FDRef and wbthrottle entries for the +unlinked object when then last link is removed and asserts that all +outstanding FDRefs for that object are dead. |