mkfs_vxfs(ADM)
mkfs_vxfs - construct a VERITAS File System
Synopsis
mkfs [-F vxfs] [generic_options] [-o specific_options] special size
Description
mkfs constructs a file system by writing on the special file special unless the -o N flag has been specified. The numeric size specifies the number of 512-byte sectors in the file system.
size can also be specified with a suffix to indicate a unit of measure other than sectors. Append k or K to indicate the value is in kilobytes, m or M to indicate megabytes, or g or G to indicate gigabytes. An appended letter may be separated from the number by a space, in which case the letter and number should be enclosed in a set of quotes (for example, "512 k").
mkfs builds a file system with a root directory and a
lost+found directory (see
fsck(ADM)).
The file system constructed can have disk layout Version 1, disk layout
Version 2, or disk layout Version 4. Version 2 supports dynamic inode
allocation. Version 4 adds support for large files. The default is
Version 4.
The number of inodes allocated to a file system depends on the disk layout version. For Version 1 file systems, the default number of inodes is calculated as a function of the file system size, with 1/4 of the available blocks used for inodes. This default can be overridden with the ninode=num option. For Version 2 or 4 disk layouts, inode allocation is done dynamically. There is a minimum number of inodes allocated to the file system by mkfs, and any other inode allocations are done on an as-needed basis during file system use.
Some applications that pre-date System V Release 4 do not work on file systems with more than 64K inodes. For the Version 1 layout, when the number of inodes for the file system to be built exceeds the 64K limit, mkfs prompts the user for confirmation that the file system should be built with the large number of inodes and offers the option of truncating the number to 64K. The -o C and -o L options suppress this prompting. For the Version 2 and 4 layouts there is no prompting since the number of inodes is determined through use. However, Version 2 and 4 file systems can be made to limit the number of inodes that can be allocated, using the -o C option or the ninode=num option, so that older applications will work correctly.
NOTE: If a Version 1 file system is expanded with
fsadm_vxfs(ADM)
the number of inodes may be increased. This
could cause the file system to exceed the 65,536 inode limit required
for pre-SVR4 compatibility. If the file system needs to be pre-SVR4
compatible, care should be taken to ensure that the inode limit is not
exceeded while the file system is being expanded.
No boot program is initialized by mkfs.
Options
- generic_options
- Supported by the generic mkfs command
(see
mkfs(ADM)).
- specific_options
- Supported by mkfs_vxfs.
- -F vxfs
- Specify the vxfs file system type.
- -o
- Specify the vxfs file system specific options in a comma-separated list. The following options are
available:
- C
- Limit the number of inodes to no more than 65,536. Ensures compatibility with UNIX
Systems prior to System V Release 4. Use of this option suppresses the
confirmation prompting when the number of inodes exceeds 65,536. Note that the
C and L options are mutually exclusive.
- L
- Do not limit the number of inodes to 65,536. Use of this option suppresses the confirmation
prompting when the number of inodes exceeds 65,536. The L option forces the
build of the file system with the given number of inodes, even if that number
exceeds 65,536. Note that the C and L options are mutually exclusive.
- N
- Do not write the file system to the special file. This option gives all the information needed
to create a file system but does not create it.
- version=n
- n is the vxfs disk layout version number. Valid values are 1, 2, and 4. The default is disk
layout Version 4.
- inosize=inosize
- inosize is the on-disk inode structure size for files on the file system. For disk layout
Versions 1 and 2, the only valid value is 256. For disk layout Version 4, the valid
values are 256 and 512. The default is 256. There is usually no reason to increase
the inode size, and not using the default value may even adversely affect file
system performance.
- bsize=bsize
- bsize is the block size for files on the file system and represents the smallest amount of disk
space that will be allocated to a file. bsize must be a power of 2 currently selected
from the range 1024 to 8192. The default is 1024, but may increase for larger file
systems.
- ninode=n
- n is the maximum number of inodes in the file system. The digit 0 and the string unlimited
both mean the number of inodes is unlimited. For disk layout Version 1, n is
rounded down and the default is the total number of blocks in allocation units
divided by 4. For disk layout Versions 2 and 4, the default is unlimited.
- nau=n
- n is the number of allocation units on the file system. This option is ignored for the Version
4 disk layout. For disk layout Versions 1 and 2, if nau is specified, then ausize is
determined by evenly dividing the sectors among the allocation units. By default,
the number of allocation units will be set based on the value of ausize.
- ausize=n
- n is the size, in blocks of size bsize, of an allocation unit. This option is ignored for the
Version 4 disk layout, which fixes the allocation unit size at 32768. For disk layout
Versions 1 and 2, this is an alternate way of specifying the number of allocations
units. This option may not be used in conjunction with the nau option. With this
option, the last allocation unit on the file system may be shorter than the others. If
the last allocation unit on the file system is not long enough to contain an entire
allocation unit header, the size of the resulting file system will be shortened to the
end of the last complete allocation unit.
- aufirst=n
- n is the starting block number, in blocks of size bsize, of the first allocation unit. This
option allows the allocation units to be aligned to a particular boundary, such as a
cylinder boundary. This option is ignored for the Version 4 disk layout, which
always sets the starting block number to 0.
- aupad=n
- n is the size, in blocks of size bsize, of the padding to be left before the first data block in
each allocation unit. This option allows the data blocks of an allocation unit to be
aligned to a particular boundary, such as a cylinder boundary. This option is
ignored for the Version 4 disk layout.
- logsize=n
- n is the number of blocks to allocate for an activity logging area. The minimum value for
n is 32 blocks. The maximum value for n is the number of blocks that will make
the log no greater than 16384K bytes. The default logsize is usually 1024 blocks;
for a small file system the default may be smaller to avoid wasting space.
- A large log will provide better performance on metadata-intensive workloads. A small log
will use less space on the disk and leave more room for file data. For example, an
NFS-intensive workload will perform better with a large log; a small floppy
device will need a small log.
- largefiles | nolargefiles
- Valid only for the Version 4 disk layout. This option controls the
largefile compatibility flag for the file system. If
largefiles is specified, the bit is set and files 2
gigabytes or larger can be created. If nolargefiles is
specified, the bit is cleared and files created on the file system are
limited to less than 2 gigabytes. The default is
nolargefiles.
See
mkfs(ADM)
and
fsadm_vxfs(ADM).
- NOTE: Be careful when implementing large file system capability. System administration
utilities such as backup may experience problems if they are not large file aware. For more information see
``Large File Support''
in intro(S).
References
fsadm_vxfs(ADM),
fsck(ADM),
fsck_vxfs(ADM),
mkfs(ADM),
mount_vxfs(ADM),
intro(S),
open(S),
dir(F)
fs_vxfs(F)
© 1997 The Santa Cruz Operation, Inc. All rights reserved.