Re: ext4 confusion

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

 



On Tue, Mar 06, 2018 at 03:34:25PM -0800, Randy Dunlap wrote:
> 
> My custom kernel does not use an initramfs at all.

OK, so if you are not using an initramfs at all, it's *normal* for the
file system to be mounted read-only, since it's not safe to run fsck
on the file system unless it is mounted read-only.  So the standard
init scripts (at least in the good old days pre-systemd) expected that
you use the ro option to make sure the root file system is mounted
read-only, and then the init scripts would check the file system if it
was needed, and then the init scripts would remount the file sytsem
read-write afterwards.

As I mentioned, with many modern distro's this is now done in
initramfs, and with Debian it will actually run the fsck *before* the
root file system is even mounted, and then it can just mount it
read/write.  Obviously, if that is what initramfs does, then the init
scripts (or the magic systemd units in the brave new systemd world)
don't need to remount the file system read/write.

To be honest, there is a huge amount of magic these days in the
initramfs and systemd scripts.  I do know that Debian stable supports
using a read-only mount and its systemd setup does the right thing,
because that's how kvm-xfstests works.  But with some of the other
distro's (Red Hat Enterprse Linux especially), it's been magic, and
trying to figure out how it works is something I gave up on a long
time ago.  I was just amazed that it managed to boot over fiber
channel, and I was glad I never had to debug on the freaking thing
worked.  :-/

						- Ted



[Index of Archives]     [Reiser Filesystem Development]     [Ceph FS]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite National Park]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]     [Linux Media]

  Powered by Linux