• Ilya Dryomov's avatar
    libceph: wait for latest osdmap in ceph_monc_blacklist_add() · bb229bbb
    Ilya Dryomov authored
    Because map updates are distributed lazily, an OSD may not know about
    the new blacklist for quite some time after "osd blacklist add" command
    is completed.  This makes it possible for a blacklisted but still alive
    client to overwrite a post-blacklist update, resulting in data
    corruption.
    
    Waiting for latest osdmap in ceph_monc_blacklist_add() and thus using
    the post-blacklist epoch for all post-blacklist requests ensures that
    all such requests "wait" for the blacklist to come into force on their
    respective OSDs.
    
    Cc: stable@vger.kernel.org
    Fixes: 6305a3b4 ("libceph: support for blacklisting clients")
    Signed-off-by: default avatarIlya Dryomov <idryomov@gmail.com>
    Reviewed-by: default avatarJason Dillaman <dillaman@redhat.com>
    bb229bbb
ceph_common.c 19.9 KB