In this guide we show OpenNebula Cloud users how to import an Ubuntu | Debian Qcow2 OS images to OpenNebula image datastore and spinning virtual machines from them. OpenNebula is created to help System Administrators manage distributed data center infrastructures from a central console. In our recent guide, we covered importation of CentOS 8 and CentOS 7 qcow2 OS images. This is a critical step before the actual creation of Virtual Machines on OpenNebula Cloud environment.

You’ll need an access to OpenNebula Sunstone web console, with the permissions to write to image datastore. Before you perform this operation confirm the Image type datastore ready for use. In my setup, this datastore is named “default“.

configure nfs datastores opennebula 02

Step 1: Locate & Import Debian | Ubuntu OS Images

You can optionally create your own custom Qcow2 images for any version of Ubuntu/Debian release. In our guide we’ll use the publicly available Cloud images from OpenNebula market place.

On the web console move to Storage > MarketPlaces > OpenNebula Public

add ubuntu debian opennebula os images 00

Select “Apps” tab and search for “Ubuntu” to filter results.

add ubuntu debian opennebula os images 01

Select the OS image you want to import to the image datastore. I’ll go with “Ubuntu 20.04“, and hit the Cloud import link.

add ubuntu debian opennebula os images 02

Select the the storage datastore for the image then “Download” link.

add ubuntu debian opennebula os images 03

For Debian filter with the keyword “debian

add ubuntu debian opennebula os images 04

Upon successful importation the templates are created.

add ubuntu debian opennebula os images 07

Step 2: Edit Created Templates

To customize the templates go to “Templates” > “VMs” then select the template you want to update.

add ubuntu debian opennebula os images 07

In the next screen click on “Update” button.

add ubuntu debian opennebula os images 07 01

Update default compute information such as memory and CPU to your liking in the “General” tab.

add ubuntu debian opennebula os images 07 02

Default network can be chosen under the “Networks” tab.

add ubuntu debian opennebula os images 07 03

Upload default SSH key under “Context

add ubuntu debian opennebula os images 07 04

Modify any other settings as needed and click “Update” to commit the changes.

Step 3: Create Ubuntu | Debian Virtual Machines on OpenNebula

To create an Ubuntu / Debian Virtual Machine go to “Instances” > “VMs“. Choose OS “Template” and give VM a name, count and modify compute parameters.

add ubuntu debian opennebula os images 08

Wait for the VM status to change from “PENDING to “RUNNING

add ubuntu debian opennebula os images 10

Initiate an SSH access to confirm the instance is up and running:

$ ssh [email protected]
The authenticity of host '172.20.20.101 (172.20.20.101)' can't be established.
ECDSA key fingerprint is SHA256:hUrIPpbWL51mKrzZ1PVkuPMVwlIlhS8WDTP8g7F+klI.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '172.20.20.101' (ECDSA) to the list of known hosts.
Enter passphrase for key '/home/josphat/.ssh/id_rsa':
Welcome to Ubuntu 20.04.1 LTS (GNU/Linux 4.19.0-14-amd64 x86_64)

 * Documentation:  https://help.ubuntu.com
 * Management:     https://landscape.canonical.com
 * Support:        https://ubuntu.com/advantage

  System information as of Wed Mar 31 20:28:46 UTC 2021

  System load:  0.08              Temperature:           41.0 C
  Usage of /:   50.5% of 1.96GB   Processes:             22
  Memory usage: 8%                Users logged in:       0
  Swap usage:   0%                IPv4 address for eth0: 172.20.20.101


0 updates can be installed immediately.
0 of these updates are security updates.


The list of available updates is more than a week old.
To check for new updates run: sudo apt update

Last login: Wed Mar 31 20:28:28 2021 from 172.20.20.1

We’ve successfully imported a Debian and Ubuntu OS images to OpenNebula Image datastore and created VMs from the templates created.

Similar articles:

Install OpenNebula KVM Node on Debian

OpenNebula LXD Node Installation on Debian

How To Configure NFS Filesystem as OpenNebula Datastores

Create and Use Bridged Networks in OpenNebula VMs

Your support is our everlasting motivation,
that cup of coffee is what keeps us going!


As we continue to grow, we would wish to reach and impact more people who visit and take advantage of the guides we have on our blog. This is a big task for us and we are so far extremely grateful for the kind people who have shown amazing support for our work over the time we have been online.

Thank You for your support as we work to give you the best of guides and articles. Click below to buy us a coffee.

LEAVE A REPLY

Please enter your comment!
Please enter your name here