Caution: This version of this document is no longer maintained. For the latest documentation, see


Format a Power-Safe filesystem (QNX Neutrino)

Note: You must be logged in as root to run this utility.


mkqnx6fs [-Bq] [-b blocksize] [-e endian] [-g groups]
         [-i inodes] [-n blocks] [-r percent] [-T type]
         [-u uuid] host

Runs on:



Rewrite only the boot loader; don't touch anything in the filesystem (in particular don't reformat it). You would use this to upgrade to new boot loader code.
-b blocksize
Set the logical blocksize of the filesystem. Valid values are 512, 1024, 2048, or 4096; the default is 1024. Varying the blocksize can control various types of fragmentation as well as determine the maximum file size supported.
-e endian
Set the endian layout of the on-disk filesystem. Valid values are big or little; by default the filesystem uses the native endian-ness of the CPU.
-g groups
Set the number of allocation groups to subdivide the filesystem; by default a value (from 1 to 16) is selected based on filesystem size. An allocation group is a logical concept, not a physical segregation.
-i inodes
Set the maximum number of inodes in the filesystem. Each unique file or directory requires an inode.
-n blocks
Set the number of logical blocks in the filesystem. This is the total size of the filesystem, from which space is first allocated to the system bitmap and inodes files (so the number of user-accessible blocks will be slightly less than the specified value).

By default, mkqnx6fs makes the filesystem fully occupy the specified host (e.g. it determines the number of blocks from the size of the disk partition).

Operate quietly; don't prompt for confirmation and don't display the resulting configuration of the new filesystem. Without this option, mkqnx6fs will confirm that you meant to format if the host is a block-special device or is currently mounted.
-r percent
Set the percentage of the filesystem to reserve to prevent it from becoming completely full. In general, filesystem performace degrades when the disk is nearly full; this option just makes ENOSPC happen prematurely to stop this. The default is 3%.
-T type
Set the expected usage type of the filesystem; valid values are desktop, runtime, and media. This type is used to pick the appropriate blocksize, number of allocation groups, and number of inodes. It's a hint that's intended to replace explicit -b, -g, and -i values.
-u uuid
Specify a 128-bit UUID for the filesystem, in the UUID "8-4-4-4-12" format. If you don't specify a UUID, mkqnx6fs generates a random, time-based (version 4 UUID) value.
The host of the new filesystem. You can specify this as a block-special device or partition (e.g. /dev/hd0t76), as a regular file, or as the root directory of a mounted fs-qnx6 filesystem (which will be resolved to the real host device).


The mkqnx6fs utility creates a fresh fs-qnx6 filesystem on the specified host (typically a hard disk partition, although you can create an image inside a regular file).

The integer fields of the filesystem are maintained as either all little-endian or all big-endian, as dictated by the -e option. Thus no CPU architecture pays a byte-swapping penalty for local disks. The filesystem detects the endian-ness and swaps if necessary, so you can move a disk across platforms (with a slight penalty in performance).


# mkqnx6fs /dev/hd0t76
All files on /dev/hd0t76 will be lost!
Confirm filesystem re-format (y) or (n): y
Format fs-qnx6: 8040524 blocks, 62816 inodes, 8 groups

Exit status:

The filesystem was formatted successfully.
An error occurred (a descriptive message is written to stderr).

See also:

chkqnx6fs, devb-*,

"Power-Safe filesystem" in the Filesystems chapter of the System Architecture guide

"Power-Safe filesystem" in the Filesystems chapter of the Neutrino User's Guide