]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
osd/scrub: exempt only operator scrubs from max_scrubs limit 59020/head
authorRonen Friedman <rfriedma@redhat.com>
Mon, 29 Jul 2024 14:11:50 +0000 (09:11 -0500)
committerRonen Friedman <rfriedma@redhat.com>
Mon, 5 Aug 2024 10:38:19 +0000 (05:38 -0500)
commita3f16627fde5426b19b932b9ef41c167e029d30f
tree5d2b608341ee8d35ea10f63d59564ed848732d23
parentd99c9769be1521395979e8c23d9073adbf1ff43f
osd/scrub: exempt only operator scrubs from max_scrubs limit

Existing code exempts all 'high priority' scrubs, including for example
'after_repair' and 'mandatory on invalid history' scrubs from the limit.

PGs that do not have valid last-scrub data (which is what we have when
a pool is first created) - are set to shallow-scrub immediately.
Unfortunately - this type of scrub is (in the low granularity implemented
in existing code) is 'high priority'.
Which means that a newly created pool will have all its PGs start
scrubbing, regardless of concurrency (or any other) limits.

Fixes: https://tracker.ceph.com/issues/67253
Signed-off-by: Ronen Friedman <rfriedma@redhat.com>
(cherry picked from commit babd65e412266f5c734f7a2b57d87657d3470c47)
conflict resolution:
- eliminating irrelevant 'main' code that was picked into this branch.
- the code to set the scrub_job's flag moved to osd_scrub_sched.cc,
  where the corresponding function is.
src/osd/scrubber/osd_scrub_sched.cc
src/osd/scrubber/pg_scrubber.cc
src/osd/scrubber/scrub_job.h