.TH MKFS 1 .SH NAME mkfs \- make a file system .SH SYNOPSIS .in +5 .ti -5 .B mkfs .RB [ \-t .IR type ] .RB [ \-i .IR inodes ] .RB [ \-b .IR bpi ] .RB [ \-p .IR priority ] .RB [ \-TDL ] .I device .RI [ size ] .in -5 .SH DESCRIPTION .B Mkfs make a Minix file system on a the block special device, or prepares the device for use as a paging device. .PP This .B mkfs is really a forerunner to .B mkfs1 through .BR mkfs2f , see .BR mkfs1 (1) for a more details. .PP Before .B mkfs calls any of the other programs to do the real work, it first checks if .I device is mounted, because touching a mounted file system will confuse the system. .PP Unlike the other programs the .I size argument is optional. .B Mkfs will do a binary search for the end of the device to determine its size if not given. You can specify a size to .B mkfs if you want to make a small file system, or if you are using an old 360k PC drive whose size can't be sensed automatically. (Or if you want to use a proto file, which is accepted if size is not a number.) .PP The maximum file system size is 64 Mb for the V1 types, and 1 Gb for V2. .SH OPTIONS .TP .BI \-t " type" Make a file system of type .BR 1 , .BR 2 , .BR 1f , .BR 2f , a swap device .RB ( swap ), or add swap to the second half of a device .RB ( +swap ). If the type is not given then the fstab is searched for a type, otherwise an error is reported. The odd .B +swap type is used to initialize an area behind a file system as swap space. First you make a file system on a device that is smaller than the device allows. (By using a smaller .I size argument.) Then you use .B +swap to mark the rest of the device as swap. .TP .BI \-i " inodes" Make a file system with exacly this many inodes. Use this option if you need a certain number of inodes, like on the root file system for all the device files. Minix file systems can't have more than 65535 inodes, so the number of inodes is truncated to this number. .TP .BI \-b " bpi" Sets the average number of bytes per inode. The number of inodes is computed by dividing the size of the device by this ratio. By default .B \-b 3072 is assumed for small file systems, increasing to 4 kb at 8 Mb, 5 kb at 16 Mb, 6 kb at 32 Mb, 7 kb at 64 Mb and 8 kb at 128 Mb and above. (It is assumed that larger file systems have larger files.) .TP .BI \-p " priority" The priority of a swap device tells which device should be preferred for swapping. Highest priority wins. .I Priority is a signed number, by default 0. .TP .B \-TDL These options are passed on to the real mkfs program in lowercase. .SH "SEE ALSO" .BR mkfs1 (1), .BR fstab (5), .BR mount (1). .SH DIAGNOSTICS .RB $ " mkfs -t 2f /dev/fd0" .br /dev/fd0: V2 flex file system, 1440 kilobytes, 480 inodes, 3072 bytes/inode .SH BUGS Four different programs with just minor differences is a bug in itself. .PP The V1 file systems lack accessed and inode changed times, and are too small for serious use. New file systems should be V2. .PP A V3 file system with more inodes is badly needed. .SH AUTHOR Kees J. Bot (kjb@cs.vu.nl) .\" .\" $PchId: mkfs.1,v 1.3 1995/11/27 22:10:43 philip Exp $