Filename rules

QNX Neutrino supports a variety of filesystems, each of which has different capabilities and rules for valid filenames.

For information about filesystem capabilities, see the Working with Filesystems chapter; for filesystem limits, see the Understanding System Limits chapter.

The maximum length of a filename depends on the type of filesystem. Individual bytes within the filename may have any value except the following (all values are in hexadecimal):

If you're using UTF-8 representations of Unicode characters to represent international characters, the limit on the filename length will be lower, depending on your use of characters in the extended range.

In the Power-Safe filesystem, you can use international characters in filenames by using the UTF-8 encoding of Unicode characters. Filenames containing UTF-8 characters are generally illegible when viewed from the command line.

You can also use the ISO-Latin1 supplemental and PC character sets for international characters; however, the appearance of these 8-bit characters depends on the display settings of your terminal, and might not appear as you expect in other operating systems that access the files via a network.

Most other operating systems, including Microsoft Windows, support UTF-8/Unicode characters. Filenames from older versions of Microsoft Windows may be encoded using 8-bit characters with various language codepage in effect. The DOS filesystem in QNX Neutrino can translate these filenames to UTF-8 representations, but you need to tell the filesystem which codepage to use via a command-line option. For more information see fs-dos.so in the Utilities Reference.

Note: All our disk filesystems—i.e., fs-dos.so, fs-ext2.so, the Power-safe filesystem (fs-qnx6.so), and fs-udf.so—use UTF-8 encoding for presentation of their filenames; attempts to specify a filename not using UTF-8 encoding will fail (with an error of EILSEQ) on these filesystems.