joe Linux ARM
joe Linux ARM is joe Linux for 64-bit Arm servers and virtual machines. It keeps dave, its upgrades and the security module, and rebuilds everything under them.
What it is
joe Linux ARM is a console system for 64-bit Arm machines that start with UEFI. It has no desktop. Its packages come from their own repository, joelinux.io/aarch64, and it is developed in its own git repository, joe-linux-aarch64.
What joe Linux is known for is the same: upgrades are applied to a btrfs snapshot and step back by themselves when the new system does not start, dave installs and upgrades, and the security module holds privileged processes to signed code. The userland is GNU, so the system is ordinary to use: bash, coreutils, util-linux, OpenSSH, doas, vim and nano.
What is under them is new:
| joe Linux | joe Linux ARM | |
|---|---|---|
| Processors | x86_64 | aarch64 (ARMv8.0 and later), UEFI with ACPI or a device tree |
| C library | glibc | bionic, from the Android Open Source Project, made into a Linux C library |
| Compilers | GCC | LLVM only: clang, lld, compiler-rt, libunwind, libc++, installed on every system |
| Init | systemd | dynamod |
| Boot loader | systemd-boot | systemd-boot |
| Desktop | GNOME | none |
bionic is Android’s C library. joe builds it from AOSP’s sources with AOSP’s own build descriptions, and a series of patches makes it a C library for an ordinary Linux system: accounts in /etc/passwd and /etc/shadow, time zones in /usr/share/zoneinfo, the resolver reading /etc/resolv.conf, syslog writing to /dev/log, and the interfaces programs written for glibc expect. The repository’s README lists them.
Releases are named as joe Linux’s are, JX-Y-Z (the system revision, the kernel’s version and dave’s version), but they are their own: joe Linux ARM’s J1-7.3.1-0.3.0-alpha1 is not the same system as joe Linux’s J1-7.3.1-0.2.0-alpha1.
What you need
- A 64-bit Arm machine with UEFI firmware, or a virtual machine: QEMU’s
virtmachine with the edk2 firmware (QEMU_EFI.fd, callededk2-aarch64-code.fdin some packages). - A disk of at least 20 GB that you are willing to erase.
- A serial console or a screen and keyboard. Servers’ management controllers offer both.
So far it has run in QEMU only. Arm servers with UEFI and ACPI should work; if you try one, a report is welcome.
Starting the medium
Download the medium from the downloads page. Write it to a USB stick, or attach it to the machine as a CD, and start the machine from it. In QEMU on an Arm machine:
qemu-system-aarch64 -M virt -cpu host -accel kvm -m 4G -smp 4 \
-drive if=pflash,format=raw,readonly=on,file=QEMU_EFI.fd \
-drive if=pflash,format=raw,file=QEMU_VARS.fd \
-device virtio-scsi-pci -device scsi-cd,drive=cd \
-drive if=none,id=cd,media=cdrom,readonly=on,file=MEDIUM.iso \
-drive if=virtio,file=disk.qcow2 -nographic
On a Mac, use -accel hvf. On an x86_64 computer, replace -cpu host -accel kvm with -cpu max; it works, slowly.
The medium starts a live console system with root logged in, on the serial console and on the screen. Nothing done there is kept.
Installing
dave install-system --list
dave install-system --disk /dev/vda
The first shows the disks and whether each can be used. The second erases the disk it names and installs joe onto it: an EFI system partition and a btrfs root, the packages copied from the medium itself. The firmware is told about the new system, then you restart it from the disk.
The first start
An installed system has no account anyone can log in with yet, so on its first start the console asks for one instead of showing the login prompt. Whichever console you use, serial or screen:
- Choose a password for root.
- Optionally, create an account of your own. It can act as root with
doas, and can log in over SSH with its password. - Optionally, paste an SSH public key, for that account or for root. Root logs in over SSH only with a key.
After that the console shows the ordinary login prompt.
Using it
Packages come from joelinux.io/aarch64, about 200 of them: libraries, development tools such as git, curl, rsync and ccache, the command line (tmux, htop, jq, GnuPG, tcpdump), and servers such as nginx, HAProxy, PostgreSQL, Valkey, memcached, Unbound, chrony, WireGuard and OpenVPN.
doas dave install nginx
doas dynamodctl enable nginx
doas dynamodctl start nginx
Servers are installed disabled. dynamodctl enable NAME starts one at every boot, and dynamodctl start NAME starts it now. dynamodctl also answers to systemctl for the common commands. dave upgrade and dave rollback work as on joe Linux: an upgrade is applied as the machine shuts down, and the previous system is kept to go back to.
Building software
Every system has a compiler: clang, the lld linker and LLVM’s binary tools, which also answer to the names build systems use (cc, c++, cpp, ld, ar, nm, objcopy, strip and the rest). It is configured as the compiler joe Linux ARM is built with: programs link with libc++, libunwind and compiler-rt, and run on bionic. make, cmake, meson, ninja, autoconf and pkgconf are in the repository.
doas dave install make
./configure && make
Configure scripts see the system as aarch64-unknown-linux-android, which is how they recognise bionic. Software written for glibc mostly builds as it is; what does not is usually a missing GNU interface, and the repository is where those are fixed, in bionic itself.
Not done yet
- Real hardware: only QEMU has run it.
- The security module’s declarations: most privileged programs are not declared yet. That is fine while the module only logs, which it does unless the kernel is started with
joe=enforce. - Some packages wait on work in bionic: rsyslog needs POSIX thread cancellation, which bionic does not have, and strace, zsh, nfs-utils and nftables need more porting. Programs written in Go, Rust or for Node.js are not packaged.
- A desktop: one is planned on Shades, a display system written in Zig, rather than on Wayland and Mesa.