linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Yordan <y16267966@gmail.com>
To: Anand Jain <anand.jain@oracle.com>
Cc: quwenruo.btrfs@gmx.com, linux-btrfs@vger.kernel.org
Subject: Re: btrfs-convert on 24Gb image corrupts files.
Date: Mon, 6 May 2024 17:57:41 +0300	[thread overview]
Message-ID: <CAE0VrXKbOXprWU7VdPTWK8+St1eeM2hpjvWOYw+BL9HjW-FSFA@mail.gmail.com> (raw)
In-Reply-To: <0f97e260-bb17-48fb-898a-a71cdcf68ba7@oracle.com>

Yes, the same error after patching, and the same error on the original
24G image:

B/btrfs-progs/btrfs-convert sda3.img
btrfs-convert from btrfs-progs v6.8.1

Source filesystem:
  Type:           ext2
  Label:
  Blocksize:      4096
  UUID:           b3a78a9f-37e7-4ccb-bedb-1f800a6a5a19
Target filesystem:
  Label:
  Blocksize:      4096
  Nodesize:       16384
  UUID:           6595aa9c-415d-4ab0-bd9f-9a7f2ee8e3a9
  Checksum:       crc32c
  Features:       extref, skinny-metadata, no-holes, free-space-tree (default)
    Data csum:    yes
    Inline data:  yes
    Copy xattr:   yes
Reported stats:
  Total space:     25769803776
  Free space:       8655269888 (33.59%)
  Inode count:         1572864
  Free inodes:         1325061
  Block count:         6291456
Create initial btrfs filesystem
Create ext2 image file
Create btrfs metadata
ERROR: inode 527126 index 2: identified unsupported merged block
length 9 wanted 10
ERROR: failed to copy ext2 inode 527126: -22
ERROR: error during copy_inodes -22
WARNING: error during conversion, the original filesystem is not modified

