Re: [PATCH 1/1] md: expose behind writes counter
From: Paul Clements <hidden>
Date: 2009-12-17 22:08:20
Attachments
- md_expose_behind_writes_2.diff [text/x-diff] 3476 bytes · preview
From: Paul Clements <hidden>
Date: 2009-12-17 22:08:20
Neil, Thanks for the feedback... Neil Brown wrote:
On Mon, 14 Dec 2009 11:56:32 -0500 Paul Clements [off-list ref] wrote:quoted
This is a very simple patch that exposes the behind_writes counter of an md array via a sysfs entry. This is helpful when tuning the value of behind_writes. Knowing, for instance, the maximum value over time allows one to set a proper upper value for an array.Hi Paul, while I can see that this information could be useful, I wonder if this is the best way of accessing it. I imagine that the count of behind_writes would change quite quickly, so you would need to sample it at quite a high rate to get a meaningful number. I'm very conscious that the 'active_stripes' number provided by RAID5 is close to useful as it almost always reads a 'zero' even when the array is quite busy. Maybe having a sysfs attribute that reports the maximum value, and allow that maximum to be reset by writing to the attribute?
OK, I did this. I called it behind_writes_top. I also left the behind_writes entry, since it might be useful too. See attached. Thanks, Paul