]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
librbd: discard cache state if compare-and-write writes to disk
authorIlya Dryomov <idryomov@gmail.com>
Mon, 15 Aug 2022 07:44:09 +0000 (09:44 +0200)
committerIlya Dryomov <idryomov@gmail.com>
Mon, 15 Aug 2022 07:44:09 +0000 (09:44 +0200)
commitec0fc71cdb579e31ff4e599c43f3918322e70ddf
treea64054989a910a51814899dff74ed2d8b96f134e
parent4ddcb7ff92a51a6fa17887e54fd357bd5dea5f4e
librbd: discard cache state if compare-and-write writes to disk

Otherwise this is obviously broken with rbd_cache_policy = writeback or
rbd_cache_policy = writethrough as the write is done on the OSD, beneath
ObjectCacher.  This went unnoticed because the original (and so far the
only known) compare-and-write user, tcmu-runner rbd driver, disables the
cache altogether.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
src/librbd/cache/ObjectCacherObjectDispatch.cc