Copyright 2006 by Theodore Ts'o. All Rights Reserved.
This file may be copied under the terms of the GNU Public License.
The
mke2fs.conf file uses an INI-style format. Stanzas, or top-level sections, are
delimited by square braces: [ ]. Within each section, each line
defines a relation, which assigns tags to values, or to a subsection,
which contains further relations or subsections.
Tags can be assigned multiple values
An example of the INI-style format used by this configuration file
follows below:
[section1]
tag1 = value_a
tag1 = value_b
tag2 = value_c
[section 2]
tag3 = {
subtag1 = subtag_value_a
subtag1 = subtag_value_b
subtag2 = subtag_value_c
}
tag1 = value_d
tag2 = value_e
}
Comments are delimited by a semicolon (';') or a hash ('#') character at the beginning of the comment, and are terminated by the end of line character.
Tags and values must be quoted using double quotes if they contain spaces. Within a quoted string, the standard backslash interpretations apply: "\en" (for the newline character), "\et" (for the tab character), "\eb" (for the backspace character), and "\e\e" (for the backslash character).
The following stanzas are used in the mke2fs.conf file. They will be described in more detail in future sections of this document.
[defaults] Contains relations which define the default parameters used by mke2fs (8). In general, these defaults may be overridden by a definition in the fs_types stanza, or by an command-line option provided by the user.
[fs_types] Contains relations which define defaults that should be used for specific filesystem types. The filesystem type can be specified explicitly using the -T option to mke2fs (8). If no filesystem type is specified, mke2fs (8) will use the filesystem type floppy if the filesystem size is less than or equal to 3 megabytes. If the filesystem size is greater than 3 but less than or equal to 512 megabytes, mke2fs (8) will use the filesystem small . Otherwise, mke2fs (8) will use the default filesystem type default .
base_features This relation specifies the filesystems features which are enabled in newly created filesystems. It may be overridden by the base_features relation found in the filesystem-type-specific subsection of the [fs_types] stanza.
default_features This relation specifies a set of features that should be added or removed to the features listed in the base_features relation. It may be overridden by the filesystem-specific default_features in the filesystem-type subsection of [fs_types] , and by the -O command-line option to mke2fs (8).
blocksize This relation specifies the default blocksize if the user does not specify a blocksize on the command line, and the filesystem-type specific section of the configuration file does not specify a blocksize.
inode_ratio This relation specifies the default inode ratio if the user does not specify one on the command line, and the filesystem-type specific section of the configuration file does not specify a default inode ratio.
inode_size This relation specifies the default inode size if the user does not specify one on the command line, and the filesystem-type specific section of the configuration file does not specify a default inode size.
[fs_types]
small = {
blocksize = 1024
inode_ratio = 4096
}
floppy = {
blocksize = 1024
}
For each filesystem type, the following tags may be used in that fs_type's subsection:
base_features This relation specifies the features which are enabled for this filesystem type.
default_features This relation specifies set of features which should be enabled or disabled to the features listed in the base_features relation. It may be overridden by the -O command-line option to mke2fs (8).
blocksize This relation specifies the default blocksize if the user does not specify a blocksize on the command line.
inode_ratio This relation specifies the default inode ratio if the user does not specify one on the command line.
inode_size This relation specifies the default inode size if the user does not specify one on the command line.
/etc/mke2fs.conf The configuration file for mke2fs (8).