mkfs - make a file system

     mkfs [-t type] [-i inodes] [-b bpi] [-p priority] [-TDL] device [size]

     Mkfs make a Minix file system on a the block special device, or  prepares
     the device for use as a paging device.

     This mkfs is really a forerunner to mkfs1 through  mkfs2f,  see  mkfs1(1)
     for a more details.

     Before mkfs calls any of the other programs to do the real work, it first
     checks  if device is mounted, because touching a mounted file system will
     confuse the system.

     Unlike the other programs the size argument is optional.  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 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.)

     The maximum file system size is 64 Mb for the V1 types, and 1 Gb for V2.


     -t type
          Make a file system of type 1, 2, 1f, 2f, a swap  device  (swap),  or
          add swap to the second half of a device (+swap).  If the type is not
          given then the fstab is searched for a type, otherwise an  error  is
          reported.  The odd +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 size
          argument.)  Then you use +swap to mark the rest  of  the  device  as

     -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.

     -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 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.)

     -p priority
          The priority of a swap device tells which device should be preferred
          for  swapping.  Highest priority wins.  Priority is a signed number,
          by default 0.

     -TDL These options are passed on to the real mkfs program in lowercase.

     mkfs1(1), fstab(5), mount(1).

     $ mkfs -t 2f /dev/fd0
     /dev/fd0:  V2  flex  file  system,  1440  kilobytes,  480  inodes,   3072

     Four different programs with just minor differences is a bug in itself.

     The V1 file systems lack accessed and inode changed times,  and  are  too
     small for serious use.  New file systems should be V2.

     A V3 file system with more inodes is badly needed.

     Kees J. Bot (