Setup VM using Oracle Virtual Box 7

In blog Setup VM for DB2, we covered how to install and create VM using Oracle Virtual Box 6. Oracle has released Oracle Virtual Box 7 and process is bit different from Virtual Box 6. 

In this blog we will cover installation of Oracle Virtual Box 7 and creating a VM.

Step1: Download Oracle Virtual Box

You can download Oracle Virtual Box from  Download Oracle Virtual Box


Create SAMPLE database in DB2

In this blog we will go though steps to create sample database. You might need SAMPLE database with tables, views, index, function, procedure and dummy data to conduct POC or for testing, learning purpose. You will need a DB2 instance to create SAMPLE database. Check blog How to create DB2 Instance on Linux for instructions to create DB2 instance and start it.

Prerequisite :

To create SAMPLE database you need a DB2 instance, also you should have SYSADM or SYSCTRL authorities for that instance.

Shared Folder Access in Oracle Virtual Box Linux VM

You might be in a situation in which you need a shared file system between multiple VM or between your VM and host OS on which you can perform both read and write operation simultaneously. Oracle Virtual Box has a answer to this in form of Shared Folder feature but to use Shared Folder feature in your VM, you must install Virtual Box Guest Additions. This simple looking Virtual Box Guest additions is quiet complicated to setup in Linux VM, it becomes even more complicated if you are not a Linux admin. In this blog we will go through step by step process to setup Virtual Box Guest Additions and Add a Shared Folder in VM and access it.

Step1: Prerequisite

To configure Virtual Box Guest Addition, you need to have kernel-devel, gcc, make and elfutils-libelf-devel package installed. Run below command to check if packages are already present.

yum list gcc make kernel-devel elfutils-libelf-devel

yum list gcc make kernel-devel elfutils-libelf-devel







Add additional Storage to VM hosted on Oracle Virtual Box

In blog Setup VM for DB2, we went through step by step process to setup a Linux VM hosted on Oracle Virtual Box. After setting up your VM, you might be in a situation where you want to create a new File System or drive, extend size of existing File System or drive, but this can be done only if you have free space available on your VM. If all existing storage is allocated for file system or drive then to create new File System or drive you would need additional storage. In this blog we will go through step by step process to add additional storage to your Oracle Virtual Box VM and then utilize additional storage to create a new File System in RHEL.

Add additional Storage to VM hosted on Oracle Virtual Box

Before addition of additional storage to your VM, you should ensure that your VM is in Powered Off state. If it is in running State then Right Click on Your VM, Select Close and then Select Power Off to Power Off your VM. You can also use your VM OS shutdown method to gracefully Power Off your VM.

Red Hat Linux 8.2 Installation

In previous blog we have seen how to install and create a new VM in Oracle VirtualBox, if you have not read it, you can check Setup VM for DB2 LUW installation post. In this post we will install Red Hat Enterprise Linux (RHEL) 8.2 on Oracle VirtualBox VM and configure RHEL for DB2 installation.

Step1: Download RHEL 8.2

You can download RHEL from Red Hat Linux website. You would need a Red Hat account to download RHEL. If you do not have a Red Hat account you can create free of cost account from Red Hat Account. RHEL 8.2 DVD ISO file size is 8 GB. As part of Red Hat Developer program you can download any RHEL version which is currently supported by Red Hat including version 5 and 6. This RHEL product must only be used for development and not for production.

Step2: Configure VM to boot RHEL 8.2 installation DVD

Open Oracle VirtualBox, select your VM and click on Settings button

Setup VM for DB2

Every DBA must have a VM to play around, it can be either a VM in public cloud like AWS, Azure, GCP, IBM Cloud etc. or you can build your own VM on your system. If you have a system with processor which supports virtualization and 8 GB of memory you should be fine with creating VMs. You can do it with 4 or 6 GB of memory but then you might observe slowness on your VM as well as on your system.

For creating VM you can use Oracle Virtual Box or  VMware Workstation Player which is freeware.

In this post we will see how to Setup VM for DB2 using Oracle Virtual Box on a Windows 10 system. Below steps can be used to setup VM for other purpose as well not necessarily for DB2.

Step1: Download Oracle Virtual Box

You can download Oracle Virtual Box from  Download Oracle Virtual Box