All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tomasz Chmielewski <tch@virtall.com>
To: Anand Jain <anand.jain@oracle.com>
Cc: Btrfs BTRFS <linux-btrfs@vger.kernel.org>
Subject: Re: fatal database corruption with btrfs "out of space" with ~50 GB left
Date: Mon, 19 Feb 2018 17:30:26 +0900	[thread overview]
Message-ID: <facafa76748644bd90a7cd283a0444f0@virtall.com> (raw)
In-Reply-To: <d8289a56-5874-dfe9-60fd-72b3c06b1664@oracle.com>

On 2018-02-19 13:29, Anand Jain wrote:
> On 02/14/2018 10:19 PM, Tomasz Chmielewski wrote:
>> Just FYI, how dangerous running btrfs can be - we had a fatal, 
>> unrecoverable MySQL corruption when btrfs decided to do one of these 
>> "I have ~50 GB left, so let's do out of space (and corrupt some files 
>> at the same time, ha ha!)".
> 
>  Thanks for reporting.
> 
>> Running btrfs RAID-1 with kernel 4.14.
> 
>  Can you pls let us know..
>  1. What tool cli/reported/identified that data is corrupted?

mysqld log - mysqld would refuse to start because of database 
corruption.

And, the database wouldn't start even when "innodb_force_recovery = " 
was set to a high/max value.


In the past, with lower kernel versions, we had a similar issue with 
mongod - it wouldn't start anymore due to some corruption which happened 
when we hit "out of space" (again, with dozens of GBs free space).


>  2. Disk error stat using.. btrfs dev stat <mnt>
>     (dev stat is stored on disk)

# btrfs dev stat /var/lib/lxd
[/dev/sda3].write_io_errs    0
[/dev/sda3].read_io_errs     0
[/dev/sda3].flush_io_errs    0
[/dev/sda3].corruption_errs  0
[/dev/sda3].generation_errs  0
[/dev/sdb3].write_io_errs    0
[/dev/sdb3].read_io_errs     0
[/dev/sdb3].flush_io_errs    0
[/dev/sdb3].corruption_errs  0
[/dev/sdb3].generation_errs  0


>  3. Wheather the disk was mounted as degraded any time before?

No. Everything healthy with the disks.


Tomasz Chmielewski
https://lxadm.com

      reply	other threads:[~2018-02-19  8:30 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-14 14:19 fatal database corruption with btrfs "out of space" with ~50 GB left Tomasz Chmielewski
2018-02-15  1:25 ` Duncan
2018-02-15  1:47 ` Qu Wenruo
2018-02-15  4:19   ` Tomasz Chmielewski
2018-02-15  4:32     ` Qu Wenruo
2018-02-15  7:02       ` Tomasz Chmielewski
2018-02-15  7:17         ` Tomasz Chmielewski
2018-02-15  9:06           ` Nikolay Borisov
2018-02-15  7:38         ` Qu Wenruo
2018-02-15  7:50         ` Duncan
2018-02-19  4:29 ` Anand Jain
2018-02-19  8:30   ` Tomasz Chmielewski [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=facafa76748644bd90a7cd283a0444f0@virtall.com \
    --to=tch@virtall.com \
    --cc=anand.jain@oracle.com \
    --cc=linux-btrfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.