2. Ubuntu Virtual Machine Installation - anhtien17/free5GC GitHub Wiki
In this first step, we:
- Install Virtualbox
- Create and install a Ubuntu virtual machine
- Install a specific Kernel version (5.4.0-42-generic).
A. Install Virtualbox
- Download Virtualbox from https://www.virtualbox.org/ and install (currently 6.1.26).
- Install following the instruction on the software.
B. Create a Ubuntu VM
-
Download Ubuntu ver 20.04.2.0.
-
Launch VirtualBox and create your first Ubuntu VM using the downloaded .iso image file. Some notes when creating a new VM:
- Name the first VM using a generic name as ubuntu, or ubuntu-20.04
- You can pick 1 or 2 (or more) CPUs, and about 2048M memory, although you can change them later
- In addition, change the default
NAT
network interface toBridged Apdater
network interface (in Setting of Virtualbox interface).
-
Install Ubuntu:
It is recommended that you should:
- Choose a short username and password for ease of typing later
- Choose
Minimal Installation
and uncheckDownload updates while installing ubuntu
, to do not install new Kernel which may cause error when runningmake
of free5gc as well as ueransim.
-
Install plugin
Insert Guest Addition CD Image
from Virtualbox/Devices interface after booting Ubuntu VM on the first time to enhance display solution.
C. Install a specific Kernel version
-
Check Kernel version
uname -r
-
Check a specific kernel version and install
# To find all kernels in version 5 sudo apt search 'linux-image-5*' # Install specific kernel version sudo apt install 'linux-image-5.4.0-42-generic'
-
Update initramfs
sudo update-initramfs -u -k all
-
Set default grub kernel boot
-
Update grub then reboot
sudo update-grub sudo reboot uname -r # check version again
-
Install kernel header file
sudo apt install linux-headers-$(uname -r)