Pseudo filesystem table
Pseudo filesystem table, or pseudo fstab, is a virtual fstab file that acts as a mapper table to map necessary files and partitions to /dev/block/by-name by identifier.
The file is named fstab.android and located in root filesystem (where you installed/deployed BlissOS), automatically created by BlissOS on installation or initial boot.
This guide is for editing/modifying the pseudo fstab file.
Example:
# fstab.android
--------------------------------------------------------------------------------------------------------
# <src> <mnt_point> <type> <mnt_flags and options> <fs_mgr_flags>
# Read-only standard mappings
$FS/system$SLOT.img system$SLOT
$FS/kernel$SLOT kernel$SLOT
$FS/initrd$SLOT.img initrd$SLOT
$FS/recovery$SLOT.img recovery$SLOT
# Read-write disk images/bindings
$FS/boot bootloader
$FS/misc.img misc
$FS/data.img userdata ext4 defaults defaults
# Hardware partitions
# /dev/sda1 (for example)
UUID=1581-FD48 esp vfat defaults defaults
# Virtual filesystems
none /sys/firmware/efi/efivars efivarfs defaults defaults
Danger
Please check your editor is editing fstab.android with LF EOL sequence instead of CRLF. If you accidentally use CRLF your fstab will not be able to work with our initrd.
EOL sequence can usually be seen on the bottom bar of the editor, for example on Visual Studio Code:
Syntax
The pseudo fstab file itself is an actual Linux/Android fstab file, with some additional modifications in syntax for extra support for file mapping and directory binding.
The file is a text file represents a table, with the following columns:
| Column | Description | Condition | Required for file mapping and directory binding |
|---|---|---|---|
<src> |
Source file/directory/partition | Must be absolute path | Yes |
<mnt_point> |
Target or mount point | Must be absolute path | Yes |
<type> |
Filesystem type | Linux supported filesystems only | Case-dependent |
<mnt_flags and options> |
Mount flags and options | Similar to using mount -o |
Case-dependent |
<fs_mgr_flags> |
Android filesystem manager flags | vold-specific flags | Case-dependent |
Warning
"Case-dependent" fields are required only if the file being mapped is a R/W mountable disk image file (.img) or a partition. For partition mounting, all fields are required.
Info
Linking a partition to a specific path also count as a file mapping.
Special mount targets
We've defined some special mount targets (<mnt_point>) for file mapping and directory binding, representing standard Android block devices:
| Identifier | Mapping target absolute path |
|---|---|
| system_a | /dev/block/by-name/system_a |
| system_b | /dev/block/by-name/system_b |
| vendor_a | /dev/block/by-name/vendor_a |
| vendor_b | /dev/block/by-name/vendor_b |
| kernel_a | /dev/block/by-name/kernel_a |
| kernel_b | /dev/block/by-name/kernel_b |
| initrd_a | /dev/block/by-name/initrd_a |
| initrd_b | /dev/block/by-name/initrd_b |
| recovery_a | /dev/block/by-name/recovery_a |
| recovery_b | /dev/block/by-name/recovery_b |
| misc | /dev/block/by-name/misc |
| bootloader | /boot |
| esp | /boot/efi |
| userdata | /dev/block/by-name/userdata (or /data if userdata is directory) |
Info
You can replace userdata with /data directly if you don't want vold to handle your data.img or userdata partition; in that situation, all column fields are required.
Variables
We provide variables to simplify the syntax and automate the mapping/binding tasks. Variables start with an $ prefix. Please refer to the following table for variable information:
| Variable | Description | Equivalent Kernel Parameter | Available Values |
|---|---|---|---|
| $SLOT | Slot suffix | androidboot.slot_suffix |
_a or _b |
| $FS | Path to directory you installed BlissOS to | SRC |
absolute folder path (relative to the root directory of the partition mountpoint) |
Info
For example: SRC is /BlissOS16 and slot suffix is _a then $FS/system$SLOT.img will become /BlissOS16/system_a.img.
