The Cubieboard2 is an low cost, high performance open ARM box based on Allwinner A20 (Cortex A7 Dual-Core) which can be used in many fields.
This development board was generously donated by Cubietech in 2013 to support the development of CRUX-ARM for this device.
After all these years, we continue to use and maintain it actively, highlighting its lasting value and reliability.
To install CRUX-ARM on a Cubieboard2, the first step is to prepare a microSD card with the appropriate partitions, install a compatible bootloader, and deploy the CRUX-ARM root filesystem.
This process involves creating the necessary partition layout tailored to the device, setting up the bootloader files (such as the zImage specific to Cubieboard2), and extracting the CRUX-ARM system files onto the designated partition.
The following sections will provide a detailed, step-by-step guide covering each of these tasks to ensure a smooth and reliable installation tailored for ARM architecture. This approach leverages CRUX-ARM’s simplicity and flexibility, allowing users to build a lightweight and customizable Linux environment optimized for ARM-powered devices like the Cubieboard2.
Before beginning the installation process, you will need access to a computer (running Linux is recommended) and a microSD card with sufficient capacity for the CRUX-ARM root filesystem. The microSD card will be used to store the bootloader, the necessary partitions, and the CRUX-ARM system itself. Ensure you have a card reader and the appropriate permissions to write to the device.
1. Flashing the Bootloader
The first step is to write the bootloader (u-boot) to the microSD card. This is essential for the Cubieboard2 to initialize and start the operating system. Use the following command, replacing ${card} with the device path of your microSD card (for example, /dev/mmcblkX):
dd if=u-boot-sunxi-with-spl.bin of=${card} bs=1024 seek=8
Warning: Be very careful to select the correct device path for your microSD card, as using the wrong device could overwrite important data.
2. Partitioning the microSD Card
After installing the bootloader, you need to create a single partition on the microSD card. With current U-boot version (v2025.04) only one ext2 or ext4 partition is required. This partition will later be configured with extlinux and will contain the CRUX-ARM root filesystem.
You can use tools like fdisk or parted to create the partition. For example, using fdisk:
fdisk ${card}
Create a new primary partition (type: Linux, usually type 83). Write the changes and exit.
Then, format the partition as ext4 (replace ${card}1 with your partition name):
mkfs.ext4 ${card}1
Once the partition is ready, you can proceed to deploy the latest version of CRUX-ARM onto it and configure extlinux.
3. Verify CRUX-ARM release checksum
Before proceeding, it is crucial to verify the integrity of the downloaded CRUX-ARM root filesystem archive. This is done by calculating its SHA-256 checksum and comparing it to the official checksum provided by the source. This step ensures that the file has not been corrupted or tampered with during download:
sha256sum crux-3.8-armhf-cubieboard2-rootfs.tar.xz
If the computed checksum matches the official value, you can safely continue with the installation.
4. Extracting CRUX-ARM rootfs into the created partition
Next, mount the previously created partition to a temporary mount point (e.g., /mnt) and extract the CRUX-ARM root filesystem archive onto it. This will deploy all necessary system files onto the microSD card:
mount ${card}1 /mnt tar pxvf crux-3.8-armhf-cubieboard2-rootfs.tar.xz -C /mnt
Ensure the extraction completes without errors before proceeding.
5. Prepare boot needed files
To enable the Cubieboard2 to boot CRUX-ARM, certain boot files must be placed in the appropriate directories on the microSD card:
Commands example:
mkdir /mnt/boot/extlinux cp extlinux.conf /mnt/boot/extlinux/ cp zImage /mnt/boot/ cp sun7i-a20-cubieboard2.dtb /mnt/boot/
This setup allows the bootloader to find the kernel and configuration needed to start the system.
6. Finally uncompress kernel modules and headers
The last step is to extract the kernel modules and headers into the root filesystem. These components are essential for hardware support and compiling additional software:
tar pxvf modules-6.14.8.tar.xz -C /mnt tar pxvf headers-6.14.8.tar.xz -C /mnt
After this, the microSD card will be fully prepared with the CRUX-ARM system, ready to boot on the Cubieboard2.
After deploying the CRUX-ARM root filesystem, it is important to configure several key system files to ensure proper operation and customization of your installation. The following files should be reviewed and edited according to your needs:
Review and adjust these files to match your hardware, network environment, and personal preferences. Proper configuration at this stage will ensure a smooth and stable experience with CRUX-ARM on your Cubieboard2.
Note: For detailed explanations and examples of these configuration files, please refer to the official CRUX Handbook. The handbook provides comprehensive guidance on system configuration and package management, which can be especially helpful for new users.
To obtain serial access:
s1:2:respawn:/sbin/agetty 115200 ttyS0 vt100
To ensure that all hardware components of the Cubieboard 2 function correctly under CRUX-ARM, it is essential to install the appropriate firmware files. Many devices on the board, depend on proprietary firmware that is not included in the kernel by default.
CRUX provides a dedicated port, linux-firmware, which contains the necessary firmware binaries for a wide range of hardware. Installing this package is required to guarantee that all features of the Cubieboard 2 are supported.
You can install the firmware package and its dependencies using the following command:
prt-get depinst linux-firmware Note: Without installing linux-firmware, certain devices on the Cubieboard 2 may not function properly or may not be detected at all.
This command will automatically resolve and install any required dependencies along with the linux-firmware package, ensuring that your Cubieboard 2 hardware operates as intended
After installation, it is recommended to reboot the system to load the newly installed firmware.
To view available governors and frequencies:
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors cat /sys/devices/system/cpu/cpu1/cpufreq/scaling_available_governors
To set the governor and frequency limits for each cpu:
echo "ondemand" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor echo "ondemand" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor echo "144000" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq echo "960000" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq echo "144000" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_min_freq echo "960000" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq
https://linux-sunxi.org/
https://linux-sunxi.org/U-Boot#Compile_U-Boot
https://linux-sunxi.org/U-Boot#Configure_U-Boot
https://linux-sunxi.org/Bootable_SD_card#Partitioning
https://linux-sunxi.org/Linux_Kernel
https://linux-sunxi.org/Mainline_Kernel_Howto
https://linux-sunxi.org/FEL/USBBoot
Reference on how we build U-boot/Kernel