osd: set suicide timeouts on some workqueues

OpWQ: timeout * 10
RecoveryWQ: this does no io; it if stalls we're probably stuck in an
  infinite loop.  timeout * 10.
ScrubFinalizeWQ: this is cpu only. we're probably stuck in a loop, or
  swapping.  timeout * 10.

Signed-off-by: Sage Weil <sage@newdream.net>
This commit is contained in:
Sage Weil 2011-08-29 11:54:21 -07:00
parent 66b6289a1b
commit 9d37c92c58

View File

@ -318,7 +318,7 @@ private:
struct OpWQ : public ThreadPool::WorkQueue<PG> {
OSD *osd;
OpWQ(OSD *o, time_t ti, ThreadPool *tp)
: ThreadPool::WorkQueue<PG>("OSD::OpWQ", ti, 0, tp), osd(o) {}
: ThreadPool::WorkQueue<PG>("OSD::OpWQ", ti, ti*10, tp), osd(o) {}
bool _enqueue(PG *pg) {
pg->get();
@ -648,7 +648,7 @@ protected:
struct RecoveryWQ : public ThreadPool::WorkQueue<PG> {
OSD *osd;
RecoveryWQ(OSD *o, time_t ti, ThreadPool *tp)
: ThreadPool::WorkQueue<PG>("OSD::RecoveryWQ", ti, 0, tp), osd(o) {}
: ThreadPool::WorkQueue<PG>("OSD::RecoveryWQ", ti, ti*10, tp), osd(o) {}
bool _empty() {
return osd->recovery_queue.empty();
@ -827,7 +827,7 @@ protected:
public:
ScrubFinalizeWQ(OSD *o, time_t ti, ThreadPool *tp)
: ThreadPool::WorkQueue<PG>("OSD::ScrubFinalizeWQ", ti, 0, tp), osd(o) {}
: ThreadPool::WorkQueue<PG>("OSD::ScrubFinalizeWQ", ti, ti*10, tp), osd(o) {}
bool _empty() {
return scrub_finalize_queue.empty();