blob: 89fd28c79139745225faa99aed87e39d22b4099c [file] [log] [blame]
.TH mkfs.xfs.d 5
.SH NAME
mkfs.xfs.d \- mkfs.xfs configuration directory
.SH DESCRIPTION
.B mkfs.xfs (8)
uses a set of initial default parameters for configuration. These defaults
are conservatively decided by the community as xfsprogs and features for XFS
in the kernel advance. One can override these default on the
.B mkfs.xfs (8)
command line, but there are cases where it is desirable for sensible defaults
to always be specified by the system where
.B mkfs.xfs (8)
runs on. This may desirable for example on systems with old kernels where the
built-in default parameters on
.B mkfs.xfs (8)
may not be able to create a filesystem which the old kernel supports and it
would be unclear what parameters are needed to produce a compatible filesystem.
Overriding
.B mkfs.xfs (8)
built-in defaults may also be desirable if you have a series of systems with
different kernels and want to be able to create filesystems which all systems
are able to support properly.
.PP
The XFS configuration directory
.B mkfs.xfs.d (5)
can be used to define different configuration file types which can be used to
override the built-in default parameters by
.B mkfs.xfs (8).
Different configuration file types are supported, the default
configuration file type,
.I /etc/mkfs.xfs.d/default
, will be looked for first and if present will be used to override
.B mkfs.xfs (8)
built-in default parameters. You can override the configuration file type by
specifying the type when using
.B mkfs.xfs (8)
by using the
.B -T
parameter. For example:
.I mkfs.xfs -T experimental -f /dev/sda1
will make
.B mkfs.xfs (8)
look for and use the configuration file type
.I /etc/mkfs.xfs.d/experimental
to override
.B mkfs.xfs (8)
default parameters. If you need to override the full path for a configuration
file type you can use the
.I MKFS_XFS_CONFIG
environment variable prior to calling
.B mkfs.xfs (8)
to define the
full path to the configuration file to be used. If you used the
.B -T
parameter or if you set the
.I MKFS_XFS_CONFIG
environment variable the configuration file must be present and should parse
correctly.
.PP
Parameters passed to to the
.B mkfs.xfs (8)
command line always override any defaults set on the configuration file used.
.PP
.B mkfs.xfs (8)
will always describe what configuration file was used, if any
was used at all. To verify which configuration file would be used prior to
execution of
.B mkfs.xfs (8)
you can use
.I mkfs.xfs -N.
.PP
.SH DEFAULT PARAMETERS
Default parameters for
.B mkfs.xfs (8)
consists of a small subset of the parameters one can set with on the command
line. Default parameters can only be either enabled or disabled, you can set
their value to 1 to enable or 0 to disable. Below we list the different
supported default parameters which can be defined on configuration files, along
with the current built-in setting.
.PP
.BI [data]
.br
.BI noalign=0
.PP
.BI [inode]
.br
.BI align=1
.br
.BI projid32bit=1
.br
.BI sparse=0
.PP
.BI [log]
.br
.BI lazy-count=1
.PP
.BI [metadata]
.br
.BI crc=1
.br
.BI finobt=1
.br
.BI rmapbt=0
.br
.BI reflink=0
.PP
.BI [naming]
.br
.BI ftype=1
.PP
.BI [rtdev]
.br
.BI noalign=0
.PP
.SH SEE ALSO
.BR mkfs.xfs (8),
.BR xfsctl (3),
.BR xfs_info (8),
.BR xfs_admin (8),
.BR xfsdump (8),
.BR xfsrestore (8).