Thread (2 messages) 2 messages, 2 authors, 2013-05-27

Re: Spinning down idle disks?

From: Vincent Pelletier <hidden>
Date: 2013-05-27 06:46:17

Le dimanche 26 mai 2013 12:49:54, Roy Sigurd Karlsbakk a écrit :
Is it possible somehow to have linux spin down idle disks in an MD raid as
to use MD for a MAID (massive array of idle disks)? I tried to monitor an
idle raid with blktrace, and it seems the array (and its members) is
accessed every two seconds for some reason. The array used with for the
testing is a idle, degraded raid-5.
FWIW, there is a small daemon to spin disks down in a - to me - clever way: 
only reads from device reset spindown timeout. Writes are kept in cache until 
an explicit flush happens.

http://noflushd.sourceforge.net/

This allows skipping superblock refreshes (FS- and MD-level).
It has a large drawback when using it for MD (and other composite devices): it 
doesn't look for slave devices, so if you tell it to control sda and sdb and 
you have md0 on top of both, it will eventually spin down sda and sdb, only to 
manually flush md0, spinning both up again.

I've implemented a quick-hack workaround for this:

https://github.com/vpelletier/pynoflushd

Both implementation have the drawback of increasing the frequency of writes to 
the actual disk: as the daemon take over dirty_writeback_centisecs's job using 
userspace-available flush methods (mine using BLKFLSBUF ioctl, the original 
using fsync on block device), something gets flushed which is usually not (I 
wandered a bit in kernel code without finding how writeback code handles this 
timeout).

I think it would be nice to have an equivalent of dirty_writeback_centisecs at 
device granularity, so that one doesn't have to delegate flushing to a 
userspace daemon.

Regards,
-- 
Vincent Pelletier
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help