0% found this document useful (0 votes)
20 views

Lab 00 Setup

Uploaded by

ahmed
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
20 views

Lab 00 Setup

Uploaded by

ahmed
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

Embedded Linux System Development

QEMU ARM variant

Practical Labs

Bechir Zalila
[email protected]

May 6, 2021
Embedded Linux System Development

About this document


Modified by Bechir Zalila (2019).
This document is a modified version of another document writtent by Bootlin, https://
bootlin.com. Updates to the original document can be found on https://bootlin.com/
doc/training/embedded-linux-qemu and sources can be downloaded from https://git.
bootlin.com/training-materials.

Copying this document


© 2004-2021, Bootlin, https://bootlin.com.
This document is released under the terms of the Creative Commons CC BY-
SA 3.0 license . This means that you are free to download, distribute and even
modify it, under certain conditions.
Corrections, suggestions, contributions and translations are welcome!

2 © 2019-2021 Bechir Zalila, CC BY-SA license


Embedded Linux System Development

Ubuntu installation
Set up the Linux distribution: Ubuntu 20.04

Option 1: native installation


Go to https://ubuntu.com/#download, download the Desktop edition and then follow the
instructions.
You don’t have to replace your existing operating system completely. Just make some free
space (at least 30 GB for Ubuntu and the labs we will run) and install Ubuntu alongside
your existing system.

Option 2: using a VirtualBox virtual machine


In case you have to keep your existing operating system and dual-booting is not an option,
another option is to download VirtualBox (https://www.virtualbox.org/) and download
and use our virtual machine image from https://f000.backblazeb2.com/file/bootlin-
big-files/training/ubuntu-20.04-20200617.ova
You will still need something like 30 GB of free space to run all the labs comfortably.
In Virtualbox, you just have to use File -> Import Appliance to create a new virtual machine
from this image.
In this VM, here are the credentials:
• User: tux
• Password: tux

© 2019-2021 Bechir Zalila, CC BY-SA license 3


Embedded Linux System Development

Training setup
Download files and directories used in practical labs

Install lab data


For the different labs in this course, your instructor has prepared a set of data (kernel images,
kernel configurations, root filesystems and more). Download and extract its tarball from a
terminal:
$ cd
$ wget /embedded-linux-qemu-labs.tar.xz
$ tar xvf embedded-linux-qemu-labs.tar.xz

Lab data are now available in an embedded-linux-qemu-labs directory in your home direc-
tory. This directory contains directories and files used in the various practical labs. It will
also be used as working space, in particular to keep generated files separate when needed.
You are now ready to start the real practical labs!

Install extra packages


Feel free to install other packages you may need for your development environment. In
particular, we recommend to install your favorite text editor and configure it to your taste.
The favorite text editors of embedded Linux developers are of course Vim and Emacs, but
there are also plenty of other possibilities, such as Visual Studio Code1 , GEdit, Qt Creator,
CodeBlocks, Geany, etc.
It is worth mentioning that by default, Ubuntu comes with a very limited version of the vi
editor. So if you would like to use vi, we recommend to use the more featureful version by
installing the vim package.

More guidelines
Can be useful throughout any of the labs
• Read instructions and tips carefully. Lots of people make mistakes or waste time
because they missed an explanation or a guideline.
• Always read error messages carefully, in particular the first one which is issued. Some
people stumble on very simple errors just because they specified a wrong file path and
didn’t pay enough attention to the corresponding error message.
• Never stay stuck with a strange problem more than 5 minutes. Show your problem to
your colleagues or to the instructor.
• You should only use the root user for operations that require super-user privileges,
such as: mounting a file system, loading a kernel module, changing file ownership,
configuring the network. Most regular tasks (such as downloading, extracting sources,
compiling...) can be done as a regular user.
• If you ran commands from a root shell by mistake, your regular user may no longer
be able to handle the corresponding generated files. In this case, use the chown -R
command to give the new files back to your regular user.
Example: $ chown -R myuser.myuser linux/

1 This tool from Microsoft is Open Source! To try it on Ubuntu: sudo snap install code --classic

4 © 2019-2021 Bechir Zalila, CC BY-SA license

You might also like