Last edited 5 months ago

File Hierarchy Standard (FHS)

Applicable for STM32MP13x lines, STM32MP15x lines, STM32MP25x lines

This article lists and describes the OpenSTLinux file-system hierarchy (Weston and core).

1. Introduction[edit | edit source]

Linux® is a file-oriented operating system. This means that any application, library, or other information related, for example, to configurations and running applications is stored in files only.

The Filesystem Hierarchy Standard (FHS) defines the directory structure and directory contents in Linux distributions.
It is maintained by the Linux Foundation. The latest version is 3.0, released on June 3rd 2015[1]

The main parts described by the FHS are:

  • the physical filesystem: any mass storage devices (NAND/eMMC/... partitions, USB key partitions, and so on)
  • pseudo filesystem: created dynamically at boot-up (and/or at runtime) to store various information and configurations related to the software being run
  • remote filesystem: rootfs can contain links to a network filesystem

OpenSTLinux images respect the latest FHS definition: 3.0

2. Root filesystem content[edit | edit source]

  • The filesystem root of any Linux Distribution (OpenSTLinux included) is named '/' or 'root' (do not confuse with the 'root' super user name).

There are no files in the root path, only directories that shape the Linux FHS, as listed below:

bin/ Essential command binaries
boot/ Static boot loader files
dev/ Device files (temporary filessytem devtmpfs)
etc/ Host-specific system configuration
lib/ Essential shared libraries and kernel modules
media/ Mount point for removable media
mnt/ Mount point for temporarily mounting a filesystem
proc/ Kernel and process information (pseudo filesystem procfs)
opt/ Add-on application software packages
run/ Data relevant to running processes
sbin/ Essential system binaries
sys/ Kernel and system information (pseudo filesystem sysfs))
srv/ Data for system-provided services
tmp/ Temporary files
usr/ Secondary filesystem-hierarchy
var/ Variable data
  • As a standard Linux distribution, the OpenSTLinux distribution includes the optional user directories:
/home User home directories (optional)
/root Home directory for the root user (optional)

Details of the directory purpose, content or sub-hierarchy can be found in the official documentation: FHS-3.0

  • OpenSTLinux also integrates a vendorfs filesystem, mounted on a dedicated Flash-memory partition (that is, /dev/mmcblk0p5):
/vendor Vendor dedicated directory

This directory allows the storage of specific vendor libraries.

3. References[edit | edit source]