missing y2038 support
missing y2038 support
Posted Mar 8, 2022 8:03 UTC (Tue) by pm215 (subscriber, #98099)In reply to: missing y2038 support by arnd
Parent article: When and why to deprecate filesystems
[*] I think of all these as basically the same thing, which may or may not be an incorrect mental model, but which I suspect is not an uncommon one...
Posted Mar 8, 2022 8:22 UTC (Tue)
by TomH (subscriber, #56149)
[Link] (3 responses)
You can increase the size with "tune2fs -I <device>" but a fsck needs to be done first so the filesystem will need to be unmounted and you probably want to read what the manual page says before trying it.
Posted Mar 8, 2022 9:02 UTC (Tue)
by arnd (subscriber, #8866)
[Link]
Posted Mar 8, 2022 17:55 UTC (Tue)
by smurf (subscriber, #17840)
[Link]
SCNR …
Posted Mar 8, 2022 19:37 UTC (Tue)
by pm215 (subscriber, #98099)
[Link]
Posted Mar 8, 2022 8:48 UTC (Tue)
by arnd (subscriber, #8866)
[Link]
missing y2038 support
Ah, I did not know that tune2fs could do it, should have read your reply first. However, it seems this does not help with
missing y2038 support
Changing the inode size not supported for filesystems with the flex_bg feature enabled.
It apparently works on ext4 file systems without the flex_bg feature, and on ext2/ext3 images that do not support flex_bg in the first place, but apparently not on small ext4 images that were created with flex_bg or had it (irreversibly) added later.
missing y2038 support
missing y2038 support
I don't think you can convert between those in place without a full backup/restore.
One way to find out the inode format is to use the "stats" command in debugfs. It appears that at least in e2fsprogs version 1.45.7, the default in mkfs is still to use small inodes for smaller file system images, regardless of the file system type, so an ext2 file system image over 512MB is not actually compatible with the ext2 format unless you manually set the inode size, and smaller ext4 images continue having the y2038 problem:
missing y2038 support
$ truncate --size=511M ext4.img
$ mkfs -t ext4 -q ext4.img
$ echo stats | debugfs ext4.img 2>&1 | grep "Inode size"
Inode size: 128
$ truncate --size=512M ext2.img
$ mkfs -t ext2 -q ext2.img
$ echo stats | debugfs ext2.img 2>&1 | grep "Inode size"
Inode size: 256
The defaults are configured in /etc/mke2fs.conf, which on my system contains:
small = {
inode_size = 128
inode_ratio = 4096
}
Removing this bit makes mkfs use 256 byte inodes by default, regardless of the size.