Jump to content

Initramfs/Inspecting

From postmarketOS Wiki
Revision as of 17:25, 31 August 2017 by Ollieparanoid (talk | contribs) (Link to boot process, adjust initramfs generation step (no full install necessary))

This page explains how to connect to your device when it has booted to the initramfs by installing the so-called usb-shell hook. This is useful if you want to know more about the boot process, simply inspect the initramfs or you want to debug why something doesn't work.

NOTE: This is considered a security hole. Only use it for debugging, and uninstall the usb-shell hook afterwards

By default, initramfs launchs a telnet daemon listening on :23 waiting for your partition password.

It is possible to enable a second telnet daemon on :24 that gives you a shell this way:

./pmbootstrap.py initfs hook_add usb-shell
./pmbootstrap.py initfs
./pmbootstrap.py flasher boot # or however you flash/boot the kernel

After reflashing the kernel or booting with the new initramfs image, you should be able to connect to the new telnet instance.

Tips and tricks