public inbox for linux-btrfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Qu Wenruo <quwenruo.btrfs@gmx.com>
To: Hector Martin <marcan@marcan.st>, Neal Gompa <neal@gompa.dev>,
	Qu Wenruo <wqu@suse.com>
Cc: Josef Bacik <josef@toxicpanda.com>,
	Linux BTRFS Development <linux-btrfs@vger.kernel.org>,
	Anand Jain <anand.jain@oracle.com>,
	David Sterba <dsterba@suse.cz>, Sven Peter <sven@svenpeter.dev>,
	Davide Cavalca <davide@cavalca.name>, Jens Axboe <axboe@fb.com>,
	Asahi Lina <lina@asahilina.net>,
	Asahi Linux <asahi@lists.linux.dev>
Subject: Re: [PATCH v4 0/1] Enforce 4k sectorize by default for mkfs
Date: Thu, 30 Nov 2023 06:57:30 +1030	[thread overview]
Message-ID: <c87f6f12-15ef-4860-a3c8-7038c51eddb1@gmx.com> (raw)
In-Reply-To: <aaee6d4f-4e89-4bc7-8a7e-03ffc8b81a34@marcan.st>



On 2023/11/29 23:28, Hector Martin wrote:
>
>
> On 2023/11/29 6:24, Neal Gompa wrote:
>> On Tue, Nov 28, 2023 at 2:57 PM Qu Wenruo <wqu@suse.com> wrote:
>>>
>>>
>>>
>>> On 2023/11/29 01:31, Hector Martin wrote:
>>>>
>>>>
>>>> On 2023/11/28 1:07, Josef Bacik wrote:
>>>>> On Thu, Nov 16, 2023 at 11:02:23AM -0500, Neal Gompa wrote:
>>>>>> The Fedora Asahi SIG[0] is working on bringing up support for
>>>>>> Apple Silicon Macintosh computers through the Fedora Asahi Remix[1].
>>>>>>
>>>>>> Apple Silicon Macs are unusual in that they currently require 16k
>>>>>> page sizes, which means that the current default for mkfs.btrfs(8)
>>>>>> makes a filesystem that is unreadable on x86 PCs and most other ARM
>>>>>> PCs.
>>>>>>
>>>>>> This is now even more of a problem within Apple Silicon Macs as it is now
>>>>>> possible to nest 4K Fedora Linux VMs on 16K Fedora Asahi Remix machines to
>>>>>> enable performant x86 emulation[2] and the host storage needs to be compatible
>>>>>> for both environments.
>>>>>>
>>>>>> Thus, I'd like to see us finally make the switchover to 4k sectorsize
>>>>>> for new filesystems by default, regardless of page size.
>>>>>>
>>>>>> The initial test run by Hector Martin[3] at request of Qu Wenruo
>>>>>> looked promising[4], and we've been running with this behavior on
>>>>>> Fedora Linux since Fedora Linux 36 (at around 6.2) with no issues.
>>>>>>
>>>>>
>>>>> This is a good change and well documented.  This isn't being ignored, it's just
>>>>> a policy change that we have to be conservative about considering.  We only in
>>>>> the last 3 months have added a Apple Silicon machine to our testing
>>>>> infrastructure (running Fedora Asahi fwiw) to make sure we're getting consistent
>>>>> subpage-blocksize testing.  Generally speaking it's been fine, we've fixed a few
>>>>> things and haven't broken anything, but it's still comes with some risks when
>>>>> compared to the default of using the pagesize.
>>>>>
>>>>> We will continue to discuss this amongst ourselves and figure out what we think
>>>>> would be a reasonable timeframe to make this switch and let you know what we're
>>>>> thinking ASAP.  Thanks,
>>>>
>>>> Reminder that the Raspberry Pi 5 is also shipping with 16K pages by
>>>> default now. The clock is ticking for an ever-growing stream of people
>>>> upset that they can't mount/data-rescue/etc their rPi5 NAS disks from an
>>>> x86 machine ;)
>>>
>>> As long as they are using 5.15+ kernel, they should be able to mount and
>>> use their RPI NAS with disks from x86 machines.
>>>
>>> The change is only for the default mkfs options.
>>>
>>
>> Right, and the thing is, it's fairly common for the disks to be
>> formatted from a Raspberry Pi. So until some kind of support for using
>> any sector size on any architecture regardless of page size lands,
>> this is going to be a big problem.
>>
>
> Yup, I meant what I said.
>
> Someone sets up a rPi5 as a NAS, formats the disk from it, as you would
> normally when setting up such a thing from scratch. Later, the rPi stops
> working, as rPis often do. This person's data is now *completely
> inaccessible* until they find another Raspberry Pi 5 or an Apple Silicon
> laptop.
Got it.

I am putting too much trust on RPI, as my experience is pretty good so
far (just for VM hosting and running fstests), thus I though everyone
would just go x86->aarch64, at least for NAS hosting/VM testing...

>
> This is going to be *common*. And since the 16K decision is made at
> format time, these people are going to be oblivious until they find
> themselves with an urgent need to acquire a Raspberry Pi 5 to access
> their data at all, and then they're going to be mad. So the longer you
> wait to flip the switch, the more people unaware of their own data's
> fragile accessibility condition you will build up, and the more upset
> people you're going to have even long after the change was finally made.

In that case, I'm totally fine to support the switch of default sector
size, sooner than later.

With Asahi already running 4K sector sizes, and I have not received any
death thread for the loss of one's data, I believe the prerequisite for
the switch is already here.

And even if there are hidden bugs, default to 4K is in fact going to
make it faster to get reports and fixed.

Thanks,
Qu
>
> - Hector

  reply	other threads:[~2023-11-29 20:28 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-16 16:02 [PATCH v4 0/1] Enforce 4k sectorize by default for mkfs Neal Gompa
2023-11-16 16:02 ` [PATCH v4 1/1] btrfs-progs: mkfs: Enforce 4k sectorsize by default Neal Gompa
2023-11-17 10:41   ` Eric Curtin
2023-11-27 16:07 ` [PATCH v4 0/1] Enforce 4k sectorize by default for mkfs Josef Bacik
2023-11-28 15:01   ` Hector Martin
2023-11-28 19:57     ` Qu Wenruo
2023-11-28 20:09       ` Roman Mamedov
2023-11-28 20:31         ` Qu Wenruo
2023-11-28 21:24       ` Neal Gompa
2023-11-29 12:58         ` Hector Martin
2023-11-29 20:27           ` Qu Wenruo [this message]
2023-11-30  3:38             ` Neal Gompa
2023-12-13 22:25 ` David Sterba
2024-01-05 23:10   ` Neal Gompa

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=c87f6f12-15ef-4860-a3c8-7038c51eddb1@gmx.com \
    --to=quwenruo.btrfs@gmx.com \
    --cc=anand.jain@oracle.com \
    --cc=asahi@lists.linux.dev \
    --cc=axboe@fb.com \
    --cc=davide@cavalca.name \
    --cc=dsterba@suse.cz \
    --cc=josef@toxicpanda.com \
    --cc=lina@asahilina.net \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=marcan@marcan.st \
    --cc=neal@gompa.dev \
    --cc=sven@svenpeter.dev \
    --cc=wqu@suse.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