From: Richard Weinberger <richard@nod.at>
To: Chris Murphy <lists@colorremedies.com>
Cc: "Pali Rohár" <pali.rohar@gmail.com>,
linux-fsdevel <linux-fsdevel@vger.kernel.org>
Subject: Re: Is rename(2) atomic on FAT?
Date: Fri, 25 Oct 2019 11:50:37 +0200 (CEST) [thread overview]
Message-ID: <1376825056.38827.1571997037107.JavaMail.zimbra@nod.at> (raw)
In-Reply-To: <CAJCQCtTU3NXrg=yVosYcj6F6NQLQ21hO3Xd=ta=JCZWjRUh8QQ@mail.gmail.com>
----- Ursprüngliche Mail -----
> Von: "Chris Murphy" <lists@colorremedies.com>
> An: "richard" <richard@nod.at>
> CC: "Chris Murphy" <lists@colorremedies.com>, "Pali Rohár" <pali.rohar@gmail.com>, "linux-fsdevel"
> <linux-fsdevel@vger.kernel.org>
> Gesendet: Freitag, 25. Oktober 2019 11:22:17
> Betreff: Re: Is rename(2) atomic on FAT?
> On Fri, Oct 25, 2019 at 12:33 AM Richard Weinberger <richard@nod.at> wrote:
>>
>> ----- Ursprüngliche Mail -----
>> >> U-boot, for example. Of course it does not so for any filesystem, but whe=
>> > re
>> >> it is needed and makes sense.
>> >
>> > Really? uboot does journal replay on ext3/4? I think at this point the
>> > most common file system on Linux distros is unquestionably ext4, and
>> > the most common bootloader is GRUB and for sure GRUB is no doing
>> > journal replay on anything, including ext4.
>>
>> For ext4 it does a replay when you start to write to it.
>
> That strikes me as weird. The bootloader will read from the file
> system before it writes, and possibly get the wrong view of the file
> system's true state because journal replay wasn't done.
This can't happen. U-boot is strictly single threaded, no interrupts,
no nothing.
For the ext4 case in U-boot, it does a replay not to have clean file
system upon read but to not corrupt it upon write.
For UBIFS, for example, U-boot does a replay also before reading.
But it replays into memory. The journal size is fixed and known,
so no big deal.
>> > Yeah that's got its own difficulties, including the way distro build
>> > systems work. I'm not opposed to it, but it's a practical barrier to
>> > adoption. I'd almost say it's easier to make Btrfs $BOOT compulsory,
>> > make static ESP compulsory, and voila!
>>
>> I really don't get your point. I thought you are designing a "sane"
>> system which can tolerate powercuts down an update.
>> Why care about distros?
>> The approach with Linux being a "bootloader" is common for embedded/secure
>> systems.
>
> I want something as generic as possible, so as many use cases have
> reliable kernel/bootloader updates as possible, so that fewer users
> experience systems face planting following such updates. Any system
> can experience an unscheduled, unclean shutdown. Exceptions to the
> generic case should be rare and pretty much be about handling hardware
> edge cases.
Don't forget UEFI updates. ;-)
Really, you can't have it all on a x86 system in such a generic way.
Thanks,
//richard
next prev parent reply other threads:[~2019-10-25 9:50 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-21 19:57 Is rename(2) atomic on FAT? Chris Murphy
2019-10-21 21:44 ` Richard Weinberger
2019-10-22 10:54 ` Pali Rohár
2019-10-23 0:10 ` Chris Murphy
2019-10-23 11:50 ` Pali Rohár
2019-10-23 14:21 ` Chris Murphy
2019-10-23 17:16 ` Pali Rohár
2019-10-23 19:18 ` Chris Murphy
2019-10-23 21:21 ` Richard Weinberger
2019-10-23 21:56 ` Chris Murphy
2019-10-23 22:22 ` Richard Weinberger
2019-10-24 21:46 ` Chris Murphy
2019-10-24 21:57 ` Pali Rohár
2019-10-24 22:19 ` Chris Murphy
2019-10-24 22:16 ` Richard Weinberger
2019-10-24 22:26 ` Chris Murphy
2019-10-24 22:33 ` Richard Weinberger
2019-10-25 9:22 ` Chris Murphy
2019-10-25 9:50 ` Richard Weinberger [this message]
2019-10-23 12:53 ` Colin Walters
2019-10-23 14:24 ` Chris Murphy
2019-10-23 17:26 ` Colin Walters
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=1376825056.38827.1571997037107.JavaMail.zimbra@nod.at \
--to=richard@nod.at \
--cc=linux-fsdevel@vger.kernel.org \
--cc=lists@colorremedies.com \
--cc=pali.rohar@gmail.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 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.