Re: ext4 confusion

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

 



On Mon, Mar 05, 2018 at 08:17:10PM -0800, Randy Dunlap wrote:
> 
> ext4_fill_super() tells me:
> 
> [    3.033174] EXT4-fs (sda5): couldn't mount as ext3 due to feature incompatibilities
> [    3.100186] EXT4-fs (sda5): mounted filesystem with ordered data mode. Opts: (null)
> [    3.102683] VFS: Mounted root (ext4 filesystem) readonly on device 8:5.
> 
> This is a new install, new filesystem. It has never been ext2 or ext3.
> 
> After bootup and before I do anything else, I can remount /dev/sda5 on / as
> rw and everything is OK.

What is the boot command-line that are you using?  What does
/proc/cmdline say?  Mine says (for example):

% cat /proc/cmdline 
BOOT_IMAGE=/vmlinuz-4.15.3-00026-g373ea7d39542 root=/dev/mapper/cwcc-root ro fbcon=font:sun12x22 quiet

The ro mount option is usually what causes the root file system to be
mounted read-only.

I would check and see whether you are using the same init script path
for your custom kernel versus your distro kernel.  In particular, is
the initramfs the same for both?  With Debian, there is an initial
ramdisk which is used:

	linux	/vmlinuz-4.15.3-00026-g373ea7d39542 root=/dev/mapper/cwcc-root ro fbcon=font:sun12x22 quiet
	echo	'Loading initial ramdisk ...'
	initrd	/initrd.img-4.15.3-00026-g373ea7d39542

With the Debian initial ram disk, e2fsck is actually run on the file
system *before* it is mounted, and then it is mounted under userspace
control, and the kernel's default autoprobing isn't used at all.  So
with Debian's initramfs, it *knows* it is an ext4 file system and it
mounts it directly as ext4, so in my kernel logs I just see this:

Mar  5 18:26:11 cwcc kernel: [   15.073579] EXT4-fs (dm-1): mounted filesystem with ordered data mode. Opts: (null)

So I don't see the "VFS: mounting root..." message at all.  I don't
know what your distribution is doing, but you might want to check and
see if the "VFS: mounting root" is showing up when you are booting the
distro-kernel.  This really smells like a problem with how the
initramfs for your custom kernel was set up...

	      	   	  	     - 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