make_ext4fs to generate filesystem
make_ext4fs to generate filesystem
Posted Oct 8, 2020 22:39 UTC (Thu) by jhhaller (guest, #56103)Parent article: The ABI status of filesystem formats
It was not hard to slightly modify mke2fs to take a manifest of files (and file of contents for regular files), and use the functions available to mke2fs to write the special files, permissions, directories, and file content to the ISO. I based the manifest loosely on the syntax of the contents of the proto argument of Unix 6th edition mkfs command - http://man.cat-v.org/unix-6th/8/mkfs - and added options for other file types including both symbolic and hard links. But, by using mke2fs, it at least used the functions built into the filesystem to populate the parts of the filesystem, making corruption significantly less likely. It would make two passes through the internal data model of the manifest, the first time writing inodes, and the second time writing the file contents. I don't remember if all-zero blocks were suppressed to support holes, I suspect not, as few files we installed had large all-zero blocks.
It was just more work than I wanted to do to get approval for releasing the changes externally, and get it accepted into ext4 source code, so it stayed internal. Since we never redistributed the tool externally, there was no need to share it, even though the change was under GPL. Sorry, Google and Ted Ts'o.
