In this article, we will show you how to install the Debian 12 server operating system on an Oracle VirtualBox 7 virtual machine.
Topic of Contents:
- Downloading the Debian 12 ISO Image
- Creating a Debian 12 VirtualBox Virtual Machine
- Starting the Debian 12 VirtualBox 7 Virtual Machine
- Installing the Debian 12 Server on the VirtualBox 7 Virtual Machine
- Installing the VirtualBox Guest Additions on the Debian 12 Virtual Machine
- Conclusion
Downloading the Debian 12 ISO Image
You can download the ISO image of Debian 12 from the official website of Debian. If you need any assistance on that, read this article.
Creating a Debian 12 VirtualBox Virtual Machine
To create a new VirtualBox virtual machine, open the Oracle VM VirtualBox app and click on Machine > New.
Type in a name for the VirtualBox virtual machine in the “Name” section[1].
To select the Debian 12 installation ISO image, click on “Other” from the “ISO Image” dropdown menu[2].
Select the Debian 12 ISO image file that you downloaded and click on “Open”.
The Debian 12 ISO image file should be selected. Make sure that Linux and Debian are selected as the “Type” and “Version” for the virtual machine, respectively[1].
Tick on “Skip Unattended Installation”[2] and click on “Next”[3].
Select the amount of memory and the number of processor cores that you want to allocate for the Debian 12 virtual machine[1] and click on “Next”[2].
Select the amount of disk space that you want to allocate for the Debian 12 virtual machine[1] and click on “Next”[2].
Click on “Finish”.
A Debian 12 VirtualBox virtual machine should be created.
Starting the Debian 12 VirtualBox 7 Virtual Machine
To start the Debian 12 virtual machine, select it from the VirtualBox app[1] and click on “Start”[2].
The Debian 12 VirtualBox virtual machine should start and greet you with the Debian 12 installer’s boot menu.
Installing the Debian 12 Server on the VirtualBox 7 Virtual Machine
To install the Debian 12 server operating system on the VirtualBox virtual machine, select “Graphical install” from the Debian 12 installer’s boot menu and press <Enter>.
The Debian 12 graphical installer should be displayed. You can install the Debian 12 server operating system on the VirtualBox virtual machine from here.
The Debian 12 server can be installed on the virtual machine in the same way as you install it on a real computer. We wrote an article on how to install the Debian 12 server on a computer which covers the in-depth Debian 12 server installation process. So, we will quickly go over the installation process here without too much explanation. For a detailed information on installing Debian 12 on the VirtualBox virtual machine, read the article on How to Install the Debian 12 Server Operating System on your Computer.
First, select your language and click on “Continue”.
Select your country and click on “Continue”.
Select your locale and click on “Continue”.
Select your keyboard and click on “Continue”.
Type in a hostname[1] and click on “Continue”[2].
Type in a domain name (optional)[1] and click on “Continue”[2].
Type in a root password (if you want to enable the root user account) and click on “Continue”. This is optional. You can leave it blank if you want to use sudo to get the superuser privileges.
Type in your full name[1] and click on “Continue”[2].
Type in your username[1] and click on “Continue”[2].
Type in your login password and click on “Continue”.
Since you’re installing the Debian 12 server on a virtual machine, you can safely install Debian 12 on the entire disk. So, double-click (LMB) on “Guided – use entire disk” to select it.
NOTE: If you have special application/workload-specific partitioning requirements for the disks, read this article to learn how to do advanced partitioning for your Debian 12 installation.
Select a virtual disk for the Debian 12 server installation[1] and click on “Continue”[2].
Select “All files in one partition (recommended for new users)”[1] and click on “Continue”[2].
Select “Finish partitioning and write changes to disk”[1] and click on “Continue”[2].
Select “Yes”[1] and click on “Continue”[2].
The Debian 12 base system is being installed on the virtual machine. It takes a few seconds to complete.
Select “No”[1] and click on “Continue”[2].
Select your country to find the best package mirror for Debian (so that you get faster downloads of the Debian packages) and click on “Continue”.
Select “deb.debian.org” (or any Debian mirror that you like) and click on “Continue”.
Click on “Continue”.
The Debian 12 installation should continue.
Select “No”[1] and click on “Continue”[2].
To install the Debian 12 server on the virtual machine, uncheck everything from the Software selection prompt and check only the “SSH server” and “standard system utilities”[1].
Once you’re done, click on “Continue”[2].
The Debian 12 installation should continue. It takes a while to complete.
Select “Yes”[1] and click on “Continue”[2].
Select “/dev/sda”[1] and click on “Continue”[2].
The Debian 12 installation should continue.
At this point, the Debian 12 server operating system should be installed on the VirtualBox virtual machine.
Click on “Continue”.
The Debian 12 virtual machine should reboot into the newly installed Debian 12 server operating system.
Select “Debian GNU/Linux” from the Debian 12 boot menu and press <Enter>.
Login to your Debian 12 server virtual machine with the username and password that you setup during the installation.
You should be logged into the Debian 12 server virtual machine.
Installing the VirtualBox Guest Additions on the Debian 12 Virtual Machine
To get the best performance on the Debian 12 server VirtualBox virtual machine, you must install the VirtualBox Guest Additions on the Debian 12 virtual machine.
For more information on VirtualBox Guest Additions, read this article.
Conclusion
We showed you how to create a Debian 12 VirtualBox virtual machine. We also showed you how to install the Debian 12 server operating system on the VirtualBox virtual machine.