On Thu, Jun 1, 2023 at 2:48 PM Daniel Spannbauer <ds@marco.de> wrote:
ext4 only shows in /proc/mounts or moutinfo options that differ from default where default values are set in super block (during creation or by tune2fs). So presumably both options are already set as default. You can check full list of currently used mount options in /proc/fs/ext4/sda4/options
Ok, thats a good hint. So I set the journalmode to writeback
tune2fs -o journal_data_writeback /dev/sda4
According to you there must be the "data=ordered been shown in the findmnt, cat /proc/mounts and mount.
But:
b-sekret:~ # findmnt /dev/sda4 TARGET SOURCE FSTYPE OPTIONS / /dev/sda4 ext4 ro,relatime
As you can see, it is mounted readOnly. Nothing changed to fstab.
The only thing I found in dmesg:
EXT4-fs (sda4): Cannot change data mode on remount.
It seems that the data-mode cannot be changes via fstab if it is the Root-Device.
Yes, if the option cannot be changed on remount you need to pass it to initrd. By default dracut is using current options from /proc/self/mountinfo and stores in initrd which is why changing /etc/fstab and running mkinitrd has no effect. Arguably it is not the best default and violates principle of the least surprise You can a) boot using rootflags=... kernel option and then run mkinitrd to store current options in initrd b) run directly "dracut --fstab ..." to regenerate initrd so it (see "man dracut" for full list of options). "dracut --fstab -f" should recreate initrd for the currently running kernel.