linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* hung task timer + btrfs_convert or btrfs balance = OOPS
@ 2014-04-23 20:44 Robert White
  2014-04-23 21:12 ` Marc MERLIN
  0 siblings, 1 reply; 3+ messages in thread
From: Robert White @ 2014-04-23 20:44 UTC (permalink / raw)
  To: linux-btrfs

The first mount of a non-trivial file system after a btrfs_convert, or 
an ongoing btrfs balance operation containing large files may lead to an 
oops (and a pathologically damaged file system) if the hang check timer 
(CONFIG_DETECT_HUNG_TASK=y) is compiled into the linux kernel and not 
disabled.

I've had two systems destroyed after a btrfs_convert. After the 
conversion the first mount took several minutes. The hung task timer 
expired against some internal btrfs_daemon. I think it was 
'[btrfs-transacti]'. Said task then goes oops and the file system was 
chock full of errors. So many that I no longer trusted the conversion so 
mkfs.btrfs and restored from backup.

On another system the same thing happened after a successful convert and 
mount (I'd remembered to disable the timer during the first mount) when 
a btrfs balance was running.

Whatever is blocking in that task really ought not to do that for 2+ 
minutes and sleep on some data structure instead.

As it is, the two options are not happy together. Be sure to

echo 0 > /proc/sys/kernel/hung_task_timeout_secs

to disable the timer before doing a mount or balance after a 
btrfs_convert (and possibly a btrfs balance if it decides to move a very 
large file like a VM disk image).


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-04-23 23:06 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-04-23 20:44 hung task timer + btrfs_convert or btrfs balance = OOPS Robert White
2014-04-23 21:12 ` Marc MERLIN
2014-04-23 22:59   ` Robert White

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).