Once the Linux kernel has booted from the boot partition and the init process is running from the ramdisk, the next immediate step is to mount the massive partitions that contain the actual operating system.
Historically, Android was a monolithic mess where all code was dumped into a single partition. Today, the OS is strictly compartmentalized across four primary read-only partitions.
1. system (The Android Framework)
This is the largest and most critical partition. It contains the pure, generic Android operating system exactly as provided by Google.
- Contents: The Java framework APIs, core native services (SurfaceFlinger, logd), and standard system apps (Settings, standard Launcher).
- Maintenance: Only Google (or the ROM developer) touches the code in this partition.
2. vendor (The Silicon Drivers)
Introduced by Project Treble, the vendor partition strictly isolates the proprietary hardware drivers provided by the silicon manufacturer (e.g., Qualcomm, Samsung Exynos).
- Contents: Hardware Abstraction Layers (HALs), proprietary
.solibraries for the camera Image Signal Processor, and closed-source audio mixers. - Rule: The
systempartition cannot access thevendorpartition directly; they must communicate strictly via IPC (Binder/AIDL).
3. product (OEM Customizations)
A device manufacturer (OEM) like Samsung or Motorola usually wants to add their own custom apps, themes, and bloatware without modifying Google's generic system partition.
- Contents: OEM-specific applications, custom ringtones, wallpapers, and specific framework overlay files.
- Why it exists: By isolating customizations here, the OEM can accept a Generic System Image (GSI) update from Google for the
systempartition without losing their proprietary, custom branded applications.
4. odm (Original Design Manufacturer)
Sometimes, a single OEM will design one phone but source the motherboard from different Original Design Manufacturers (ODMs) depending on the regional market.
- Contents: Highly specific board-level configurations and hardware overlays that differ even between variants of the exact same phone model.
- Relationship: If the
vendorpartition is for the SoC (the brain), theodmpartition is for the specific physical motherboard layout.
The fstab (File System Table)
The init process knows how and where to mount these partitions because it reads the fstab file (usually located in the vendor ramdisk). The fstab tells the kernel: "Take the physical block device at /dev/block/sda5, format it as EXT4 or EROFS, and mount it to the /system folder."
# Example snippet of an Android fstab file
# <src> <mnt_point> <type> <mnt_flags and options>
/dev/block/bootdevice/by-name/system /system erofs ro,barrier=1
/dev/block/bootdevice/by-name/vendor /vendor erofs ro,barrier=1