Skip to contentSkip to conversation

BTRFS in laptop-mode

DISCUSSION Adam Ryczkowski 2 participants 2 messages May 14, 2013 Btrfs file system

lore
Share & tools
lore
#0 lore raw

Welcome,

What are perspectives on BTRFS complying with laptop-mode and stop writing to disk every 30 sec?

The thread was asked several years before (http://mailman.samwel.tk/pipermail/laptop-mode/2012-February/000520.html), but time went by and maybe the situation became a little more on the bright side...? With kernel 3.8.11 I can still see with lm-profiler a lot of "btrfs-transacti" and ""btrfs-submit-1" events, roughly once every 30 sec.

Is there any tunable switch, that can delay such writes to, say, 15 minutes, or better yet: until the disk started spinning anyway?

Signature · 3 lines
Adam Ryczkowski
+48505919892 <callto:+48505919892>
Skype:sisteczko <skype:sisteczko>
#1 lore raw
Quoted 5 lines · Adam Ryczkowski

What are perspectives on BTRFS complying with laptop-mode and stop writing to disk every 30 sec?

Is there any tunable switch, that can delay such writes to, say, 15 minutes, or better yet: until the disk started spinning anyway?

30 seconds is the regular transaction commit interval. Tweaking the value is easy (via a mount option to make it clearly visible):

http://lxr.free-electrons.com/source/fs/btrfs/disk-io.c#L1691

but has implications about data safety in case of a long delay in combination with a crash.

david