ironic 140622212631-phpapp02

28
IRONIC OPENSTACK BAREMETAL PROVISIONING SERVICE Hao Meng, Wang IRC: Haomeng [email protected] June, 2014

Upload: narender-kumar

Post on 15-Apr-2017

14 views

Category:

Software


0 download

TRANSCRIPT

Page 1: Ironic 140622212631-phpapp02

IRONIC OPENSTACK BAREMETAL PROVISIONING SERVICEHao Meng, WangIRC: [email protected], 2014

Page 2: Ironic 140622212631-phpapp02

2

AGENDA• Bare Metal Provision Domain

• Why Provision Bare Metal(BM)• Provision Methods & Scenarios• Key Technologies for BM Provision

• PXE ROM & NBP• IPMI Functions• IPMI Block Diagram• IPMI + PXE Provising Workflow

• Ironic

• About Ironic • Architecture

• Conceptual• Logical

• Framework• Components• BM Provision Sequence Diagram• Data Model• Images used by Ironic• Commands• How to use Ironic

• TripleO

Page 3: Ironic 140622212631-phpapp02

3

Why Provision Bare Metal(BM)

• Database/Hadoop hosting (some databases run poorly in a hypervisor)

• Single tenant, dedicated hardware for performance, security, dependability and other regulatory requirements

• Computing tasks that require access to hardware devices which can’t be virtualized

• High-performance computing(HPC) clusters, physical compute nodes

• Or, rapidly deploying a cloud infrastructure self, TripleO or others

• Cloud scaling out

• X86_64, ARM, TILE-Gx16/36/64/100 systems

• SoftLayer / Racespace Cloud supports bare-metal as service

Page 4: Ironic 140622212631-phpapp02

4

Provision Methods & Scenarios

• Methods• CLONE – ghost/dd

• INSTALL – JumpStart/KickStart/OS Installer• CLONE + INSTALL

• Scenarios• Diskful

• HD/SSD• iSCSI/SAN disk

• Diskless• RAM Disk

Page 5: Ironic 140622212631-phpapp02

5

Key Technologies for BM Provision

• PXE Preboot Execution Environment (PXE) is part of the Wired for Management (WfM) specification developed by Intel and Microsoft. Booting computers via a network.

• NBP Network Bootstrap Program (NBP) is equivalent to GRUB (GRand Unified Bootloader) or LILO (LInux LOader) - loaders which are traditionally used in local booting. Like the boot program in a hard drive environment, the NBP is responsible for loading the OS kernel into memory so that the OS can be bootstrapped over a network.

• IPMI Intelligent Platform Management Interface (IPMI) is a standardized computer system interface used by system administrators for out-of-band management of computer systems and monitoring of their operation.

• DHCP Using PXE, the BIOS uses DHCP to obtain an IP address for the network interface and to

locate the server that stores the network bootstrap program (NBP). • TFTP Trivial File Transfer Protocol (TFTP) is a simple file transfer protocol that is generally used for

automated transfer of configuration or boot files between machines in a local environment. In a PXE environment, TFTP is used to download NBP over the network using information from the DHCP server.

• iSCSI Internet Small Computer System Interface, uses this to 'dd' the image to target machnie local disk

Page 6: Ironic 140622212631-phpapp02

6

PXE ROM & NBP (bootloader,pxelinux.0)

PXE ROM Chip

Page 7: Ironic 140622212631-phpapp02

7

NBP bootloader config file sample

default deploy

label deploy

kernel /tftpboot/76305cdf-a30a-453e-bc92-b3f869a27fd8/deploy_kernel

append initrd=/tftpboot/76305cdf-a30a-453e-bc92-b3f869a27fd8/deploy_ramdisk selinux=0 disk=cciss/c0d0,sda,hda,vda iscsi_target_iqn=iqn-76305cdf-a30a-453e-bc92-b3f869a27fd8 deployment_id=76305cdf-a30a-453e-bc92-b3f869a27fd8 deployment_key=UKKQZ3N2AOUJ45NZVB27L25XKR6I57V8 ironic_api_url=http://192.0.2.1:6385 troubleshoot=0 nofb nomodeset vga=normal

label boot

kernel /tftpboot/76305cdf-a30a-453e-bc92-b3f869a27fd8/kernel

append initrd=/tftpboot/76305cdf-a30a-453e-bc92-b3f869a27fd8/ramdisk root=UUID=319005ff-9177-45af-87db-ada3a1f6dc9f ro nofb nomodeset vga=normal

Page 8: Ironic 140622212631-phpapp02

8

IPMI Functions

• power Shortcut to chassis power commands

• chassis bootdev Set the boot device

• sensor Print detailed sensor information

• sol Configure and connect IPMIv2.0 Serial-over-LAN

• ...

Page 9: Ironic 140622212631-phpapp02

9

IPMI Block Diagram

IPMI Port

Page 10: Ironic 140622212631-phpapp02

10

IPMI NIC Port

Page 11: Ironic 140622212631-phpapp02

11

“Ironic is an Incubated OpenStack project which aims to provision bare metal (as opposed to virtual) machines by leveraging common technologies such as PXE boot and IPMI to cover a wide range of hardware, while supporting pluggable drivers to allow vendor-specific functionality to be added.”

http://docs.openstack.org/developer/ironic/

About Ironic

Page 12: Ironic 140622212631-phpapp02

12

Conceptual Architecture

Page 13: Ironic 140622212631-phpapp02

13

Logical Architecture

Page 14: Ironic 140622212631-phpapp02

14

Framework

Page 15: Ironic 140622212631-phpapp02

15

Ironic Components• Ironic-api

• handles the remote api requests

