How to Launch an Instance from OpenStack Horizon Dashboard

To Launch an instance from OpenStack Horizon dashboard, first we need to finish following steps :

  • Create a Project and add a member to the Project.
  • Create a Image and Flavor
  • Create a Network and Router for a Project.

In my Case i will use Project Name as “Innovation” and linuxtechi as Project Member of Innovation.

  • Internal Network = 10.10.10.0/24
  • External Network or Floating IP Network = 192.168.1.0/24
  • Gateway of External Network = 192.168.1.1

Create a Project and add a member to the Project.

Login to the dashboard using Admin credentials and Go to Identity Tab –> Projects and Click on Create Project.

Create-Projects-OpenStack-Dashboard

Click on “Create Project” , We can also set the Quota for the project from Quota Tab.

To create Users , Go to Identify Tab–> Users–> Click on ‘Create User’

In my case i have specify the followings :

  • User Name = linuxtechi
  • email = [email protected]
  • password = xxxxxx
  • Primary Project = innovation
  • Role = member

Create-Users-OpenStack-Dashboard

Create a flavor and image :

To create a flavor login in dashboard using admin credentials , Go to Admin Tab –> Flavors –> Click on create Flavor.

Flavors-OpenStack-Dashboard

Specify the Flavor Name (fedora.small) , VCPU , Root Disk , Ephemeral Disk & Swap disk.

Create-Flavors-OpenStack-Dashboard

To Create Image , Go to Admin Tab –> Images—> Click on Create Image.

Specify the Image Name , Description, Image Soure ( in my case i am using Image File as i have already downloaded the Fedora 23 Cloud Image ) , Format QCOW2

Create-Images-OpenStack Dashboard

Create Network and Router for Project Innovation.

To create Network and router for Innovation project sign out of admin user and login as “linuxtechi” user in dashboard.

Go to the Network Tab —> Click on Networks —> then Click on Create Network

Specify the Network Name as Internal

internal-network-name-openstack

click on Next..

Specify the Subnet name (sub-internal) and Network Address (10.10.0.0/24)

internal-subnet-name-openstack

Click on Next..

click-create-internal-network-openstack

VMs will be getting internal ip from DHCP Server because we enable DHCP option for internal network.

Now Create External Network . Click on “Create Network” again , Specify Network Name as “external

external-network-openstack-dashboard

Click on Next…

Specify subnet Name as “sub-external” & Network Address as “192.168.1.0/24

subnet-name-external-name-openstack

Click on Next

Untick  “Enable DHCP” option and Specify the ip address pool for external network.

ipaddress-pool-external-network-openstack

Click on Create.

Now time to create a Router.

Go To Network Tab –> Routers –> Click on ‘+ Create Router’

create-router-openstack

Now Mark External network as “External” , this task can be completed only from admin user , so logout from linuxtechi user and login as admin.

Go to Admin Tab —> Networks–> Click on Edit Network for “External”

Set-External-Networks-OpenStack-Dashboard

Click on Save Changes

Now Logout from admin user and login as linuxtechi user.

Go to Network Tab —> Routers –> for Router1 click on “Set Gateway”

Set-Gateway-Router-OpenStack-Dashboard

Click on “Set Gateway” , this will add a interface on router and will assign the first ip of external subnet (192.168.1.0/24).

Add internal interface to router as well , Click on the “router1″ and select on “interfaces” and then click on “Add interface”

Add-internal-interface-router-OpenStack-Dashboard

Click on Add interface.

Network Part is completed Now & we can view Network Topology from “Network Topology” Tab

Network-Topology-OpenStack-Dashboard

Now Create a key pair that will be used for accessing the VM and define the Security firewall rules.

For creating a key pair

Go to ‘Access & Security’  Tab —> Click on Key Pairs –> then click on ‘Create Key Pair

Access-security-OpenStack-Dashboard

It will create a Key pair with name “myssh-keys.pem

