Re: Block device throttling [Re: Distributed storage.]

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Daniel Phillips
Date: Monday, August 13, 2007 - 4:18 am

On Monday 13 August 2007 01:23, Evgeniy Polyakov wrote:
(phillips@phunq.net) wrote:

What can happen is, as soon as you unthrottle the previous queue, 
another thread can come in and put another request on it.  Sure, that 
thread will likely block on the physical throttle and so will the rest 
of the incoming threads, but it still allows the higher level queue to 
grow past any given limit, with the help of lots of threads.  JVM for 
example?

Say you have a device mapper device with some physical device sitting 
underneath, the classic use case for this throttle code.  Say 8,000 
threads each submit an IO in parallel.  The device mapper mapping 
function will be called 8,000 times with associated resource 
allocations, regardless of any throttling on the physical device queue.

Anyway, your approach is awfully close to being airtight, there is just 
a small hole.  I would be more than happy to be proved wrong about 
that, but the more I look, the more I see that hole.


Quite true.  In some cases the simple inc/dec per bio works just fine.  
But the general case where finer granularity is required comes up in 
existing code, so there needs to be a plan.

Regards,

Daniel
-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Distributed storage., Evgeniy Polyakov, (Tue Jul 31, 10:13 am)
Re: Distributed storage., Daniel Phillips, (Thu Aug 2, 2:08 pm)
Re: Distributed storage., Mike Snitzer, (Thu Aug 2, 9:09 pm)
Re: Distributed storage., Manu Abraham, (Thu Aug 2, 10:04 pm)
Re: Distributed storage., Evgeniy Polyakov, (Fri Aug 3, 3:26 am)
Re: Distributed storage., Evgeniy Polyakov, (Fri Aug 3, 3:42 am)
Re: Distributed storage., Evgeniy Polyakov, (Fri Aug 3, 3:44 am)
Re: Distributed storage., Evgeniy Polyakov, (Fri Aug 3, 3:57 am)
Re: Distributed storage., Peter Zijlstra, (Fri Aug 3, 5:27 am)
Re: Distributed storage., Evgeniy Polyakov, (Fri Aug 3, 6:49 am)
Re: Distributed storage., Peter Zijlstra, (Fri Aug 3, 7:53 am)
Re: Distributed storage., Daniel Phillips, (Fri Aug 3, 12:41 pm)
Re: Distributed storage., Daniel Phillips, (Fri Aug 3, 12:48 pm)
Re: Distributed storage., Daniel Phillips, (Fri Aug 3, 5:41 pm)
Re: Distributed storage., Daniel Phillips, (Fri Aug 3, 5:49 pm)
Re: Distributed storage., Daniel Phillips, (Fri Aug 3, 6:19 pm)
Re: Distributed storage., Dave Dillow, (Fri Aug 3, 7:51 pm)
Re: Distributed storage., Manu Abraham, (Fri Aug 3, 8:44 pm)
Re: Distributed storage., Evgeniy Polyakov, (Sat Aug 4, 9:37 am)
Re: Distributed storage., Evgeniy Polyakov, (Sat Aug 4, 9:44 am)
Re: Distributed storage., Evgeniy Polyakov, (Sat Aug 4, 10:03 am)
Re: Distributed storage., Daniel Phillips, (Sun Aug 5, 1:04 am)
Re: Distributed storage., Daniel Phillips, (Sun Aug 5, 1:06 am)
Re: Distributed storage., Evgeniy Polyakov, (Sun Aug 5, 8:01 am)
Re: Distributed storage., Evgeniy Polyakov, (Sun Aug 5, 8:08 am)
Re: Distributed storage., Daniel Phillips, (Sun Aug 5, 2:23 pm)
Re: Distributed storage., Daniel Phillips, (Sun Aug 5, 2:35 pm)
Re: Distributed storage., Evgeniy Polyakov, (Mon Aug 6, 1:25 am)
Re: Distributed storage., Evgeniy Polyakov, (Mon Aug 6, 1:28 am)
Re: Distributed storage., Jens Axboe, (Tue Aug 7, 5:05 am)
Re: Distributed storage., Daniel Phillips, (Tue Aug 7, 11:24 am)
Re: Distributed storage., Jens Axboe, (Tue Aug 7, 1:55 pm)
Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Wed Aug 8, 2:54 am)
[1/1] Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Wed Aug 8, 3:17 am)
Re: [1/1] Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Wed Aug 8, 6:28 am)
Re: [1/1] Block device throttling [Re: Distributed storage.], Daniel Phillips, (Sun Aug 12, 4:16 pm)
Re: Distributed storage., Daniel Phillips, (Sun Aug 12, 4:36 pm)
Re: Block device throttling [Re: Distributed storage.], Daniel Phillips, (Sun Aug 12, 10:22 pm)
Re: Block device throttling [Re: Distributed storage.], Daniel Phillips, (Sun Aug 12, 10:36 pm)
Re: Block device throttling [Re: Distributed storage.], Daniel Phillips, (Sun Aug 12, 11:44 pm)
Re: Distributed storage., Jens Axboe, (Mon Aug 13, 12:28 am)
Re: Distributed storage., Jens Axboe, (Mon Aug 13, 12:45 am)
Re: Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Mon Aug 13, 1:14 am)
Re: [1/1] Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Mon Aug 13, 1:18 am)
Re: Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Mon Aug 13, 1:23 am)
Re: Distributed storage., Daniel Phillips, (Mon Aug 13, 1:59 am)
Re: Distributed storage., Daniel Phillips, (Mon Aug 13, 2:08 am)
Re: Distributed storage., Jens Axboe, (Mon Aug 13, 2:12 am)
Re: Distributed storage., Jens Axboe, (Mon Aug 13, 2:13 am)
Re: Distributed storage., Evgeniy Polyakov, (Mon Aug 13, 2:18 am)
Re: Distributed storage., Daniel Phillips, (Mon Aug 13, 2:55 am)
Re: Distributed storage., Jens Axboe, (Mon Aug 13, 3:06 am)
Re: Distributed storage., Daniel Phillips, (Mon Aug 13, 3:12 am)
Re: Distributed storage., Daniel Phillips, (Mon Aug 13, 3:15 am)
Re: Distributed storage., Jens Axboe, (Mon Aug 13, 3:22 am)
Re: Distributed storage., Daniel Phillips, (Mon Aug 13, 3:32 am)
Re: Distributed storage., Evgeniy Polyakov, (Mon Aug 13, 4:03 am)
Re: Block device throttling [Re: Distributed storage.], Daniel Phillips, (Mon Aug 13, 4:04 am)
Re: Block device throttling [Re: Distributed storage.], Daniel Phillips, (Mon Aug 13, 4:18 am)
Re: Distributed storage., Daniel Phillips, (Mon Aug 13, 4:45 am)
Re: Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Mon Aug 13, 5:04 am)
Re: Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Mon Aug 13, 5:18 am)
Re: Block device throttling [Re: Distributed storage.], Daniel Phillips, (Mon Aug 13, 5:18 am)
Re: Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Mon Aug 13, 5:24 am)
Re: Block device throttling [Re: Distributed storage.], Daniel Phillips, (Mon Aug 13, 6:04 am)
Re: Distributed storage., Daniel Phillips, (Mon Aug 13, 4:27 pm)
Re: Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Tue Aug 14, 1:46 am)
Re: Block device throttling [Re: Distributed storage.], Daniel Phillips, (Tue Aug 14, 4:13 am)
Re: Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Tue Aug 14, 4:30 am)
Re: Block device throttling [Re: Distributed storage.], Daniel Phillips, (Tue Aug 14, 4:35 am)
Re: Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Tue Aug 14, 4:50 am)
Re: Block device throttling [Re: Distributed storage.], Daniel Phillips, (Tue Aug 14, 5:32 am)
Re: Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Tue Aug 14, 5:46 am)
Re: Block device throttling [Re: Distributed storage.], Daniel Phillips, (Tue Aug 14, 5:54 am)
Re: [1/1] Block device throttling [Re: Distributed storage.], Daniel Phillips, (Mon Aug 27, 2:57 pm)
Re: [1/1] Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Tue Aug 28, 2:35 am)
Re: Distributed storage., Evgeniy Polyakov, (Tue Aug 28, 10:19 am)
Re: [1/1] Block device throttling [Re: Distributed storage.], Daniel Phillips, (Tue Aug 28, 10:27 am)
Re: [1/1] Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Tue Aug 28, 10:54 am)
Re: [1/1] Block device throttling [Re: Distributed storage.], Daniel Phillips, (Tue Aug 28, 2:08 pm)
Re: [1/1] Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Wed Aug 29, 1:53 am)
Re: [1/1] Block device throttling [Re: Distributed storage.], Daniel Phillips, (Thu Aug 30, 4:20 pm)
Re: [1/1] Block device throttling [Re: Distributed storage.], Evgeniy Polyakov, (Fri Aug 31, 10:33 am)
Re: [1/1] Block device throttling [Re: Distributed storage.], Alasdair G Kergon, (Fri Aug 31, 2:41 pm)