On Mon, May 6, 2024 at 4:43 PM Anand Jain <anand.jain@oracle.com> wrote:
>
>
> It is meant to be applied on latest devel branch.
>
>
> With the v2 patches:
>
> $ ./btrfs-convert ~/sda3.img
> btrfs-convert from btrfs-progs v6.8
>
> Source filesystem:
>    Type:           ext2
>    Label:
>    Blocksize:      4096
>    UUID:           b3a78a9f-37e7-4ccb-bedb-1f800a6a5a19
> Target filesystem:
>    Label:
>    Blocksize:      4096
>    Nodesize:       16384
>    UUID:           d8c61c42-1b2c-478d-8ae6-bf45213e8df4
>    Checksum:       crc32c
>    Features:       extref, skinny-metadata, no-holes, free-space-tree
> (default)
>      Data csum:    yes
>      Inline data:  yes
>      Copy xattr:   yes
> Reported stats:
>    Total space:       536870912
>    Free space:        326238208 (60.77%)
>    Inode count:           32768
>    Free inodes:           32743
>    Block count:          131072
> Create initial btrfs filesystem
> Create ext2 image file
> Create btrfs metadata
> ERROR: inode 20 index 0: identified unsupported merged block length 1
> wanted 12
> ERROR: failed to copy ext2 inode 20: -22
> ERROR: error during copy_inodes -22
> WARNING: error during conversion, the original filesystem is not modified
>
>
>
>
>
> On 5/6/24 21:35, Yordan wrote:
> > NO, I have problems applying patch4, so its unpatchet
> >
> > error: patch failed: convert/source-fs.c:316
> > error: convert/source-fs.c: patch does not apply
> >
> > I just sent you a small problematic image so you can test it yourself.
> >
> > On Mon, May 6, 2024 at 4:17 PM Anand Jain <anand.jain@oracle.com> wrote:
> >>
> >>
> >>
> >> On 5/6/24 18:53, Yordan wrote:
> >>> The attached file which is a reduced version of the problematic image,
> >>> produced by removing all files and directories, except 5 of the
> >>> problematic files and their path. Then its filesystem filled with zero
> >>> file, shrinked with "resize2fs" to 512M and compressed to 7M.
> >>>
> >>> md5sum sda3.img.zst
> >>> 9eec41fee47e3db555edeaba5d8d2e9a  sda3.img.zst
> >>>
> >>> (chroot) livecd / # zstd -d sda3.img.zst -o sda3.img
> >>> sda3.img.zst        : 536870912 bytes
> >>> (chroot) livecd / # mount -o ro sda3.img k
> >>> (chroot) livecd / # find k/ -type f | xargs md5sum >files.md5
> >>> (chroot) livecd / # md5sum -c files.md5 | grep -v OK
> >>>
> >>> (chroot) livecd / # umount k
> >>> (chroot) livecd / # B/btrfs-progs/btrfs-convert sda3.img
> >>> btrfs-convert from btrfs-progs v6.8.1
> >>>   > Source filesystem:
> >>>     Type:           ext2
> >>>     Label:
> >>>     Blocksize:      4096
> >>>     UUID:           b3a78a9f-37e7-4ccb-bedb-1f800a6a5a19
> >>> Target filesystem:
> >>>     Label:
> >>>     Blocksize:      4096
> >>>     Nodesize:       16384
> >>>     UUID:           d7c77d2f-d470-450a-ba0e-b6567ad3f4b3
> >>>     Checksum:       crc32c
> >>>     Features:       extref, skinny-metadata, no-holes, free-space-tree (default)
> >>>       Data csum:    yes
> >>>       Inline data:  yes
> >>>       Copy xattr:   yes
> >>> Reported stats:
> >>>     Total space:       536870912
> >>>     Free space:        326238208 (60.77%)
> >>>     Inode count:           32768
> >>>     Free inodes:           32743
> >>>     Block count:          131072
> >>> Create initial btrfs filesystem
> >>> Create ext2 image file
> >>> Create btrfs metadata
> >>> Copy inodes [o] [         1/        25]
> >>> Free space cache cleared
> >>> Conversion complete
> >>>
> >>> (chroot) livecd / # mount -o ro sda3.img k
> >>> (chroot) livecd / # md5sum -c files.md5
> >>> k/root/.mozilla/firefox/s554srh9.default-release/storage/permanent/chrome/idb/3561288849sdhlie.sqlite:
> >>> FAILED
> >>> k/root/.mozilla/firefox/s554srh9.default-release/storage/permanent/chrome/idb/1657114595AmcateirvtiSty.sqlite:
> >>> FAILED
> >>> k/root/.mozilla/firefox/s554srh9.default-release/storage/permanent/chrome/idb/2823318777ntouromlalnodry--naod.sqlite:
> >>> FAILED
> >>> k/root/.mozilla/firefox/s554srh9.default-release/storage/permanent/chrome/idb/2918063365piupsah.sqlite:
> >>> FAILED
> >>> k/root/.mozilla/firefox/s554srh9.default-release/storage/permanent/chrome/idb/3870112724rsegmnoittet-es.sqlite:
> >>> OK
> >>> k/root/.mozilla/firefox/s554srh9.default-release/storage/permanent/chrome/idb/1451318868ntouromlalnodry--epcr.sqlite:
> >>> FAILED
> >>> md5sum: WARNING: 5 computed checksums did NOT match
> >>>
> >>
> >>
> >> Are these test results with the v2 patchset? Thanks, Anand.
> >>
> >>
> >>> Regards, Jordan.

  reply	other threads:[~2024-05-06 14:58 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-05 22:30 You can reproduce it yourself now Yordan
2024-05-06 10:53 ` btrfs-convert on 24Gb image corrupts files Yordan
2024-05-06 13:17   ` Anand Jain
2024-05-06 13:35     ` Yordan
2024-05-06 13:43       ` Anand Jain
2024-05-06 14:57         ` Yordan [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-05-05 15:05 Yordan
2024-05-05 22:31 ` Qu Wenruo
2024-05-05  0:34 jordan.j
2024-05-05  0:50 ` Qu Wenruo
2024-05-05  0:56 ` Anand Jain
2024-05-05  5:54   ` Qu Wenruo
2024-05-06  0:33     ` Anand Jain

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=CAE0VrXKbOXprWU7VdPTWK8+St1eeM2hpjvWOYw+BL9HjW-FSFA@mail.gmail.com \
    --to=y16267966@gmail.com \
    --cc=anand.jain@oracle.com \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=quwenruo.btrfs@gmx.com \
    /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).