run arch linux arm on a steamlink, without touching the nand
Running Arch Linux ARM on the Steam Link. Yes, running - no puny chroot.
The Steam Link has ~256MiB of RAM (unlike what Wikipedia says),
and a Marvell ARMv7 CPU (1 Core, 1 Thread) (MV88DE3108
).
Directly booting a custom image has been made /harder/ due to contractual requirements. This repository explores alternative methods.
bsdtar
curl
sudo
e2fsprogs
sudo mkfs.ext4 /dev/sdXY
sudo tune2fs -O ^has_journal /dev/sdXY
- disable journaling (no kernel support)Three scripts - factory_test
, init-trampoline
and handoff
- work together to replace
the running userspace (including PID 1) with a different one.
factory_test
:
handoff
handoff
:
/sbin/init
in a tmpfs/sbin/init
, overlaying init-trampoline
init
binary as telinit u
to reexec init
init-trampoline
init-trampoline
:
pivot_root
s to the new userspace rootfschroot
s to the new userspace rootfs to work around an issue causing the caller to still have their cwd in the old rootfslib/systemd/systemd
to hand off PID 1 to systemdhandoff
before mounting it, saves us from copying it to tmpfshandoff
idea, debugging