Re: [PATCH] vfs: freeze filesystems just prior to reboot

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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.

--
To unsubscribe from this list: send the line "unsubscribe linux-xfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux