lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 19 May 2017 12:48:41 -0400
From:   Colin Walters <walters@...bum.org>
To:     Colin Walters <walters@...bum.org>, "Theodore Ts'o" <tytso@....edu>
Cc:     "Darrick J. Wong" <darrick.wong@...cle.com>,
        xfs <linux-xfs@...r.kernel.org>,
        "linux-fsdevel" <linux-fsdevel@...r.kernel.org>,
        "linux-ext4" <linux-ext4@...r.kernel.org>
Subject: Re: [PATCH] vfs: freeze filesystems just prior to reboot

On Fri, May 19, 2017, at 12:34 PM, Colin Walters wrote:
>
> So as far as I can see, a userspace API to ensure the journal is
> flushed on a mounted filesystem is going to be necessary for
> the general case.  I don't have a strong opinion on whether or not
> that's `syncfs()` - if it's e.g. a `XFS_IOC_FREEZE` `_THAW` pair
> that seems OK to me too.

Or (thinking about this more) maybe we indeed could implement that today by pivoting back to
the initramfs, and using umount()+mount() as our "syncfs() + journal flush" implementation.

Basically when we have to update /boot, we unmount, then remount again and add
new kernel+initramfs, unmount, remount and mv(/boot/grub2.conf.new,/boot/grub2.conf),
then finally unmount again.

In current design this would require keeping the initramfs resident in memory
just for this purpose, or to re-synthesize it on shutdown.

Not impossible, but it'd sure be simpler if say syncfs() had a flags argument
and there were a special "flush the journal" argument for this.

Powered by blists - more mailing lists