27
Devstack beyond ‘hello-world’

8 devstack beyond_hello-world

Embed Size (px)

Citation preview

Page 1: 8 devstack beyond_hello-world

Devstack beyond ‘hello-world’

Page 2: 8 devstack beyond_hello-world

Agenda

What is Devstack?

Single and multi node architecture

Cell architecture

Quick demo of cell setup

Page 3: 8 devstack beyond_hello-world

Run it

Test it

Mimic a deploy

Why Devstack?

Page 4: 8 devstack beyond_hello-world

Structure

nova-db

glance-

db

img

store

volume

storage

Page 5: 8 devstack beyond_hello-world

Compute

Other components Nova API

API request

Compute Compute`

Compute

Compute

Single node setup

Multi-node setup

Page 6: 8 devstack beyond_hello-world

A peek into stack.sh

ADMIN_PASSWORD=password

MYSQL_PASSWORD=stackdb

RABBIT_PASSWORD=stackqueue

SERVICE_PASSWORD=$ADMIN_PASSWORD

HOST_IP=w.x.y.z

...

localrc – set overrides

Database type

Enabled services=g-api,n-api,...

(Service repos)

NOVA_REPO=<nova git repo>

NOVA_BRANCH=<nova branch>

stackrc – primary config file

Page 7: 8 devstack beyond_hello-world

HOST_IP = <compute node IP>

MULTI_HOST=1

SERVICE_HOST=<controller IP>

MYSQL_HOST=<controller IP>

RABBIT_HOST=<controller IP>

ENABLED_SERVICES=n-cpu, n-net, c-sch, c-api, c-vol

On the compute node:

localrc settings

HOST_IP = <controller IP>

MULTI_HOST=1

ENABLED_SERVICES=n-net, n-api, c-sch, c-api, c-vol

On the controller node:

Page 8: 8 devstack beyond_hello-world

Work flow

API request

Page 9: 8 devstack beyond_hello-world

http://devstack.org/guides/multinode-lab.html

Page 10: 8 devstack beyond_hello-world

Cells

Page 11: 8 devstack beyond_hello-world

Nova-

cpu

Nova

-net DB

DB

Nova-

cpu

Nova

-net

Nova-

cell

Nova-

cell

Nova-

sch

Nova

-sch

Parent

Child

Grand-child

Page 12: 8 devstack beyond_hello-world

Parent-child structure

Page 13: 8 devstack beyond_hello-world

AMQP

Build Request

Parent

Child

Work flow

Page 14: 8 devstack beyond_hello-world

So, how we do we configure these cells in devstack?

Page 15: 8 devstack beyond_hello-world

Let’s try to configure a cell environment with one parent and one child

Page 16: 8 devstack beyond_hello-world

We used two VMs with Ubuntu 12.04 LTS installed as parent and child for this

demo

Page 17: 8 devstack beyond_hello-world

Clone https://github.com/matiu2/devstack on both parent and child and

checkout “cell_support” branch

Page 18: 8 devstack beyond_hello-world

Open localrc under devstack folder and type in

below content..

MULTI_HOST=True

enable_service n-cell n-api-meta

disable_service n-cpu

Open /etc/nova/nova.conf and type in below

content..

[cells]

enable=True

name=parent

cell_type=api

On Parent..

Run ./stack.sh

Restart n-api and n-cell services

Page 19: 8 devstack beyond_hello-world

On Child..

Open localrc under devstack folder and type in below

content..

MULTI_HOST=True

enable_service n-cell

disable_service n-api

Run ./stack.sh

Open /etc/nova/nova.conf and type in below

content..

[DEFAULT]

quota_driver=nova.quota.NoopQuotaDriver

glance_api_server = <glance server running in parent>

[cells]

enable=True

name=child

cell_type=compute

Restart n-cpu, n-sch and n-cell services

Page 20: 8 devstack beyond_hello-world

Now we are done configuring both parent and child…

Page 21: 8 devstack beyond_hello-world

How do the parent and the child know about each other now?

Page 22: 8 devstack beyond_hello-world

On parent, we will run the command:

nova-manage cell create --name=child --cell_type=compute --

username=guest --password=password --hostname=<child ip> --

port=5672 --virtual_host=/ --woffset=1.0 --wscale=1.0

Page 23: 8 devstack beyond_hello-world

On the child, we will run the command:

nova-manage cell create –name=parent --cell_type=api --

username=guest --password=password --hostname=<parent ip> --

port=5672 --virtual_host=/ --woffset=1.0 --wscale=1.0

Page 24: 8 devstack beyond_hello-world

Let’s try to build an instance in this cell environment…

Page 25: 8 devstack beyond_hello-world
Page 26: 8 devstack beyond_hello-world

http://openlystacking.blogspot.in/2013/07/creating-cell-environment-using-

devstack.html

Page 27: 8 devstack beyond_hello-world

So far, we have seen…

Brief introduction to devstack

Single and multi-node environment

Cells

A demo in a cell environment

Questions?