Add a new Security Group with name ‘fedora-rules’ from Access & Security Tab. Allow 22 and ICMP from Internet ( 0.0.0.0 ).

Security-Group-OpenStack-Dashboard

Once the Security Group ‘fedora-rules’ created , click on Manage Rules and allow 22 & ICMP ping.

Manage-Security-Group-Rules-OpenStack Dashboard

Click on Add , Similarly add a rule for ICMP.

Now Finally it’s time to Launch an instance.

Go to Compute Tab –> Click on Instances –> then click on ‘Launch Instance’

Instances-Details-OpenStack-Dashboard

Specify the Instance Name , Flavor that we created in above steps and ‘Boot from image’ from Instance Boot Source option and Select Image Name ‘fedora-image’.

Click on ‘Access & Security’ and Select the Security Group ‘fedora-rules’ & Key Pair ”myssh-keys

Instances-Security-group-keypair-OpenStack-Dashboard

Now Select Networking and add ‘Internal’ Network and the Click on Launch ….

Instances-Network-OpenStack-Dashboard

Once the VM is launched , Associate a floating ip so that we can access the VM.

Associate-floating-ip-Instances-OpenStack-Dashboard

Click on ‘Associate Floating IP

Allocating-floating-OpenStack Dashboard

Click on Allocate IP.

Associate-floating-ip-instance-OpenStack-Dashboard

Click on Associate

Instances-internal-floating-OpenStack-Dashboard

Now try to access the VM with floating IP ( 192.168.1.20) using keys.

Access-openstack-instance-using-keys

As we can see above that we are able to access the VM using keys. Our task of launching a VM from Dashboard is Completed Now.

Hope you like steps and do not hesitate to share this article.

23 thoughts on “How to Launch an Instance from OpenStack Horizon Dashboard”

  1. Hi Pradeep, i’m confused about all the ip addresses you’ve listed there, would you please tell me the meaning and the relationship between these ip addresses, thank you so much.
    your br-ex ip: 192.168.1.3; your floatiog ip: 192.168.1.0; your ip address pool: 192.168.1.19, 192.168.1.30 and this ip: 192.168.1.20
    i’m quite new to openstack, so thanks for your help~

  2. Author is using bridged network for first interface, kind of easy to get the SSH access, but most of you guys have Host only network for enp0s8, and making configuration changes which are meant for bridged network.

  3. Hi Pradeep, I am getting below error

    Message
    Build of instance ec4b4174-c0f7-4932-b1e1-45690a462446 aborted: Volume eba07b7d-48a0-4257-bcc7-ef744f532f0d did not finish being created even after we waited 0 seconds or 1 attempts. And its status is error.
    Code
    500
    Details
    Created
    Jan. 16, 2018, 5:34 p.m.

    Can you please help me to find out what is the problem here ?

  4. Hi,

    Is anyone stsill monitoring this site?
    I cannot reach the internet from the instance though I am able to SSH into it. I can reach the instance via SSH and its external IP. It seems that the bridge is not forwarding the traffic. Any suggestions?

    Thank you

  5. Nishith Niranjan Vyas

    Hello Mr. Pradeep,

    I’ve followed your documentation & performed all exercise very well. However, I’m unable to connect VM using putty.

    ICMP & SSH is allowed from 0.0.0.0/0 network range. Here is my configuration.

    Internal Network: 10.159.0.0/24 (DHCP Enabled). The internal network captures 10.159.1.1 as a default gateway as I left that field blank.

    External Network: 192.168.7.0/20
    (IP Range Address Range is 192.168.7.20-192.168.7.200) (DHCP Disabled)

    Router External IP: 192.168.7.58

    I can access the Fedora VM over the console however I’m unable to login as without as the ppk has not given.

    Any suggestions?

    1. Hi,

      You need to first create key pair and attach that key pair while launching the virtual machine. You can not login to virtual machine without keys. It is mandate to use it unless you have customized the cloud image.

Leave a Comment

Your email address will not be published. Required fields are marked *