{"action":"created","issue":{"url":"https://api.github.com/repos/ceph/ceph/issues/3733","labels_url":"https://api.github.com/repos/ceph/ceph/issues/3733/labels{/name}","comments_url":"https://api.github.com/repos/ceph/ceph/issues/3733/comments","events_url":"https://api.github.com/repos/ceph/ceph/issues/3733/events","html_url":"https://github.com/ceph/ceph/pull/3733","id":57722642,"number":3733,"title":"osd: consider last scrub timestamp globally when determining if the PG should schedule to scrub","user":{"login":"guangyy","id":891065,"avatar_url":"https://avatars.githubusercontent.com/u/891065?v=3","gravatar_id":"","url":"https://api.github.com/users/guangyy","html_url":"https://github.com/guangyy","followers_url":"https://api.github.com/users/guangyy/followers","following_url":"https://api.github.com/users/guangyy/following{/other_user}","gists_url":"https://api.github.com/users/guangyy/gists{/gist_id}","starred_url":"https://api.github.com/users/guangyy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guangyy/subscriptions","organizations_url":"https://api.github.com/users/guangyy/orgs","repos_url":"https://api.github.com/users/guangyy/repos","events_url":"https://api.github.com/users/guangyy/events{/privacy}","received_events_url":"https://api.github.com/users/guangyy/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-02-15T08:20:17Z","updated_at":"2015-02-15T19:33:39Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/ceph/ceph/pulls/3733","html_url":"https://github.com/ceph/ceph/pull/3733","diff_url":"https://github.com/ceph/ceph/pull/3733.diff","patch_url":"https://github.com/ceph/ceph/pull/3733.patch"},"body":"Currently the scheduling of scrub is optimized locally at each OSD, that is, for each PG this OSD acts as the primary, it selects the one which hasn't been scheduled to scrubbing longest, put it as the candidate and request scrub reserver from all replicas. Since each OSD can only have 1 active scrubbing, that active slot could potentially always occupied by a replica, as a result, the PG whose primary is this OSD, fail to schedule and left behind.\r\n\r\nFor scrub reservation request, we can add the last scrub timestamp, so that for the replica OSD, it can use that timestamp to compare with its local scrub scheduling (primary) and make call to allow or deny the request.\r\n\r\nFixes: 10796\r\n\r\nSigned-off-by: Guang Yang <yguang@yahoo-inc.com>"},"comment":{"url":"https://api.github.com/repos/ceph/ceph/issues/comments/74432631","html_url":"https://github.com/ceph/ceph/pull/3733#issuecomment-74432631","issue_url":"https://api.github.com/repos/ceph/ceph/issues/3733","id":74432631,"user":{"login":"trociny","id":1517222,"avatar_url":"https://avatars.githubusercontent.com/u/1517222?v=3","gravatar_id":"","url":"https://api.github.com/users/trociny","html_url":"https://github.com/trociny","followers_url":"https://api.github.com/users/trociny/followers","following_url":"https://api.github.com/users/trociny/following{/other_user}","gists_url":"https://api.github.com/users/trociny/gists{/gist_id}","starred_url":"https://api.github.com/users/trociny/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/trociny/subscriptions","organizations_url":"https://api.github.com/users/trociny/orgs","repos_url":"https://api.github.com/users/trociny/repos","events_url":"https://api.github.com/users/trociny/events{/privacy}","received_events_url":"https://api.github.com/users/trociny/received_events","type":"User","site_admin":false},"created_at":"2015-02-15T19:33:39Z","updated_at":"2015-02-15T19:33:39Z","body":"The last scrub timestamp is operation specific field. Wouldn't it be better to add it to the scrub operation payload (ceph_osd_op) instead of MOSDSubOp? "}}