OSDN Git Service

Import translated manuals from JM CVS Repository.
[linuxjm/jm.git] / manual / util-linux / original / man8 / mkfs.8
1 .\" -*- nroff -*-
2 .TH MKFS 8 "Jun 1995" "Version 1.9"
3 .SH NAME
4 mkfs \- build a Linux file system
5 .SH SYNOPSIS
6 .B mkfs
7 [
8 .B \-V
9 ]
10 [
11 .B \-t
12 .I fstype
13 ]
14 [
15 .B fs-options
16 ]
17 .I filesys
18 [
19 .I blocks
20 ]
21 .SH DESCRIPTION
22 .B mkfs
23 is used to build a Linux file system on a device, usually
24 a hard disk partition.
25 .I filesys
26 is either the device name (e.g.
27 .IR /dev/hda1 ,
28 .IR /dev/sdb2 )
29 or the mount point (e.g. 
30 .IR / ,
31 .IR /usr ,
32 .IR /home )
33 for the file system.
34 .I blocks
35 is the number of blocks to be used for the file system.
36 .PP
37 The exit code returned by
38 .B mkfs
39 is 0 on success and 1 on failure.
40 .PP
41 In actuality,
42 .B mkfs
43 is simply a front-end for the various file system builders
44 (\fBmkfs\fR.\fIfstype\fR)
45 available under Linux.
46 The file system-specific builder is searched for in a number
47 of directories like perhaps
48 .IR /sbin ,
49 .IR /sbin/fs ,
50 .IR /sbin/fs.d ,
51 .IR /etc/fs ,
52 .I /etc
53 (the precise list is defined at compile time but at least
54 contains
55 .I /sbin
56 and
57 .IR /sbin/fs ),
58 and finally in the directories
59 listed in the PATH enviroment variable.
60 Please see the file system-specific builder manual pages for
61 further details.
62 .SH OPTIONS
63 .TP
64 .B -V
65 Produce verbose output, including all file system-specific commands
66 that are executed.
67 Specifying this option more than once inhibits execution of any
68 file system-specific commands.
69 This is really only useful for testing.
70 .TP
71 .BI -t \ fstype
72 Specifies the type of file system to be built.
73 If not specified, the default file system type
74 (currently ext2) is used.
75 .TP
76 .B fs-options
77 File system-specific options to be passed to the real file 
78 system builder.
79 Although not guaranteed, the following options are supported
80 by most file system builders.
81 .TP
82 .B -c
83 Check the device for bad blocks before building the file system.
84 .TP
85 .BI -l \ filename
86 Read the bad blocks list from
87 .I filename
88 .TP
89 .B -v
90 Produce verbose output.
91 .SH BUGS
92 All generic options must precede and not be combined with
93 file system-specific options.
94 Some file system-specific programs do not support the
95 .I -v
96 (verbose) option, nor return meaningful exit codes.
97 Also, some file system-specific programs do not automatically
98 detect the device size and require the
99 .I blocks
100 parameter to be specified.
101 .SH AUTHORS
102 David Engel (david@ods.com)
103 .br
104 Fred N. van Kempen (waltje@uwalt.nl.mugnet.org)
105 .br
106 Ron Sommeling (sommel@sci.kun.nl)
107 .br
108 The manual page was shamelessly adapted from Remy Card's version
109 for the ext2 file system.
110 .SH SEE ALSO
111 .BR fs (5),
112 .BR badblocks (8),
113 .BR fsck (8),
114 .BR mkdosfs (8),
115 .BR mke2fs (8),
116 .BR mkfs.bfs (8),
117 .BR mkfs.ext2 (8),
118 .BR mkfs.ext3 (8),
119 .BR mkfs.minix (8),
120 .BR mkfs.msdos (8),
121 .BR mkfs.vfat (8),
122 .BR mkfs.xfs (8),
123 .BR mkfs.xiafs (8)