Arch Linux Arm on Banana Pi compiled from Arch Linux
Copy Arch Linux arm base filesystem
We start with a fresh SD card. Firstly, format the SD card as described in the Cubieboard 2 tutorial. /dev/sdc
is my SD card.
1 2 3 4 5 6 7 8 |
|
The SD card is synced with the base file system of ALARM. Now onto creating the u-boot components u-boot-sunxi-with-spl.bin
and boot.scr
, you could refer to compiled files by tredaelli but as they caused boot problems for me, I will continue with creating those two by myself.
Compiling boot.scr and u-boot myself
I will at first install the Arch Linux uboot-tools package. Followed by creating both files from sources in a folder self-build
that was placed in my working directory with the precompiled files. Use the Arch Linux wiki article to fetch the file contents.
1 2 3 4 5 6 7 8 9 10 11 12 |
|
Now the u-boot binary.
1 2 3 4 5 6 |
|
In the end, my workspace looked like this (sizes in bytes):
1 2 3 4 5 6 7 8 9 10 11 12 13 |
|
Make fails due to wrong Python version
In case you encounter a problem with your Python version when binman
is called, manipulate $PATH
to find Python2 first. Problem here is the shebang #!/usr/bin/env python
, which is Python3 on Arch Linux but binman awaits Python2
1 2 3 4 5 6 7 8 |
|
Troubleshooting
Plug and play my ass. Again I needed to plug in a monitor to see what's broken. I was lucky DHCP worked. With the precompiled files in the steps above the kernel was not loaded and the Pi was stuck in trying to load pxelinux from the network. With the self compiled files the kernel booted and used the DHCP address.
SSH does not work
Port 22 connection refused! Systemctl showed start request repeated too quickly, refusing to start
. Problem: Server keys could not be loaded. This might have been caused by power interrupt during debugging, so that the keys were generated but not written to SD card in time, resulting in empty files in /etc/ssh
. As root on the Pi:
1 2 3 4 |
|
See also SSH: Could not load host key: /etc/ssh/ssh_host_rsa_key.
netctl not able to start wifi configuration
I was trying to set up this Banana Pi with a 5Ghz wifi dongle (TP-Link TL-WDN3200, Ralink RT5572 chip, 148F:5572), configured the netctl profile /etc/netctl/wireless
as followed:
1 2 3 4 5 6 7 8 9 |
|
Using netctl start wireless
resulted in Could not create a wpa config file for interface
. Problem: no wpa_supplicant installed. pacman -S wpa_supplicant
solves this problem. Enable the profile with netctl enable wireless
so it will be automatically started on boot.