AArch64 QEMU User Space Emulation
QEMU linux-user
There is a QEMU userspace emulator available to execute AArch64 applications on an x86_64 machine and kernel. This program interprets aarch64 binaries and translate operating system calls to the underlying x86_64 kernel, enabling many aarch64 binaries to be executed with good performance. However, because it does not emulate the full system, some capabilities are not available: in particular, debugging software such as gdb and strace will not work.
Special Mounts
In the arm64 chroot, some commands such as mount and top will not work correctly because special filesystems such as /proc
and /sys
are not mounted. If you need those filesystems, explicitly mount them within your chroot environment, remembering to unmount them when you're done.
Setting Up Qemu User Space Emulation
On Australia
1. Unpack the archive in your home directory:
cd ; sudo tar xvf /public/qemu-linux-user-aarch64
2. To switch to arm64/aarch64 mode, type:
sudo chroot ~/arm64
On your home system
1. Obtain the files in the /public/qemu-linux-user-aarch64
directory on Australia: arm64.qemu-userspace.tgz
and qemu-arm64.conf
2. Copy those files your machine.
3. In a suitable location with at least 1.1GB of storage available, unpack the arm64.qemu-userspace.tgz
archive as root (use -p to preserve permissions and timestamps).
4. Put the qemu-arm64.conf file into /etc/binfmt.d/qemu-arm64.conf on your local machine.
4. Activate the new qemu-arm64 binformat configuration:
sudo systemctl restart systemd-binfmt
5. To switch to arm64/aarch64 mode, type:
sudo chroot ~/arm64 # or wherever you put your arm64 directory