workshop - openstack, cloud computing, virtualization
TRANSCRIPT
Openstack Workshop@ Kalasalingam Institute of Technology Sep 26th 2015
Beny Raja & Jayaprakash
What is Cloud Computing?
Sharing Compute Resources - RAM, CPU and Hard drive
Cloud computing means storing and accessing data / programs over the Internet on a shared platform instead of your local server.
Cloud computing enables companies to consume compute resources as a utility rather than having to build and maintain computing infrastructures in-house.
Advantages and Why?❖ No Capital investment and very low Operating Expense
❖ Cost effective - Pay for what you use
❖ Scalability - up and down
❖ Quick Disaster Recovery
❖ Environmental friendly
❖ Work from anywhere
Models of Cloud Computing
IaaS (Infrastructure as a Service)
Provides compute resources (RAM, CPU and Storage) over the Internet.
eg: AWS, Rackspace, HpCloud
PaaS (Platform as a Service)
Provides the platform/environment to deploy the application. eg: GAE, Microsoft Azure
SaaS (Software as a Service)
Provides the software/ application over the Internet. eg: Google apps, Dropbox.
Types of IaaS Model
Public Cloud
Services are delivered to the client through the Internet from a third party service provider. eg: AWS, GAE, InstaCompute
Private Cloud
Services are managed and provided within the organization. eg: IBM, eBay.
Hybrid Cloud
Integrated cloud service utilising both private and public clouds to perform distinct functions within the same organization. eg: Interoute, IBM
What is Hypervisor and different types
A hypervisor is a piece of computer software, firmware or hardware that creates and runs virtual machines.
Type 1Citrix Xenserver, VMware Esxi
Type 2 Virtual box, VMware workstation
Different Cloud Platforms
What is Openstack?
OpenStack is a set of open source software tools for building and managing cloud computing platforms for public and private clouds.
Why OpenStack ?
Control and Flexibility. Open source platform means you’re never locked to a proprietary vendor, and modular design can integrate with legacy or third-party technologies to meet your business needs.
Industry Standard.
Proven Software. Run the same software that today powers some of the largest public and private clouds in the world.
Compatible and Connected. Compatibility with public OpenStack clouds means enterprises are prepared for the future—making it easy to migrate data and applications to public clouds when conditions are right—based on security policies, economics, and other key business criteria.
Who are all Involved?
Founded by rackspace and NASA in 2010. Now managed by the openstack foundation established in
2012.
KeystoneGlanceNovaNeutronHorizonCinder
HeatCeilometerTroveSaharaSwift
Projects Under OpenStack - Integrated
Upcoming Projects....
Barbican
Congress
Cue
Designate
Ironic
Kolla
Magnetodb
Magnum
Manila
Mistral
Murano
Rally
Refstack
Searchlight
Security
Solum
Tripleo
Zaqar
OpenStack Releases...
Openstack Architecture
Dashboard (Horizon)
Web based user interface to other OpenStack services like Nova, Swift, Keystone, Neutron, Heat, etc.
Developed with python Django web framework
Recommended to deployed under Apache web server
Extendable to other upcoming openstack services
As a cloud administrator, the dashboard provides an overall view of the size and state of your cloud. You can create users and projects, assign users to projects and set limits on the resources for those projects.
The dashboard provides users a self-service portal to provision their own resources within the limits set by administrators.
Compute (Nova)
Nova, also known as OpenStack Compute, is the software that controls your Infrastructure as as Service (IaaS) cloud computing platform.
Components/Services:
❖Nova-api - Gateway
❖Controller - Collection of services that enable you to launch virtual machine instances.
❖Compute - Exactly the VM is created under hypervisor
❖Scheduler - Part of controller to select which compute node
Nova cont.
Virtual Machine Security groups
Identity (keystone)
Keystone is an OpenStack project that provides Identity, Token, Catalog and Policy services for use specifically by projects in the OpenStack family. Every Openstack API call gets authenticated & authorized with keystone and proceed further.
Concepts:
Tenants
Users
Roles
Tokens
Services
Quotas
keystone cont.
Networking (Neutron)
OpenStack Neutron is an SDN (Software Defined Networking) project focused on delivering networking-as-a-service (NaaS) in virtual compute environments.
It also lets tenants create multiple private networks and control the IP addressing them. As a result of API extensions, organizations have additional control over security and compliance policies, quality of service [QoS], monitoring and troubleshooting, as well as the ability to easily deploy advanced network services, such as a firewall, intrusion detection, or VPN.
Neutron - network for Cloud Administrator
Vlan Network
Neutron - Network Components for End user
External Network - The external network typically provides Internet access for your instances.Tenant Network - The tenant network provides internal network access for instances. Tenant Router - Default gateway for the tenant VMs, which connects the Tenant Network and the External network
Neutron Advanced Services
LBaaS (Load Balancer as a Service) It allows for proprietary and open-source load balancing technologies to drive the actual load balancing of requests.FWaaS (Firewall as a Service)Neutron extension that introduces firewall feature set.VPNaaS (VPN as a Service)Connect Remote Location through vpn using IPsec/l2tp
Image Service (Glance)Image repository of Openstack. It includes discovering, registering, and retrieving virtual machine images.The images made available through Glance can be stored in a variety of locations like jbod, Swift, S3, ceph or Raid.
Supported disk formatsraw (unstructured) qcow2 (Qemu) isovhd, vmdk, vdi (Hyper-V, Esxi, Virtual Box) aki, ari, ami (amazon images)
Block Storage (Cinder)
It is a Storage as a service component of Openstack. It provides ephemeral and persistent block level storage device, that keeps the data even after the instance is terminated. It provides block storage devices to VM instances as additional storage.
The backend should be configured as a logical volume and added to the volume groups. It also supports variety of drivers like NAS/SAN, NFS, iSCSI, Ceph, and more.
Object Storage (Swift)Swift is a highly available, distributed, eventually consistent object/blob store. Organizations can use Swift to store lots of data efficiently, safely, and cheaply.
Components for Cloud AdminProxy ServerThe RingStorage PoliciesObject ServerContainer ServerAccount ServerReplicationUpdatersAuditors
Swift - Components for end user
End user lists
Account - Your Cloud Administrator creates your account and you own all resources in that account.
Containers - Contains objects and defines namespace for each objects. You can create any number of containers within an account.
Objects - Stores data content, such as documents, images, and so on. By default, each object can be as large as 5GB and it can be increased by the cloud admin.
Orchestration (Heat)
● Heat is the orchestration component of Openstack.
● Template-driven engine that allows us to describe and automate the deployment of infrastructure & application
● Extended features like AutoScaling, Software deployment using configuration management tools like puppet, Chef
● Stack - Grouping of cloud resources
● Intern Heat will talk to other services
Stack Topology
Autoscaling
Automatically adds or removes compute resources depending upon actual usage.
Telemetry (Ceilometer)
Monitoring & Metering component of Openstack
Collects metrics of openstack cloud resources
Alarms can be defined against a resource metrics
Ceilometer Architecture
CLI
Keystone (Identity Service)List all users
keystone user-list
List all services in service catalog
keystone service-list
Create new user
keystone user-create --name --tenant-id --pass --email --enabled
Create new tenant
keystone tenant-create --name --description --enabled
Nova (Compute Service)List instances
nova list
List images
nova image-list
List flavors
nova flavor-list
Boot an instance
nova boot --image cirros --flavor m1.tiny --security-groups jp --nic net-id=acf5f405-9b56-46c5-9a63-b5871f36f68a TestInstance
Nova VM actions (Pause, suspend, stop, reboot)
nova stop <name>
nova start <name>
nova pause <name>
nova unpause <name>
nova suspend <name>
nova resume <name>
nova reboot <name>
Nova cont.
# Create an instance snapshot
nova image-create volumeTwoImage snapshotOfVolumeImage
nova image-show snapshotOfVolumeImage
# Manage security groups
# Add rules to default security group allowing ping and ssh between #instances in the default security group
nova secgroup-add-group-rule default default icmp -1 -1
nova secgroup-add-group-rule default default tcp 22 22
Glance (Image Service)
# Manage images
glance image-list, glance image-show/image-delete/image_update <image>
glance image-create --name “cirros-threepart-kernel” --disk-format aki --container-format aki --is-public True --file ~/images/cirros-0.3.1~pre4-x86_64-vmlinuz
Neutron (Networking Service)
# Create network
neutron net-create <name>
# Create a subnet
neutron subnet-create <network name> <cidr>
neutron subnet-create my-network 10.0.0.0/29
# List/Show network and subnet
neutron net/subnet-list
neutron net/subnet-show <id or name of network>
Cinder (Block Storage)
# Manage volumes and volume snapshots
# Create a new volume
cinder create 1 --display-name MyFirstVolume
# Boot an instance and attach to volume
nova boot—image cirros-qcow2 --flavor m1.tiny MyVolumeInstance
# Attach volume to instance after instance is active, and volume is available
nova volume-attach <instance-id> <volume-id> auto
nova volume-attach MyVolumeInstance /dev/vdb auto
Swift (Object Store)
# List, Create containers & Objects in a container
swift list, swift post mycontainer, swift list container
# Upload file to a container
swift upload mycontainer myfile.txt
# Download object from container
swift download <container name> <file name>
# Upload with chunks, for large file
swift upload -S 64 mycontainer largeFile