A step-by-step guide for building your very own Cybersecurity Home Lab using VirtualBox
In this module, we are going to install Kali Linux. We will use this VM in the next module also to complete the pfSense setup.
Go to the following link: Get Kali | Kali Linux
Download the 64-bit Recommended Installer. The image is ~4GB in size so it will take some time to download.
As of writing the latest version of Kali Linux is
Once it is downloaded we should have an
Launch VirtualBox. Select
Tools from the sidebar and then click on
New from the toolbar.
Give the VM a Name. Set the Folder option to the location where the Home Lab VMs are going to be saved. Leave the ISO Image option empty. Select Type as
Linux and Version as
Debian (64-bit) then click on
Leave everything on its default values. Click on
Increase the Disk Size to
80GB and click on
Ensure that all the settings look right and click on
Right-click on the Kali Linux VM from the sidebar, select
Move to Group -> [New].
The VM will now be added to a Group called
New Group. Right-click on the group name and select
Rename Group. Name the group
Select the Firewall and Management group (
Ctrl+Click). Right-click on the name of one of the groups. From the menu select
Move to Group -> [New].
Now both the groups should be nested inside a group called
New Group. Right-click on the group and choose
Rename Group. Give the group the name
In the end, we should have the following structure:
Select the Kali Linux VM and then from the toolbar select
System -> Motherboard. For the Boot Order option ensure that the
Hard Disk is on the top followed by
Go to the
Storage tab. Select the Empty disk present below
Controller: IDE then click on the small disk icon on the right side of the Optical Drive option.
Choose a disk file and then select the downloaded
.iso file for Kali Linux.
The final result should look as follows:
Network -> Adapter 1. For the Attached to field select
Internal Network. For Name select
LAN 0. Expand the Advanced section. For Adapter Type select
Paravirtualized Network (virtio-net).
Remember to boot the pfSense VM if it was shut down before starting the Kali Linux installation.
Select Kali Linux from the sidebar and click on
Start on the toolbar.
From the Installer menu select Graphical Install.
Select your Language, location and keyboard layout.
Enter a name for the VM. You can use any name here. The hostname is used to identify the system on the network. The hostname can also be changed after installation.
Leave the domain name input blank and click on
Enter your name. This name will be shown on the login screen.
The username is used to create the home directory for the user. All the user-related configurations are stored in this folder.
Enter a strong password. Re-enter the password in the second field and click on
Select your clock and then click on
Select the drive (
sda) and click on
Select Guided - use entire disk and then click on
Select the option: All files in one partition and click on
Select Finish partitioning and write changes to disk. Then click on
Yes and click on
After the base system installation is complete we need to choose the desktop environment that will be installed. I have selected GNOME for installation.
The default is XFCE it does not look as pretty as GNOME it is much lighter and should have better performance. KDE Plasma is the fanciest with a lot of bells and whistles. I would only recommend KDE if you can assign 2 cores and 4GB RAM for this VM. Once the desktop environment is selected click on
The installation will take some time. Select
Yes and click on
Continue to Reboot the system.
After reboot, we should see the Login screen. Click
Enter to log in. Enter the password that was configured during the installation.
Kali Linux installer can detect when it is run from a VM because of this it automatically installs Guest Addons.
Right Ctrl+F to enter Fullscreen mode. The VM should scale to fill the entire screen. Press
Right Ctrl+F again to exit Fullscreen mode. From the dock at the bottom of the screen. Select the Terminal.
Run the command:
ip a. We can see that the Kali VM has been assigned an IP address from the LAN network range. The VM should be able to access the internet as well.
Use the following command to update the system:
sudo apt update && sudo apt full-upgrade
Enter password when prompted.
Once the sources have been fetched we will be asked if we want to continue. Enter
Y and then press
Enter to start the update.
After the update is complete run the following command to remove the unused packages:
sudo apt autoremove
.iso file that was downloaded to create the VM can be deleted now if you do not plan to store it for future use.
In the next module, we will access the pfSense Web UI and complete the remaining configuration.