• Ironic-conductor

• talk with physical machines

• Nova compute driver• Implements the nova virt.ComputeDriver.

• Direct the calls to Ironic

• CLI client

• Ironic deployment ramdisk agent• Built by diskimage-builder

• Deploy by PXE, talk with Ironic-conductor

RAMDISK Agent - https://github.com/openstack/diskimage-builder/tree/master/elements/deploy-ironic

Page 16: Ironic 140622212631-phpapp02

16

Juno Teeth Agent• In Juno release, a new ramdisk agent will be introduced to Ironic by

RackSapce. (teeth agent) The new name is Ironic Python Agent

• Supports:• Partition disks

• Erase disks

• Install bootloaders

• Install an OS image

• Update firmware

• Configure RAID and more....

• A new DeployInterface driver will be written to communicate with the new Teeth agent.

Page 17: Ironic 140622212631-phpapp02

17

Ironic BM Provision Sequence Diagram

Page 18: Ironic 140622212631-phpapp02

18

Ironic Objects Model

Page 19: Ironic 140622212631-phpapp02

19

Images used by Ironic● NBP

– Ironic.conf pxe_bootfile_name

– default pxelinux.0

● Ironic Deployment Agent

– bm-deploy-kernel / bm-deploy-ramdisk

– BM flavor's extra_specs data – baremetal:deploy_kernel_id/baremetal:deploy_ramdisk_id

● User Image – to be deployed to bm

– user-image/

– user-image-vmlinuz

– user-image-initrd

– Images' kernel_id/ramdisk_id ext props•

Page 20: Ironic 140622212631-phpapp02

20

Ironic Commands• node-create - Create a new node.

• node-delete - Delete a node.

• node-get-console - return the connection information about the console.

• node-list - list nodes.

• node-set-console-mode - Enable or disable the console access.

• node-set-power-state - Power the node on or off.

• node-set-provision-state - Provision or tear down a node.

• node-show - Show a node.

• node-update - Upate a node.

• node-validate - Validate the node driver interfaces.

Page 21: Ironic 140622212631-phpapp02

21

Ironic Commands• port-create - Create a new port.

• port-delete - Delete a port.

• port-list - List ports.

• port-show - Show a port.

• port-update - Update a port.

• chassis-create - Create a new chassis.

• chassis-delete - Delete a chassis.

• chassis-list - List chassis.

• chassis-node-list - List the nodes contained in the chassis.

• chassis-show - Show a chassis.

• chassis-update - Update a chassis.

• driver-list - List drivers.

• driver-show - Show a driver.

Page 22: Ironic 140622212631-phpapp02

22

How to use Ironic• Install Ironic - Try with devstack or TripleO's Devtest, it supports Ironic for long time

– http://docs.openstack.org/developer/ironic/dev/dev-quickstart.html#deploying-ironic-with-devstack

– https://wiki.openstack.org/wiki/Tuskar/Devtest

• Setup the compute node's nova.conf• compute_driver = ironic.nova.virt.ironic.driver.IronicDriver

• scheduler_host_manager = ironic.nova.scheduler.ironic_host_manager.IronicHostManager

• Setup tftp folder and prepare pxe boot loader file• # cp pxelinux.0 /YOUR_TFTP_FOLDER/

• Prepare the baremetal flavor• # nova flavor-create <name> <id> <ram> <disk> <vcpus>

• # nova flavor-key baremetal set "cpu_arch"="$ARCH" "baremetal:deploy_kernel_id"="$deploy_kernel_id" "baremetal:deploy_ramdisk_id"="$deploy_ramdisk_id"

• Register these nodes with correct drivers• # ironic node-create driver=pxe_ipmitool

• Register the ports information

• # ironic port-create -a aa:bb:cc:dd:ee:ff -n 76305cdf-a30a-453e-bc92-b3f869a27fd8

• Nova boot to kick off the baremetal provision

• Check node's provision_state/power_state value• # ironic node-show 76305cdf-a30a-453e-bc92-b3f869a27fd8

Page 23: Ironic 140622212631-phpapp02

23

TripleO• TripleO = OpenStack on OpenStack

• INFO: May 2014 at the Atlanta Summit: both RedHat's (InStack) and HP's (Helion) OpenStack distributions are now based on TripleO

Page 24: Ironic 140622212631-phpapp02

24

TripleO – Covers full DevOps

TripleO = NovaBM/Ironic + os-collect-config + os-apply-config + os-refresh-config + os-cloud-config + diskimage-builder (dib) + tripleo-image-elements (dib) + tripleo-heat-elements (dib) + Tuskar(tuskar/tuskarui/python-tuskarclient)

Page 25: Ironic 140622212631-phpapp02

25

TripleO – Block Diagram

v

Page 26: Ironic 140622212631-phpapp02

26

PC

Seed VM

UndercloudOvercloud Controller

Overcloud Compute

Overcloud Compute

Workload

Workload Workload

$ heat stack-createundercloud

$ heat stack-createovercloud

$ heat stack-createworkload

Seed / under / over Clouds in TripleO

Page 27: Ironic 140622212631-phpapp02

27

References• Ironic wiki - https://wiki.openstack.org/wiki/Ironic

• PXE Spec - http://download.intel.com/design/archives/wfm/downloads/pxespec.pdf

• IPMI overview - http://www.intel.com/content/dam/www/public/us/en/documents/product-briefs/ipmi-overview.pdf

• IPMI Spec - http://www.intel.com/content/www/us/en/servers/ipmi/ipmi-specifications.html

• TripleO - https://wiki.openstack.org/wiki/TripleO

Page 28: Ironic 140622212631-phpapp02

THANK YOU