]> git.ipfire.org Git - thirdparty/e2fsprogs.git/blame - misc/mke2fs.8.in
ChangeLog, pass1b.c:
[thirdparty/e2fsprogs.git] / misc / mke2fs.8.in
CommitLineData
3839e657 1.\" -*- nroff -*-
a418d3ad
TT
2.\" Copyright 1993, 1994, 1995 by Theodore Ts'o. All Rights Reserved.
3.\" This file may be copied under the terms of the GNU Public License.
4.\"
74becf3c 5.TH MKE2FS 8 "@E2FSPROGS_MONTH@ @E2FSPROGS_YEAR@" "E2fsprogs version @E2FSPROGS_VERSION@"
3839e657
TT
6.SH NAME
7mke2fs \- create a Linux second extended file system
8.SH SYNOPSIS
9.B mke2fs
10[
11.B \-c
12|
13.\" .B \-t
14.\" test
15.\" |
16.B \-l
1e3472c5 17.I filename
3839e657
TT
18]
19[
20.B \-b
1e3472c5 21.I block-size
3839e657
TT
22]
23[
24.B \-f
1e3472c5 25.I fragment-size
3839e657
TT
26]
27[
28.B \-i
1e3472c5 29.I bytes-per-inode
3839e657
TT
30]
31[
5515e6b4
TT
32.B \-N
33.I number-of-inodes
34]
35[
3839e657 36.B \-m
1e3472c5
TT
37.I reserved-blocks-percentage
38]
39[
40.B \-o
41.I creator-os
3839e657
TT
42]
43[
f3db3566
TT
44.B \-q
45]
46[
a29f4d30
TT
47.B \-r fs-revision-level
48]
49[
50.B -R raid_options
51]
52[
521e3685
TT
53.B -s sparse-super-flag
54]
55[
3839e657
TT
56.B \-v
57]
f3db3566 58[
74becf3c
TT
59.B \-F
60]
61[
1e3472c5
TT
62.B \-L
63.I volume-label
64]
65[
66.B \-M
67.I last-mounted-directory
68]
69[
f3db3566
TT
70.B \-S
71]
818180cd 72[
50787ea2
TT
73.B \-T
74.I filesystem-type
75]
76[
818180cd
TT
77.B \-V
78]
1e3472c5 79.I device
3839e657 80[
1e3472c5 81.I blocks-count
3839e657
TT
82]
83.SH DESCRIPTION
84.B mke2fs
85is used to create a Linux second extended file system on a device (usually
86a disk partition).
87.br
88.I device
89is the special file corresponding to the device (e.g /dev/hdXX).
90.br
91.I blocks-count
92is the number of blocks on the device. If omitted,
93.B mke2fs
94automagically figures the file system size.
95.SH OPTIONS
96.TP
97.I -b block-size
98Specify the size of blocks in bytes.
99.TP
100.I -c
101Check the device for bad blocks before creating the file system, using a
102fast read-only test.
103.TP
104.I -f fragment-size
105Specify the size of fragments in bytes.
106.TP
107.I -i bytes-per-inode
108Specify the bytes/inode ratio.
109.B mke2fs
110creates an inode for every
111.I bytes-per-inode
50787ea2
TT
112bytes of space on the disk.
113The larger the bytes-per-inode ratio, the fewer inodes will be created.
114This value generally shouldn't be smaller than
115the blocksize of the filesystem, since then too many inodes will be made.
116Be warned that is not possible to expand the number of inodes on a
117filesystem after it is created, so be careful decided the correct
118value for this parameter.
3839e657 119.TP
5515e6b4
TT
120.I -N number-of-inodes
121overrides the default calculation of the number of inodes that should be
122reserved for the filesystem (which is based on the number of blocks and
123the bytes-per-inode ratio). This allows the user to specify the number
124of desired inodes directly.
125.TP
3839e657
TT
126.I -l filename
127Read the bad blocks list from
583ccdc3 128.I filename.
3839e657
TT
129\.
130.TP
131.I -m reserved-blocks-percentage
132Specify the percentage of reserved blocks for the super-user. This value
133defaults to 5%.
134.\" .TP
135.\" .I -t test
136.\" Check the device for bad blocks before creating the file system
137.\" using the specified test.
138.TP
1e3472c5
TT
139.I -o
140Manually override the default value of the "creator os" field of the
141filesystem. Normally the creator field is set by default to the native OS
583ccdc3
TT
142of the
143.B mke2fs
144executable.
1e3472c5 145.TP
f3db3566 146.I -q
583ccdc3
TT
147Quiet execution. Useful if
148.B mke2fs
149is run in a script.
f3db3566 150.TP
521e3685
TT
151.I -s sparse-super-flag
152If sparse-super-flag is 1, then turn on the sparse superblock flag.
153If 0, then turn off the sparse superblock flag. (Currently, the sparse
a29f4d30
TT
154superblock flag defaults to off.)
155.B Warning:
156The Linux 2.0 kernel does not properly support this feature. Neither do
157all Linux 2.1 kernels; please don't use this unless you know what you're
158doing!
521e3685 159.TP
3839e657
TT
160.I -v
161Verbose execution.
7f88b043 162.TP
74becf3c 163.I -F
583ccdc3
TT
164Force
165.B mke2fs
166to run, even if the specified device is not a
ca3c3285 167block special device, or appears to be mounted.
f3db3566 168.TP
1e3472c5
TT
169.I -L
170Set the volume label for the filesystem.
171.TP
172.I -M
173Set the last mounted directory for the filesystem. This might be useful
174for the sake of utilities that key off of the last mounted directory to
175determine where the filesytem should be mounted.
176.TP
a29f4d30
TT
177.I -r revision
178Set the filesystem revision for the new filesystem. Note that 1.2
179kernels only support revision 0 filesystems.
180.TP
181.I -R raid_options
cb620174 182Set raid-related options for the filesystem. Raid options are comma
a29f4d30
TT
183separated, and may take an argument using the equals ('=') sign.
184Currently the only supported argument is
185.I stride
186which takes as its argument the number of blocks in a RAID stripe.
187.TP
f3db3566
TT
188.I -S
189Write superblock and group descriptors only. This is useful if all of
190the superblock and backup superblocks are corrupted, and a last-ditch
583ccdc3
TT
191recovery method is desired. It causes
192.B mke2fs
193to reinitialize the
f3db3566
TT
194superblock and group descriptors, while not touching the inode table
195and the block and inode bitmaps. The
196.B e2fsck
197program should be run immediately after this option is used, and there
7f88b043 198is no guarantee that any data will be salvageable.
818180cd 199.TP
50787ea2
TT
200.I -T fs-type
201Specify how the filesystem is going to be used, so that mke2fs can
202automatically determine the optimal filesystem parameters. The only
203filesystem type which is currently supported is "news".
204.TP
818180cd 205.I -V
50787ea2 206Print the version number of
818180cd
TT
207.B mke2fs
208and exit.
3839e657
TT
209.SH AUTHOR
210This version of
211.B mke2fs
a418d3ad 212has been written by Theodore Ts'o <tytso@mit.edu>.
3839e657
TT
213.SH BUGS
214.B mke2fs
215accepts the -f option but currently ignores it because the second
216extended file system does not support fragments yet.
217.br
218There may be some other ones. Please, report them to the author.
219.SH AVAILABILITY
220.B mke2fs
a789d840
TT
221is part of the e2fsprogs package and is available for anonymous
222ftp from tsx-11.mit.edu in /pub/linux/packages/ext2fs.
3839e657 223.SH SEE ALSO
e72a9ba3 224.BR badblocks (8),
3839e657
TT
225.BR dumpe2fs (8),
226.BR e2fsck (8),
227.BR tune2fs (8)