UNIX filesystem concepts


The top-level view

Simple file naming:

Name components can contain any character except '/' (because it's the directory separator) or '\0' (C end-of-string marker), so you might see embedded whitespace, control characters, etc.

Originally UNIX used a simple record-oriented format for directories with 14 bytes for a file/directory name and two bytes for the associated inode number. BSD's FFS later introduced a variable-name-length format with up to 254 characters in the file name; inode numbers have since also increased in size (to at least 32 bits).

By contrast, file naming in the VMS operating system is very complicated:

NODENAME::DEV:[DIR1.DIR2.DIR3]FILENAME.EXTENSION;1

Next ->


Steve VanDevender
Last modified: Fri May 4 12:11:33 PDT 2007