Format a read-only compressed filesystem (QNX Neutrino)

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


mkrcfs [options]... [directory] file

Runs on:

QNX Neutrino, Linux


-b 0..4
Specify the blocksize:
Value Blocksize
0 4 KB
1 8 KB
2 16 KB (the default)
3 32 KB
4 64 KB
-c 1..9
The compression factor; the higher the factor, the slower the compression. The default is 9.
-D type
Dump filesystem structures (s for superblock, i for inodes).
-L str
A plain-text string (up to 32 bytes) to record in the superblock.
("el") List the contents of file only. The directory isn't touched.
-p patch_file
Apply patching instructions from this file (see "Patch files," below).
-t none | lzo | ucl
The compression type to use:
Type Compression Decompression Amount
lzo Fast Very fast 30–50% on executables
ucl Slow Fast 40–65% on executables
Be verbose. You can specify up to -vvv to increase verbosity.
Extract from file and create directory.
Make a compressed filesystem of all files in this directory.
The output file representing the read-only compressed filesystem.


The mkrcfs utility creates a fresh read-only compressed filesystem (RCFS) on the specified host (typically a hard disk partition, although you can create an image inside a regular file).

Patch files

Patch files let you override the user ID, group ID, and permissions of certain files, depending on their location and filename pattern. Patches are applied after all files have been collected from the specified directory. Consequently, patch files can override the files' original settings.

Patch files must contain only lines of the form:




In comment lines, # must be the very first character. The entire line is regarded as a comment and is ignored.

The type is either d or f, optionally followed by r. Type d patches are applied only to directories, and type f patches are applied only to files. An r indicates that the patch should be applied recursively within path; without r, the patch is applied to path only.

The pattern is a filename pattern that specifies which files to apply the patch to. The uid and gid must be decimal numbers, while perms must be an octal number (see chmod). Note that it isn't possible to set only the user ID, group ID, or permissions; for each match, all three are affected.

Summary of filesystem commands

The following table shows the shared objects and related commands for the filesystems:

Partition type Filesystem Shared object Initialize with: Check with:
1, 4, or 6 DOS mkdosfs chkdosfs
7 Windows NTa N/A N/A
11, 12, or 14 FAT32 mkdosfs chkdosfs
77, 78, or 79 QNX 4 dinit chkfsys
131 Linux (Ext2) N/A N/A
175 Apple Macintosh HFS or HFS Plusa N/A N/A
177, 178, or 179 Power-Safe mkqnx6fs chkqnx6fsb
  Read-only compressed (RCFS) mkrcfs N/A

a Read-only.

b Not usually necessary.

For more information, see the Filesystems chapter of the System Architecture guide.

Exit status:

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