postmarketOS
postmarketOS is a free and open-source Linux distribution based on the lightweight Alpine Linux operating system, specifically designed to run on smartphones, tablets, and other mobile devices with the goal of extending the usable lifespan of consumer electronics by providing users with full control over their hardware.[1] It emphasizes sustainability, privacy, and the avoidance of vendor lock-in, enabling devices to receive long-term maintenance and updates far beyond typical manufacturer support periods.[2] The project was initiated to bridge the gap in the Linux mobile ecosystem, targeting initially Linux enthusiasts, hackers, and tinkerers who seek a complete, modifiable operating system experience on mobile hardware.[3] postmarketOS uses the mainline Linux kernel and supports a variety of touch-optimized user interfaces, such as Phosh, Plasma Mobile, Sxmo, GNOME, and KDE, allowing users to choose based on their preferences for aesthetics and functionality.[1] Its base system is minimal, leveraging Alpine's security-focused design with musl libc and BusyBox for a small footprint—typically around 5 MB for the core installation—while prioritizing free software and full disk encryption.[2] Currently, postmarketOS supports over 700 devices, primarily those with aarch64 architectures like Qualcomm Snapdragon models (e.g., SDM845 and MSM8916), though compatibility varies and requires technical expertise for installation and troubleshooting.[2] The latest stable release is version v25.06, with ongoing development occurring in the edge branch, but it remains in an alpha stage for most users, lacking the polished usability of proprietary systems like Android or iOS.[1] As a community-driven effort with no paid support, it relies on volunteer contributions and encourages participation through its GitLab repositories and Matrix/IRC channels to advance hardware support and stability.[3]History
Founding and Early Development
postmarketOS was founded by developer Oliver Smith and publicly launched on May 26, 2017, as a touch-optimized and pre-configured variant of Alpine Linux specifically tailored for smartphones and other mobile devices.[4][5] The project emerged from Smith's efforts, which began in 2016, to create an open-source operating system that could replace proprietary mobile OSes like Android on aging hardware.[5] The core motivations behind postmarketOS centered on extending the usable lifespan of smartphones to at least 10 years through sustainable, open-source software development, thereby countering planned obsolescence and vendor lock-in imposed by manufacturers.[4][6] By prioritizing long-term support and full user control over devices, the initiative aimed to promote environmental sustainability and empower users to repurpose electronics rather than discard them prematurely.[1][6] From its inception, postmarketOS targeted Linux enthusiasts interested in running a native Linux environment on mobile hardware, with early development emphasizing ports to select devices using minimal device-specific code to facilitate broad compatibility.[7] Initial ports included the Nokia N900 on June 8, 2017—the project's first non-Android device—and various Samsung Galaxy series models, such as the Galaxy S Advance, achieved shortly thereafter, demonstrating viability on diverse hardware with shared kernel configurations.[7] The choice of Alpine Linux as the base system was driven by its lightweight design, which incorporates musl libc for efficient resource usage and BusyBox utilities for a compact footprint, ensuring ease of maintenance and suitability for constrained mobile environments.[4] This foundation allowed postmarketOS to focus on sustainability without the bloat of larger distributions, while an emphasis on mainline Linux kernels minimized proprietary dependencies.[7]Major Releases and Milestones
In the early 2020s, postmarketOS achieved a key milestone with the integration of Wayland support, enabling modern, efficient display protocols for mobile user interfaces such as Plasma Mobile and Phosh, which replaced older X11-based rendering for better performance on resource-constrained devices.[8] This paved the way for smoother graphics handling and reduced latency in touch interactions, marking a shift toward upstream-compatible display stacks. By 2025, the project further organized its ports by separating downstream kernel-based devices into a dedicated category, allowing clearer distinction from mainline efforts and facilitating maintenance for legacy hardware that relies on vendor-specific modifications.[9] This restructuring, implemented in June 2025, helped streamline development by isolating non-upstream ports while prioritizing mainline kernel advancements.[10] A significant major release came with version 25.06 on June 22, 2025, which introduced systemd as the default init system, replacing OpenRC to enhance service management, boot reliability, and compatibility with broader Linux ecosystems for enthusiasts seeking stable mobile environments.[10] The release also incorporated automated testing enhancements through expanded continuous integration pipelines, reducing breakage in device ports and improving overall stability across supported hardware.[10] Updates to user interfaces, including GNOME 48, KDE Plasma Mobile 6.3.5, and Phosh 0.47.0, further bolstered usability, with features like improved task switchers and volume controls tailored for touch-based navigation.[11] Community engagement reached a highlight at FOSDEM 2025 in February, where postmarketOS developers presented talks on project progress and participated in a subsequent hackathon, yielding practical solutions for running mainline Linux kernels on diverse hardware like Qualcomm and MediaTek chipsets.[12] These events fostered collaborations that accelerated upstreaming of patches, such as those for systemd integration and sensor drivers, contributing to long-term device longevity.[13] As of November 2025, postmarketOS supports 703 devices with 1,420 in progress, reflecting sustained community efforts in porting and testing across smartphones and tablets from an initial handful of ports in its early days.[14] This growth underscored a strategic focus on upstreaming patches to Linux kernels and Alpine Linux components, ensuring patches for hardware enablement—such as display and audio drivers—are submitted for inclusion in official repositories to promote broader adoption and reduce maintenance burdens.[15] Continued development in late 2025 included enhancements like Sxmo 1.18.0 and new device ports, maintaining momentum in hardware support.[16]Architecture
Base System Components
postmarketOS relies on Alpine Linux as its core distribution, which provides a minimal and secure foundation optimized for resource-constrained environments like mobile devices.[2] Alpine's APK package manager enables efficient handling of dependencies and updates, ensuring a lightweight installation footprint without unnecessary bloat. This choice aligns with postmarketOS's goal of longevity, as Alpine's design emphasizes stability and security through regular security audits and a small attack surface.[2] At the userland level, postmarketOS employs musl libc as its C library implementation, which offers a compact and standards-compliant alternative to glibc, reducing memory usage and binary sizes critical for embedded systems.[2] Complementing this is BusyBox, a multi-tool utility suite that consolidates common Unix commands into a single executable, further minimizing storage and runtime requirements while maintaining full POSIX compatibility.[2] Together, these components ensure the base system remains efficient, with the base installation occupying about 5 MB before adding interfaces or applications.[17] The pmbootstrap tool serves as the primary utility for constructing and managing the base system, facilitating cross-compilation of packages for target architectures directly from a host machine.[18] It handles chroot environments to isolate builds, preventing contamination from the host system, and allows creation of custom images tailored to specific devices without necessitating a complete development setup on the target hardware.[18] This streamlines the process for developers, enabling reproducible builds and rapid iteration on the core stack.[19] Modularity is a core principle of postmarketOS's architecture, achieved through meta-packages that permit selective inclusion of features without altering the base system.[20] For instance, thepostmarketos-base meta-package pulls in essential components, while others like those for full disk encryption integrate LUKS (Linux Unified Key Setup) to optionally secure the root filesystem in supported configurations, protecting data at rest.[21] Privacy is inherently prioritized, with no built-in telemetry, advertising, or tracking mechanisms; user agents remain generic to avoid fingerprinting, and all components adhere to open-source principles without proprietary dependencies.[2] This approach allows users to extend the system incrementally, such as adding encryption or network tools, via simple package installations.[20] Since the v25.06 release in June 2025, postmarketOS also supports the systemd init system alongside OpenRC.[10]
Kernel and Drivers
postmarketOS prioritizes the use of mainline Linux kernels from kernel.org to ensure long-term hardware support and security updates, replacing vendor-provided downstream kernels where possible.[22] This approach involves porting device trees and submitting minimal patches upstream to minimize maintenance efforts and align with standard Linux development.[23] For instance, devices based on the Qualcomm MSM89x7 SoC utilize Linux kernel 6.13 as of early 2025, which includes upstreamed support for audio and charging functionalities.[24] The distribution supports ARM architectures including armhf, armv7, and aarch64, enabling generic kernel builds that provide broad compatibility across various system-on-chips (SoCs) such as Qualcomm Snapdragon and Samsung Exynos processors.[22] These builds leverage standard defconfigs like qcom_defconfig for Snapdragon devices, allowing initial booting with core hardware abstraction before full feature enablement.[23] By focusing on mainline integration, postmarketOS achieves sustainability, with kernels updated regularly to incorporate upstream improvements in areas like power management via PSCI firmware interfaces.[23] Driver management in postmarketOS emphasizes upstreaming for longevity, avoiding reliance on proprietary or poorly maintained downstream drivers from vendors.[22] Community ports may temporarily use downstream kernels, but the strategy shifts toward mainline equivalents to support essential peripherals, including input devices via CONFIG_INPUT_EVDEV and virtual terminals with CONFIG_VT.[25] Configurations for power management, charging regulators, and basic peripherals are defined in device tree sources (DTS) files, which are iteratively upstreamed to enable features like battery monitoring without vendor blobs.[23] This upstream focus reduces failure points and ensures compatibility with evolving Linux standards.[25] Kernel packaging is handled through postmarketOS-specific tools like pmbootstrap and the envkernel.sh script, which facilitate building and deployment while allowing per-device tweaks such as custom patches and defconfigs.[26] These tools maintain a shared kernel base across devices, supporting updates for over a decade by integrating upstream changes and device-specific adjustments in a modular manner.[26] For example, post-make scripts can process device trees into bootable DTB files, ensuring the kernel remains adaptable without fragmenting the core package.[26]User Interfaces
Supported Environments
postmarketOS provides a diverse array of graphical and non-graphical user interfaces, optimized for the unique input methods and form factors of mobile devices such as smartphones and tablets. These environments cater to varying user needs, from touch-centric mobile experiences to keyboard-driven minimalism, and are built atop the distribution's Alpine Linux base. The selection emphasizes modularity, enabling users to choose interfaces that align with their hardware capabilities and workflow preferences.[27][1] Among the mobile-optimized user interfaces, Phosh stands out as a GNOME-based shell specifically designed for touch interaction on handheld devices. Developed by Purism, it features a phone-friendly layout with gesture navigation, app overviews, and quick settings panels, leveraging Wayland for efficient rendering and input handling on modern mobile hardware.[28] Plasma Mobile, the KDE Plasma adaptation for mobiles, focuses on convergence, allowing users to scale interfaces from phone to desktop modes while supporting touch gestures and hardware buttons; it also runs on Wayland, promoting smooth transitions across usage scenarios.[29] For a more minimalist approach, Sxmo employs a tiling window manager with a scriptable, lightweight design tailored for advanced users, emphasizing efficiency on devices with limited resources and supporting touch alongside hardware navigation for a distraction-free experience. Traditional desktop environments are also supported, offering familiarity for users accustomed to PC Linux setups while being adaptable to mobile touchscreens through Wayland or X11 backends. GNOME provides a polished, extension-rich desktop that can incorporate mobile extensions for better touch support.[27] MATE, a continuation of the GNOME 2 series, delivers a lightweight, customizable interface primarily via X11, suitable for older devices with moderate touchscreen adaptations.[27] XFCE offers a fast, low-resource desktop environment on X11, often used as a stable option for initial ports and enhanced with touch-friendly panels.[27] Other options include Sway, a Wayland-based tiling window manager, and COSMIC, System76's modern desktop environment, both actively supported as of 2025. Unity8 (now evolved into Lomiri) serves as a convergent shell bridging mobile and desktop paradigms, with touch-optimized scopes and multitasking features that work across Wayland and Mir display servers.[30] For non-graphical operation, postmarketOS includes console mode for pure command-line access, ideal for development, debugging, or low-power scenarios on any supported device.[27] Additionally, i3wm, a keyboard-centric tiling window manager, is available for text-heavy workflows, particularly on hardware like the Nokia N900, where its shortcut-based navigation leverages the device's physical keyboard without relying on touch input.[31] The distribution's meta-package system simplifies interface management, with dedicated packages such aspostmarketos-ui-phosh for Phosh or postmarketos-ui-plasma-mobile for Plasma Mobile installed via the apk tool.[27] This allows multiple interfaces to coexist on a single device, enabling seamless switching at boot time through configuration files, without necessitating a full system rebuild or kernel changes.[27]
Customization and Configuration
postmarketOS allows users to switch user interfaces during the initial build process using the pmbootstrap tool, where thepmbootstrap init command prompts for selection of a meta-package such as postmarketos-ui-phosh or postmarketos-ui-plasma-mobile.[27] After installation, additional interfaces can be installed via the Alpine Package Keeper (apk) with commands like sudo apk add postmarketos-ui-<UI-name>, enabling multiple UIs to coexist on the system.[27] To switch between them, users configure the display manager, such as tinydm, by running [sudo](/page/Sudo) tinydm-set-session -f -s /usr/share/wayland-sessions/<UI>.desktop for Wayland-based environments, allowing selection at login via a greeter interface.[32]
Customization of themes and input methods adapts postmarketOS to diverse hardware and user preferences, with support for on-screen keyboards like Matchbox-keyboard for X11 sessions and gesture-based input in touch-optimized UIs.[33] Keyboard layouts can be adjusted in environments like Sxmo, which offers options such as Full, Emoji, or language-specific variants via configuration flags like -l for layout selection, while Phosh enables shortcut customization through Settings > Keyboard.[34][28] In Plasma Mobile, convergence modes facilitate transitions between phone and desktop layouts, supporting touch gestures for navigation and external input devices without proprietary dependencies.[27]
Advanced tweaks involve editing device-specific configuration files to fine-tune behaviors, such as screen rotation, which is configured by editing /etc/X11/xorg.conf.d/00-fbdev-rotate.conf and setting Option "Rotate" "CW" (for clockwise), "CCW" (for counterclockwise), or "UD" (for upside-down) in the Device section, followed by a reboot.[35] Power profiles are managed through system services like power-profiles-daemon, configurable via /etc/power-profiles-daemon/config to balance performance and battery life on mobile hardware.[36] Users can add extensions, such as GNOME Shell extensions in Phosh or KDE Plasma widgets, directly through package management or UI settings, ensuring compatibility without reliance on vendor-specific tools.[28]
Privacy customizations align with postmarketOS's ad-free, open-source ethos, allowing users to enable optional services like Tor by installing sudo apk add tor and editing /etc/tor/torrc for anonymous networking.[37] Notifications can be disabled globally or per-app through UI-specific settings, such as in Phosh via GNOME's notification controls, preventing intrusive alerts while maintaining system responsiveness.[28] This approach supports a no-ads philosophy by avoiding proprietary services and emphasizing user-controlled data flows.[37]
Installation and Porting
Installation Methods
postmarketOS installation primarily relies on the pmbootstrap tool, which facilitates the creation of device-specific images through cross-compilation, package management, and direct flashing capabilities. This Alpine Linux-based utility allows users to generate bootable images tailored to supported hardware, handling dependencies like kernels, interfaces, and firmware automatically.[38] Before proceeding, users must meet several prerequisites to ensure a safe and successful installation. Device bootloaders often require unlocking, a process that varies by manufacturer—such as enabling OEM unlocking in developer options for Android devices—and may void warranties or risk data loss. It is strongly recommended to create full backups of existing data, as the installation process can overwrite the device's storage. Additionally, familiarity with Linux terminal commands is essential, and tools like fastboot for Qualcomm devices or heimdall for Samsung hardware must be available, depending on the target device's supported flashing method.[38] Installation methods cater to different user needs, from straightforward pre-built images to highly customized setups. For supported devices, users can download stable channel images from the v25.06 release or later, which include a complete root filesystem ready for flashing via USB in fastboot mode or through device-specific recovery partitions. Alternatively, a minimal rootfs option enables quick testing by bootstrapping a basic system without a full user interface, allowing subsequent additions like desktop environments via package installation. Custom builds offer the most flexibility: during pmbootstrap initialization (initiated with the commandpmbootstrap init), users select from available user interfaces such as Plasma Mobile or Phosh, alongside kernel variants optimized for the device, generating a personalized image for flashing. Other approaches include the web-based flasher at flash.postmarketos.org for compatible devices using a Chromium browser, or installation from recovery mode via Android-compatible .zip files, though these are limited to specific hardware. For a subset of devices, the UBports Installer tool supports postmarketOS selection, streamlining the process through a graphical interface.[38][39][40][41]
Following installation, initial boot involves configuring essential settings to access the system. Users typically connect via SSH or a serial console for the first login, setting up a password and enabling features like full-disk encryption during the setup wizard if desired. To maintain reliability akin to over-the-air updates, selecting an update channel—stable for production use or edge for bleeding-edge features—is configured post-install via pmbootstrap or device configuration tools, ensuring seamless package updates over time.[38][42]
Porting Process
Porting postmarketOS to a new device involves adapting the Alpine Linux-based distribution to unsupported hardware, with a strong emphasis on integrating with the mainline Linux kernel to ensure long-term sustainability. The process begins with identifying the device's system-on-chip (SoC) and board details, such as the chipset model and vendor codename, which can be found through resources like device specifications or existing Android kernel sources.[23] If the SoC is supported in mainline Linux (e.g., Qualcomm MSM series or MediaTek variants), developers proceed to create or modify Device Tree Source (DTS) files to describe the hardware configuration.[43] This includes copying an existing DTS file from the kernel source tree (e.g., underarch/arm64/boot/dts/), renaming it to match the device (e.g., qcom-vendor-codename.dts), and updating properties like model and compatible strings to reflect the board specifics.[23] Patches for these changes are then upstreamed to the Linux kernel mailing lists using tools like b4 for preparation and submission, prioritizing minimal custom code to avoid vendor-specific hacks and promote upstream acceptance.[23]
Device ports are categorized based on kernel integration and maintenance level, with "Main" and "Community" requiring close-to-mainline kernels for stability, while "Downstream" allows vendor kernels for faster initial ports. "Main" ports demand maintenance by at least two developers and full functionality like calls, audio, and UI, using kernels aligned closely with upstream Linux.[44] "Community" ports, maintained by at least one person, also mandate close-to-mainline kernels that pass configuration checks (e.g., pmbootstrap kconfig check --community), support automatic upgrades across at least three releases, and remain no older than six months.[44] In contrast, "Downstream" ports permit proprietary or vendor-modified kernels to enable quick booting on devices lacking mainline support, though they are encouraged to migrate to mainline categories over time.[44] As of June 2025, postmarketOS has 703 supported devices and 1,417 devices in progress across these categories.[14]
The porting workflow relies on pmbootstrap, a tool for building and managing postmarketOS environments in chroots, requiring about 10 GB of disk space on a Linux host. Developers start with pmbootstrap init to generate initial device-specific packages (e.g., device-vendor-codename) and kernel packages (e.g., linux-vendor-codename), prompting for vendor and codename inputs while configuring options like the kernel variant.[45] Testing occurs iteratively, often using QEMU for emulated environments to verify builds without hardware (e.g., for QEMU-aarch64 targets), and on-device via flashing boot images derived from Android ROMs or recovery tools like TWRP.[46] Once functional, ports are submitted as merge requests to the pmaports GitLab repository under appropriate directories (e.g., device/community/ or device/downstream/), facilitating community review and integration.[45]
Hardware adaptation focuses on basic booting prerequisites, starting with unlocking the bootloader to allow custom images, as detailed in device-specific guides.[47] Essential components include a compatible bootloader (e.g., adapting U-Boot if needed) and initial display output, achieved through kernel configurations or patches for framebuffers and DRM drivers.[48] Developers are strongly encouraged to upstream all hardware enablement work to the Linux kernel and related projects, minimizing postmarketOS-specific code to foster broader ecosystem sustainability and reduce maintenance burdens.[23]