From Fedora Project Wiki

< Architectures‎ | AArch64

Revision as of 19:54, 8 April 2014 by Dmarlin (talk | contribs) (Starting the Model)


Aarch64 Quickstart Guide

This page will help those new to aarch64 (ARMv8) get started with the Foundation Model provided by ARM. The F21-20140407-foundation-v8 Remix tarball provides an F21-based disk image, which includes a kernel, initramfs, and device tree blob, files to support booting the kernel using EFI and Grub2, and a sample script for starting the model. This Fedora Remix uses a look aside repository for the kernel package, which includes patches that are headed upstream, but not yet added to Fedora.

Download the Foundation Model

The first step is to download the Foundation model from ARM. The model is not re-distributable and will therefore require you to create a free account with ARM. Once completed, you will be able to download the Foundation Model and begin.

To run the model you may need to install some additional software with the following command:

sudo yum install xterm xorg-x11-fonts-{misc,100dpi,75dpi}* telnet bridge-utils

Extract the Foundation Model

Once you have downloaded the model, you will need to set up your environment. The model can be extracted to a path of your choosing. Your home directory will be used in this example.

Unpack the model:

mkdir ~/aarch64
cd ~/aarch64
tar xvzf FM000-KT-00035-r0p8-52rel06.tgz

Using the Model with an Image

Using the commands below, download and extract the Aarch64 root filesystem tarball.

Note: The extracted disk image requires approximately 12GB disk space. Please ensure you have adequate free space. This may take several minutes to unpack, depending on your hardware.
cd ~/aarch64
tar Jxvf F21-20140407-foundation-v8.tar.xz 

Allowing the Model to Connect to the Internet

On the host:

  • Enable IP forwarding (as root)
echo 1 > /proc/sys/net/ipv4/ip_forward
  • Set up Network Address Translation:
HOSTEXTERNAL=eth0 # Replace this with your outside interface
sudo iptables -I FORWARD -i $HOSTEXTERNAL -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
sudo iptables -I FORWARD -i ARM1 -o $HOSTEXTERNAL -j ACCEPT
  • Firewall trouble? Try this:
sudo iptables -I INPUT -i ARM1 -j ACCEPT

The model uses Google's Public DNS server ( for name resolution (/etc/resolv.conf).

Starting the Model

The kernel supports virtio, so the kernel image and initramfs included on the image will be used in the boot process. This image boots using UEFI (tianocore) and Grub2.

An example script for starting the model has been included in the tarball. This script performs the following steps to start the model:

sudo ../Foundation_v8pkg/models/Linux64_GCC-4.1/Foundation_v8 \
  --cores=1 \
  --visualization \
  --image=linux-system-el3-foundation.axf \
  --data=RTSM_VE_FOUNDATIONV8_EFI.fd@0xA0000000 \
  --block-device `pwd`/${IMAGE} \
  --network=bridged \
  --network-bridge=ARM1 &
sleep 5
sudo ifconfig ARM1 netmask
Depending on your environment you may need to change the IP addressing used.

To start the model, change to the image subdirectory and run the script:

 cd ~/F21-20140407-foundation-v8
You must have 'sudo' access in order to run this script. The script assumes the foundation model is in:
Adjust as necessary for your environment.

To connect to the serial console, telnet to the provided ports as it boots, for example:

telnet 5000     # note this is the IP of the model gateway and not the model
Connecting using telnet will also close the xterm popup window.

This is an example log of the model starting, and using telnet to access the console:

terminal_0: Listening for serial connection on port 5000
terminal_1: Listening for serial connection on port 5001
terminal_2: Listening for serial connection on port 5002
terminal_3: Listening for serial connection on port 5003
Visualization web server started on port 2001
Simulation is started
sh: xterm: command not found
telnet 5000

$ telnet 5000
Connected to
Escape character is '^]'.

The model will then start the first stage bootloader (tianocore), which will launch grub2, which will in turn boot the selected kernel, for example:

Secure firmware (version  built at 13:07:46 on Apr  7 2014)

|                                                                           |
|     ARM64, with Linux 3.14.0-0.rc8.git1.1.0.1.fc21.aarch64                |
|     ARM64, with Linux 0-rescue-79e714035d9e46cbbecc55e70a3b10a1           |
|                                                                           |
|                                                                           |
|                                                                           |
|                                                                           |
|                                                                           |
|                                                                           |
|                                                                           |
|                                                                           |
|                                                                           |
|                                                                           |
|   The selected entry will be started automatically in 1s.                 |
|   Press 'e' to edit the selected item, or 'c' for a command prompt.       |

EFI stub: Booting Linux Kernel...

You should be able to ssh to the model once it has fully booted.

It may take several minutes for the model to be fully booted.
  • For ssh login:
ssh root@        # note this is the IP address of the model


  • Verify that the system date/time are correct.
  • To avoid image or filesystem corruption it is important to shutdown the model properly.
 shutdown -h now
  • After shutting down, ensure the Foundation Model process has been stopped before restarting.
 sudo kill -TERM <PID for the Foundation Model process>
  • The root password is 'fedora'.

Fixing build failures

If you want to debug a broken package, please visit the problem package list, follow the directions and claim the packages of your choice.