- 1 General information
- 2 Specific troubleshooting pages
- 3 Uncategorized errors
- 3.1 ERROR: unsatisfiable constraints
- 3.2 pmbootstrap is broken! But it worked yesterday!
- 3.3 musl-*/busybox-static-* fails to build with a 404 error
- 3.4 Permission denied: .../pmbootstrap/work/chroot_native/proc/1/cwd'
- 3.5 can't create /dev/null: Permission denied
- 3.6 Figuring out booting problems
- 3.7 SSH / udev / touch screen do not work
- 3.8 I can't access the framebuffer device
- 3.9 BusyBox does something different than the standard tool for the job, and this breaks building my package!
- 3.10 Errors with ecryptfs
- 3.11 Serial Console Debug Cable (early boot debugging)
- 3.12 Proprietary Blobs
- 3.13 Force reboot
- 3.14 Phone shows the telnet message, a black screen, or doesn't leave the bootloader or Samsung/Google/... splash screen
- 3.15 My device runs the Linux kernel (e.g. Android), but the vendor does not provide the source
- 3.16 I have ported postmarketOS to my device and the screen doesn't get updated
- 3.17 "if running weston from ssh, use --tty to specify a tty"
- 3.18 Weston and fbsplash -s <image> do not work
- 3.19 My screen is red!
- 3.20 Errors with grsec-based kernel on the host system
- 3.21 WARNING: No provider for dependency...
- 3.22 ERROR: busybox-1.27.0-r1.post-install: script exited with error 127
- 3.23 sh: can't create /proc/sys/fs/binfmt_misc/register: nonexistent directory
- 3.24 ERROR: /mnt/pmbootstrap-packages/x86_64/qemu-user-static-repack-2.8-r6.apk: UNTRUSTED signature
- 3.25 flasher (fastboot) is stuck in < waiting for any device >
- 3.26 Invalid sparse file format at header magi
- 3.27 Installed version newer than the version in the repositories
- 3.28 Newer version in binary package repositories than in aports folder
- 3.29 Screen output flicker and inactivity
- 3.30 Screen output messed up
- 3.31 Packaging for aarch64: ./config.guess: unable to guess system type
- 3.32 Device reboots
- 3.33 ERROR: ... BAD archive
- 3.34 My Android device does not have partition labels, how do I know where to put the boot.img file etc?
- 3.35 mkbootimg: error: argument --dt: can't open '/boot/dt.img'
- 3.36 pmbootstrap builds packages that it should download from the binary repo/that are already built
- 3.37 During initramfs generation: "modprobe: WARNING: Module drm not found in directory /lib/modules/..."
- 3.38 du: unrecognized option: summarize
- 3.39 Touch screen device present but not outputting any touch events
- 3.40 CHARGING MODE: error starting charging-sdl
- 3.41 Heimdall: Flashing fails at 7%
- Always look at the log file for a detailed error message:
- Make sure, that you have the latest version. Your bug may already be fixed.
- Please report the bugs you have found in the issues, so we can fix them.
- Syslog is enabled, and will log to shared memory once the OS has booted. It can be read with the
logreadtool in BusyBox. The syslog is currently not preserved across reboots.
Specific troubleshooting pages
- grsec (TL;DR: doesn't work)
- HID buttons
- host system issues
ERROR: unsatisfiable constraints
Moved to Troubleshooting:dependencies.
pmbootstrap is broken! But it worked yesterday!
Sorry! Revert to the last commit, that was known to work (git checkout $commit) and report an issue, if there is not already one. Consult with others in the IRC/matrix channel to find out, which commit was the last one that worked.
busybox-static-* fails to build with a 404 error
pmbootstrap aportgen musl-armhf musl-aarch64 musl-x86_64. The reason why this fails from time to time is, that we use Alpine's binary
musl lib c package for
aarch64 in the native chroot, to get the cross-compiler working. So the download URL inside the
aports/cross/musl-*/APKBUILD file must be in sync with the upstream version. This pmbootstrap command safely gets the new version, uses
apk to verify the signature of the package, generates the hash, and updates the
APKBUILD file. To make sure, that
pmbootstrap aportgen receives the latest
musl version, delete your HTTP cache right before by executing this command:
pmbootstrap zap -hc. Don't bother making a pull-request for this, as the fix is really trivial (see this commit). Just report it as issue, if it happens.
Permission denied: .../pmbootstrap/work/chroot_native/proc/1/cwd'
It looks like you have created your work folder as:
pmbootstrap is the folder with the checked out source code. That is not supported. Please run
pmbootstrap shutdown, then delete that folder, then run
pmbootstrap init again and choose another work folder (e.g.
After that it should work - if this still does not resolve it, please open up an issue in the GitHub tracker.
/dev/null: Permission denied
Make sure that your working directory is mounted correctly. This can happen when working over NFS, or when you mounted the drive your working directory is on trough the file explorer (if that's the case,
umount it, and
mount it manually). This can probably happen on every drive mounted with
nosuid or similar.
Figuring out booting problems
/etc/rc.conf to have openrc log all its steps to
/var/log/rc.log. If you managed to get the system to boot far enough to have telnet access, add the port 24 telnet listener and you can mount the root device to view said log.
SSH / udev / touch screen do not work
- Make sure, that
DEVTMPFSis enabled in your kernel config. Do not enable
I can't access the framebuffer device
cat /dev/random > /dev/fb0returns:
cat: write error: No such device
- This could be caused by a proprietary 3d driver enabled in the kernel config. Try to disable it (the actual config options may be different).
BusyBox does something different than the standard tool for the job, and this breaks building my package!
Example: unzip in BusyBox doesn't extract symlinks like the normal unzip implementation (#82).
Solution: Simply add
unzip to the makedepends in the APKBUILD, and the "real" unzip will be used (or in that case, try to get the sources in another archive format, such as
Errors with ecryptfs
When your "work" folder is inside an ecryptfs mounted folder,
/dev/random may not work inside the chroot and you may have other issues. Try to move your work folder to another location, you can use
/tmp to test if this resolves the issue. You can change the location in
pmbootstrap init. See also: #61. (This doesn't seem to be an issue with newer versions of ecryptfs anymore.)
Serial Console Debug Cable (early boot debugging)
For some devices it's possible to get early boot output using a debug cable that provides access to the UART. Unfortunately manufacturers don't use to publish the details and it is endusers who in some cases have figured it out:
- Here's one such cable for Nexus 4 and another for Nexus 5.
- This article goes a step further with Google Nexus devices.
- Sony has published information about how to access the UART port on their Xperia series
- The Replicant wiki has useful information on this as well.
On fastboot devices, you may have to enable UART debugging with
fastboot oem uart-on.
By default, all output from the initramfs get redirected to
/pmOS_init.log. If you want the output through the debug cable you need to add
PMOS_NO_OUTPUT_REDIRECT to your kernel command line.
Many devices require proprietary blobs for enabling certain peripherals (wifi/bluetooth/cellular/GPS). These repositories appear to contain blobs for a large percentage of devices out there.
On some phones, you can hold down the power button for ten seconds to force a reboot. If that does not work: On other phones, you have to hold the power button down for a full minute (or hold it together with volume down). On some phones, it might take even longer (3 minutes or so).
Phone shows the telnet message, a black screen, or doesn't leave the bootloader or Samsung/Google/... splash screen
My device runs the Linux kernel (e.g. Android), but the vendor does not provide the source
- Ask kindly via e-mail.
- If they don't provide the source, team up with gpl-violations.org. You have the legal right to get the source, because the Linux kernel is under the GPLv2!
- Another option is using prebuilt kernels
I have ported postmarketOS to my device and the screen doesn't get updated
There is a known bug where if you execute
cat /sys/class/graphics/fb0/modes > /sys/class/graphics/fb0/mode exactly one frame is drawn, and the screen isn't updated otherwise.
"if running weston from ssh, use --tty to specify a tty"
Specify a tty in weston's commandline. The correct syntax is:
Weston and fbsplash -s <image> do not work
If Weston returns an error because it could not access
/dev/tty1, even when you specify it on the command line as above, you may need to enable Virtual Terminals in the kernel config.
You can enable
pmbootstrap menuconfig and checking under Device Drivers -> Character devices -> Virtual terminal
My screen is red!
There are some buggy framebuffer drivers (e.g. in LG Nexus 5) that report incorrect data. You can override it by launching weston with:
To make it persistent, you can set it in the deviceinfo:
Errors with grsec-based kernel on the host system
WARNING: No provider for dependency...
Normal behavior. it means, that your "user" repository (the repository with all custom compiled packaged from pmOS, such as your device package and kernel) does not have the dependencies from the official Alpine Linux repositories (such as
htop, ...) when indexing it. But these dependencies are in the official repositories, so they will be found when you try to install something. Usually the package indexing is done on all repositories at once in Alpine (then you wouldn't get the error), but pmOS does it only on the "user" repository.
ERROR: busybox-1.27.0-r1.post-install: script exited with error 127
Normal behavior. We use a x86_64 version of
apk to set up the chroots. When setting up the armhf chroot, the armhf post-installation code can't be executed, and that's where the errors come from. But we run "apk fix" right afterwards - with the armhf architecture, because we have an armhf version of apk installed inside the chroot now - and this runs the installation scripts again.
sh: can't create /proc/sys/fs/binfmt_misc/register: nonexistent directory
This issue is known to happen in Alpine Virthardened. It also happened in Void Linux for one user. These commands should fix it:
sudo modprobe binfmt_misc sudo mount -t binfmt_misc none /proc/sys/fs/binfmt_misc
If it still does not work, it is probably not supported by your host Linux distribution's kernel (
CONFIG_BINFMT_MISC). Try to use another kernel.
ERROR: /mnt/pmbootstrap-packages/x86_64/qemu-user-static-repack-2.8-r6.apk: UNTRUSTED signature
You don't have your own package signing key imported, which gets generated when you compile a package for the first time. pmbootstrap should automatically import it, but when you hit
^C during that, it may go wrong.
Your generated key is in
~/.local/var/pmbootstrap/config_abuild, all imported keys are in
A quick fix is deleting all packages:
./pmbootstrap zap -p
See issue #270 for more information and don't hesitate to reopen if this didn't work for you.
flasher (fastboot) is stuck in < waiting for any device >
If that does not help, it might be necessary to set the
flash_fastboot_vendor_id in your deviceinfo (this was necessary for the Amazon Kindle Fire HDX). Try to search the web for your device name and "fastboot vendor id".
If you were previously able to use fastboot and it stopped working, sometimes
pmbootstrap shutdown to restart the chroot helps (#1633). Also try to reboot the device into fastboot again.
Invalid sparse file format at header magi
In some devices (e.g.: bullhead, titan), when flashing the system (
pmbootstrap flasher flash_rootfs), it works but fastboot complains of
Invalid sparse file format at header magi.
$ ./pmbootstrap.py flasher flash_rootfs [23:02:58] (native) install android-tools [23:02:58] (native) flash rootfs image target reported max download size of 536870912 bytes Invalid sparse file format at header magi sending sparse 'system' 1/1 (274101 KB)... OKAY [ 9.452s] writing 'system' 1/1... OKAY [ 12.584s] finished. total time: 22.036s [23:03:20] Done
It happens when your device expects a sparse system image. The workaround is as follows:
For more information, see issue #299
Installed version newer than the version in the repositories
You have a program installed in one of your chroots with a higher version, than what is available in the binary package repositories (either from upstream or the packages you have built yourself).
Example how this can happen:
- Git branch switch to one which increased the version of
- Install it in a chroot (e.g. by running
- Branch switched to
- All packages got zapped, but not the chroots
postmarketos-mkinitfsagain (this time it has a lower version count!)
Solution: Simply zap your chroot! When it gets set up again, it will use the current package version.
Newer version in binary package repositories than in aports folder
You have built a package earlier, and the branch you are currently working in has a lower version in the aports folder.
Example how this can happen:
- Git branch switch to a feature branch which increased the version of
- Switch to
- Run just about any
pmbootstrapcommand, it will print this warning:
Package 'postmarketos-mkinitfs' in your aports folder has version X, but the binary package repositories already have version Y
pmbootstrap zap -m to delete the mismatched binary packages.
Note: If that does not help it, you can manually delete that specific packages from your aports folder:
sudo rm ~/.local/var/pmbootstrap/packages/*/postmarketos-mkinitfs*.apk and run
pmbootstrap index to re-index all packages. See also: #466, #474
Screen output flicker and inactivity
If you notice a very brief flicker upon boot, but immediately disappears and screen turns black, you might have a buggy framebuffer Qualcomm MDSS MDP3 driver.
You can try patching the source code by removing the function assigned to the
mdp3_interface->off_fnc in the
See example patch: 05_fix_mdp3_ctrl_off.patch
Screen output messed up
If the output on the screen is not aligned correctly (see picture) it's probably because you have a wrong value in
You can try patching the source code by setting a different video mode (RGB/ARGB/RGBA/YCRYCB/...).
See example patch: 06_fix_mdss_fb_rgb_mode.patch
Packaging for aarch64: ./config.guess: unable to guess system type
This happens in packages built with autoconf (./configure; make; make install), when it ships an outdated config.guess file in the source code. Adjust your APKBUILD's
prepare() function like done in #698.
- If your device always reboots after the same time (e.g. 2 minutes) after booting, you probably need to feed (or disable) a watchdog. Try to search your kernel config for watchdog, and also the internet for watchdog + your phone name.
- Android: The kernel config option
CONFIG_ANDROID_LOW_MEMORY_KILLERmay cause reboots. Please check if you have disabled it. If this helps you, please let us know, so we can consider checking for this option.
- Android: it is possible to get the
dmesglog from just before the crash after the reboot if you enable some kernel options.
ERROR: ... BAD archive
pmbootstrap log shows something similar to the following:
(005853) [22:25:47] (native) % apk --no-progress add -u qemu-user-static-repack qemu-user-static-repack-binfmt WARNING: Ignoring /mnt/pmbootstrap-packages/x86_64/APKINDEX.tar.gz: No such file or directory (1/2) Installing qemu-user-static-repack (2.8-r9) ERROR: qemu-user-static-repack-2.8-r9: BAD archive (2/2) Installing qemu-user-static-repack-binfmt (2.8-r9) 1 error; 20 MiB in 36 packages (005853) [22:25:53] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...then downloading a package (in this case
qemu-user-static-repack) failed. Please delete the broken package and try it again:
$ cd ~/.local/var/pmbootstrap/ # go into your work folder, as specified in 'pmbootstrap init' $ sudo rm -v cache_apk_*/qemu-user-static-repack-* # adjust the failing package name accordingly
My Android device does not have partition labels, how do I know where to put the boot.img file etc?
- Search online for the partitions, they are probably documented somewhere.
- Try to dump all partitions. Run `file` on them, it should roughly tell you the contents. If that does not help, run binwalk.
- file output: check if it is a kernel (vmlinuz),
boot.imgfile or just "data".
- In case you have "data", don't flash anything there, we probably can't generate that format yet. Please open an issue in GitHub or ask on the channel.
- file output: check if it is a kernel (vmlinuz),
- You can also look at recovery zips from other Android ROMs, that were released for your device. Extract it and look at
META-INF/com/google/android/updater-script, search for commands starting with
run_program("/sbin/busybox", "dd", they are for flashing partitions.
- In one example, there was
run_program("/sbin/busybox", "dd", "if=/tmp/boot.blob", "of=/dev/block/mmcblk0p4");, which means that a
boot.blobfile gets flashed to
boot.blobfile is also in the recovery zip - run the
fileprogram on it (see above).
- In one example, there was
mkbootimg: error: argument --dt: can't open '/boot/dt.img'
This happens when you have
deviceinfo_bootimg_qcdt enabled (which is correct when pmbootstrap generated it that way), but your kernel does not generate the
Please adjust your kernel
APKBUILD as follows:
- extend your
build()function like this
- and your
package()function like that
See #688 for a plan to automatically generate the linux APKBUILD right.
pmbootstrap builds packages that it should download from the binary repo/that are already built
Try to disable the "timestamp based rebuilds" feature in "pmbootstrap init" as a workaround and please report this as a bug. We need the following for the bug report:
- *enable* timestamp based rebuilds
pmbootstrap -v install(let it run until it starts building the package it should not build)
pmbootstrap log(we need the log from here!)
During initramfs generation: "modprobe: WARNING: Module drm not found in directory /lib/modules/..."
This means, that a module can not be put in an initramfs. When you are not using a mainline kernel, it is likely that there are no modules configured, but the code is built directly into the kernel. This means, it is expected and can be ignored.
du: unrecognized option: summarize
If you are using Alpine Linux and you encounter this issue, you will need to install the
sudo apk add coreutils
Touch screen device present but not outputting any touch events
For some devices (at least motorola-shamu and motorola-lux), the touch screen I2C device is present but not activated at boot, and must be activated before it produces any output.
For the motorola-lux, this is done in the following way:
echo 1 > /sys/devices/soc.0/78b8000.i2c/i2c-4/4-0020/drv_irq
The path to the correct touch device depends on the device. This can be added to an initfs hook to activate the touch screen automatically at boot.
CHARGING MODE: error starting charging-sdl
When attaching the power cable while the device is off, Android devices boot into a special "charging mode". postmarketOS's charging-sdl display does not work yet on all devices.
To debug the issue, follow instructions at Inspecting the initramfs including activating the initramfs-extra, then execute
start_charging_mode in the shell.
Heimdall: Flashing fails at 7%
You might also be getting the error "ERROR: Failed to confirm end of file transfer sequence"