linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tymoteusz Dolega <tymoteuszdolega@gmail.com>
To: linux-btrfs@vger.kernel.org
Subject: MySQL corruption on BTRFS
Date: Tue, 8 Feb 2022 09:07:33 +0100	[thread overview]
Message-ID: <CAHF2GV6U32gmqSjLe=XKgfcZAmLCiH26cJ2OnHGp5x=VAH4OHQ@mail.gmail.com> (raw)

Hello,
I maybe encountered a bug. I'm using NixOS, and after enabling MySQL with:

services.mysql = {
      enable = true;
      package = pkgs.mariadb;
 };

it cannot even start, and fails with "code=killed, status=6/ABRT". The
problem that MySQL reports in journal is about file corruption. I
attached all logs at the bottom of this mail.
I tried changing database location to different BTRFS SSD, cleanly
formatted, and problem persists. After changing database location to
EXT4 partition, everything works perfectly. I tried newer MySQL
version (from nix-unstable), but still errors show up. Current version
is 10.6.5-MariaDB. I tried deleting DB folder to force it to make it
again. Scrub is clean, check (--readonly) is clean. I have only 1
mount option: "noatime". "mount" reports:
(rw,noatime,ssd,space_cache,subvolid=5,subvol=/).

uname -a
Linux desktop-nixos 5.16.4 #1-NixOS SMP PREEMPT Sat Jan 29 09:59:25
UTC 2022 x86_64 GNU/Linux

btrfs --version
btrfs-progs v5.14.1

sudo btrfs fi show
Label: 'nixos'  uuid: 67b6e734-cd1e-41e3-ab7a-63660e540014
        Total devices 1 FS bytes used 95.05GiB
        devid    1 size 249.00GiB used 98.03GiB path /dev/nvme0n1p5

Label: 'cruc'  uuid: cc51fa3c-57db-42b6-a890-ff5cd7b18f47
        Total devices 1 FS bytes used 125.16MiB
        devid    1 size 931.51GiB used 2.02GiB path /dev/sdb1

btrfs fi df /mnt/cruc
Data, single: total=1.01GiB, used=124.84MiB
System, single: total=4.00MiB, used=16.00KiB
Metadata, single: total=1.01GiB, used=304.00KiB
GlobalReserve, single: total=3.25MiB, used=0.00B

dmesg.log  - https://www.dropbox.com/s/ou52m2hdjzmjy6b/dmesg.log?dl=0
but there is not much there besides you can see I cleanly formatted the drive
mysql - https://www.dropbox.com/s/jjthkfu0anh8n2o/mysql.log?dl=0
log with info about corruption
(links hosted on dropbox, you can see them without logging in)
I will be happy to answer any needed questions.

             reply	other threads:[~2022-02-08  8:07 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-08  8:07 Tymoteusz Dolega [this message]
2022-02-09 21:35 ` MySQL corruption on BTRFS Chris Murphy
2022-02-10  0:54   ` Qu Wenruo
2022-02-11  8:19 ` Forza
2022-02-20  9:41   ` Wang Yugui
2022-02-20  9:55     ` Forza

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='CAHF2GV6U32gmqSjLe=XKgfcZAmLCiH26cJ2OnHGp5x=VAH4OHQ@mail.gmail.com' \
    --to=tymoteuszdolega@gmail.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 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).