1 of 23

Installing Debian 11 Bullseye and Debian 12 Bookworm/sid Headless

Libre Computer AML-S905X-CC

2 of 23

Debian 11 Bullseye Stable Headless Overview

  • Debian is an open source Linux distribution maintained by community.
    • Debian releases a stable version roughly every two years.
    • “deb” packaging system controlled by the “apt” tool.
    • Software repositories are broken down into “main”, “contrib”, “non-free”.
      • main: official packages that comply with Debian Free Software Guidelines
      • contrib: packages with non-free package dependencies
      • non-free: packages with non-free licenses
  • Version 11 codename “Bullseye” was released on August 14th, 2021.
    • Linux 5.10
  • Headless does not install a GUI or Windowing System.
    • Minimal packages ideal for fast bootup time in IoT applications, servers, and remote ssh.
    • Designed for intermediate and advanced Linux users. Not recommended for GUI.
  • Installing from official Debian sources for maximum security.
    • Pre-packaged images by non-official sources may pose security risk.
  • Window Managers and audio may not work properly in this release!
    • Better use Debian sid or Ubuntu jammy with newer kernel and userspace utilities.

3 of 23

Debian 12 Bookworm/sid Headless Overview

  • Debian releases a CI unstable daily.
    • Features the latest packages of many open source projects.
  • Version 12 codename “Bookworm” will be release mid-2023.
    • Linux 5.20+
  • Great for testing Linux graphical features
    • Kernel
    • Wayland
    • Graphics
    • Sound
    • Much more!

4 of 23

Prerequisite

Please follow the instructions carefully so that you don’t miss any important steps. If you miss a step, the resulting installation may not boot. The installation takes ~30 minutes but may depend on your storage devices and thermal headroom.

  • MicroSD card flashed with Board Firmware + MBR EFI partition
  • USB flash drive flashed with Debian netinst arm64 (not amd64):
  • Use raw disk imaging utility to flash images on MicroSD and USB flash drive
    • Windows: Win32DiskImager
    • macOS: Disk Utility
    • Linux: gnome-disks or dd

5 of 23

Booting Installer

  1. Attach HDMI cable to the board
  2. Attach USB keyboard to the board
  3. Attach USB mouse to the board (optional)
  4. Attach eMMC 5.x Module to the board (optional)
  5. Insert flashed MicroSD card and USB drive
  6. Insert USB Drive and MicroSD card
  7. Attach MicroUSB Power to the board
  8. Wait for the board to load GRUB
  9. Select Graphical Install with your keyboard

6 of 23

Troubleshooting Booting Installer

  • If there is a pre-existing image on eMMC and your device does not boot from MicroSD card, you need to remove the bootloader from the eMMC.

7 of 23

Continue Through Installer Until Network Setup

If you get this message: “No device for installation media was detected.”

Try unplugging and re-plugging your USB key in a different USB port.

8 of 23

Network Setup

Configuring the network� Network autoconfiguration failed�Your network is probably not usin the DHCP protocol. Alternatively, the DHCP server may be slow or some network hardware is not working properly.

  1. This is an expected failure and will be fixed in Debian upstream in the future. It does not affect ethernet in the installed OS.
    1. Select Continue
    2. Select “Do not configure the network at this time”
    3. Select Continue

9 of 23

Network Setup Continued

  • Enter your hostname. This is the name of your computer on your network.
    • It can be any alphanumeric sequence but must start with a letter.
    • A typically naming convention is user-machine, eg: john-aml-s905x-cc or john-lepotato.

10 of 23

Setup Root and Users

  1. You will be asked to set the root password. The root user is a super-user the ability to modify the system. This is NOT an optional step or you will not be able to install any packages. There is no sudo!
  2. Full name for the user (optional): Your name
  3. Username for your account: The username you plan to use to login
  4. User password: The password you plan to use to login

11 of 23

Disk Setup

You must select “Manual” and Continue.

12 of 23

Disk Setup MicroSD Card

  1. The instructions below are for installing to MicroSD card. The bootloader must be preserved on the MicroSD card during partitioning or the device will not boot when installation is complete.
    1. If you want to install on eMMC module, skip the instructions below and go to the next page.
  2. Under mmcblk0 Select “FREE SPACE” and Continue
    • Select “Create a new partition”
    • Type “1GB” for the New Partition Size
    • Select “Primary” and “Beginning”
    • Select “Use as” and change to “swap area”
    • Select “Done setting up the partition” and Continue
  3. Under mmcblk0 Select “FREE SPACE” and Continue
    • Select “Create a new partition”
    • Leave New Partition Size to its default value and Continue
    • Select “Primary”
    • Select “Use as” and change to “btrfs journaling file system”
    • Done setting up the partition
  4. Under mmblk0 Select fat32 and Continue
    • Select “Use as” and change to “EFI System Partition”
    • Done setting up the partition
  5. Select “Finish partitioning and write changes to disk”
    • When prompted “Write the changes to disks?” Select Yes

13 of 23

Disk Setup eMMC Module

  1. The instructions below are for installing to eMMC Module only.
    1. Installation on eMMC does not require MicroSD card to boot since we will write the bootloader to the eMMC module boot0 partition.
  2. Select mmcblk1 and Continue
    • When prompted “Create new empty partition table on this device?”, select “Yes” and Continue
  3. Under mmcblk1 Select “FREE SPACE” and Continue
    • Select “Automatically partition the free space” and Continue
    • Select “All files in one partition (recommended for new users)” and Continue
  4. Under mmcblk1 Select “ext4” and Continue
    • Select “Use as” and change to “btrfs journaling file system”
    • Done setting up the partition
  5. Select “Finish partitioning and write changes to disk”
    • When prompted “Write the changes to disks?” Select Yes

14 of 23

Package Manager

When prompted “No network mirror was selected.

Continue without a network mirror?” Select Yes

15 of 23

Popularity Contest

You can optionally participate in the Debian package survey.

16 of 23

Software Selection

Keep the “standard system utilities” and Continue

17 of 23

GRUB Boot Loader

GRUB Installer will fail and this is expected.�We will install GRUB manually. Continue twice.

18 of 23

Installing GRUB manually

Select “Execute a shell” and Continue twice.

19 of 23

distrofix.sh

  1. Debian install requires some modifications to make the installation bootable.
    1. We have supplied a distrofix.sh script to make the necessary changes.
  2. Type the following command sequences
    • chroot target
    • For MicroSD card installation:
      1. /boot/efi/distrofix.sh
    • For eMMC module installation:
      • mount /dev/mmcblk0p1 /mnt
      • /mnt/distrofix.sh
      • umount /mnt
    • exit
    • exit

20 of 23

GRUB Boot Loader

Select “Continue without boot loader” and Continue.

21 of 23

Installation Complete

  • Remove the USB drive and MicroSD card
  • Continue

22 of 23

Where to go from here?

  • Login as root, install sudo, add user to sudo group, and remove root access
    • apt update
    • apt dist-upgrade
    • apt install sudo
    • adduser USERNAME sudo #replace USERNAME with your username
    • passwd -l root
  • Need SSH? apt install ssh
  • Treat it like any Debian Linux installation. Everything should be standard.
  • Update to latest kernel with ethernet fix and media acceleration:
  • Debian 12 Bookworm/sid only
    • apt install weston

23 of 23

Known Issues

  • Debian 11
    • Reboot hangs on stock kernel
  • 3D rendering limited to 1920 width/height by Mali-450
  • Sometimes ethernet hangs with stock kernel
    • Install latest kernel from previous page
  • Leave a comment or questions to help us improve this document.