Fix rm-data waiting forever when PGs go inactive during deletion #203

Open
koolkhel wants to merge 2 commits from koolkhel/vitastor:delete-wait-up-timer into master

2 Commits

Author SHA1 Message Date
0219f6f68b Arm the retry timer when an operation starts waiting for its PG
Instead of polling an operation that waits for its PG to come up every
client_retry_interval, arm the retry timer for client_wait_up_timeout
when its deadline is set. Re-arm it for the remaining time while the
operation still waits: reset_retry_timer() keeps a shorter timer that is
already set, and when that one fires for another operation, nothing
would wake this one up again before its deadline.
2026-11-29 14:53:15 +03:00
042b83d6e1 Fix rm-data waiting forever when PGs go inactive during deletion
An operation with OSD_OP_WAIT_UP_TIMEOUT that finds its PG inactive gets
a deadline, but the retry timer is armed only for parts retried after a
failure. An operation that first found its PG already inactive was left
without a timer and waited for an unrelated event instead of failing
after client_wait_up_timeout. rm-data hit this when OSDs died during
deletion: the deletes in flight timed out, and the following deletes of
the same PG waited forever. Arm the timer for such operations too.

Also stop sending deletes to a PG after one of them times out, and report
the PG as not deleted, so that rm-data doesn't wait client_wait_up_timeout
again for each of its remaining objects.
2026-11-29 12:32:50 +03:00