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.
Showing the changes to include/linux (1 of 3 files). Show all
Unified · Split
| @@ -294,6 +294,8 @@ extern void ceph_destroy_client(struct ceph_client *client); · 293 unmodified lines | ||
| 294 | 294 | extern int __ceph_open_session(struct ceph_client *client, |
| 295 | 295 | unsigned long started); |
| 296 | 296 | extern int ceph_open_session(struct ceph_client *client); |
| 297 | +int ceph_wait_for_latest_osdmap(struct ceph_client *client, | |
| 298 | + unsigned long timeout); | |
| 297 | 299 | |
| 298 | 300 | /* pagevec.c */ |
| 299 | 301 | extern void ceph_release_page_vector(struct page **pages, int num_pages); |