Mastering OpenStack - Second Edition

Book Description

Discover your complete guide to designing, deploying, and managing OpenStack-based clouds in mid-to-large IT infrastructures with best practices, expert understanding, and more

About This Book

  • Design and deploy an OpenStack-based cloud in your mid-to-large IT infrastructure using automation tools and best practices
  • Keep yourself up-to-date with valuable insights into OpenStack components and new services in the latest OpenStack release
  • Discover how the new features in the latest OpenStack release can help your enterprise and infrastructure

Who This Book Is For

This book is for system administrators, cloud engineers, and system architects who would like to deploy an OpenStack-based cloud in a mid-to-large IT infrastructure. This book requires a moderate level of system administration and familiarity with cloud concepts.

What You Will Learn

  • Explore the main architecture design of OpenStack components and core-by-core services, and how they work together
  • Design different high availability scenarios and plan for a no-single-point-of-failure environment
  • Set up a multinode environment in production using orchestration tools
  • Boost OpenStack's performance with advanced configuration
  • Delve into various hypervisors and container technology supported by OpenStack
  • Get familiar with deployment methods and discover use cases in a real production environment
  • Adopt the DevOps style of automation while deploying and operating in an OpenStack environment
  • Monitor the cloud infrastructure and make decisions on maintenance and performance improvement

In Detail

In this second edition, you will get to grips with the latest features of OpenStack. Starting with an overview of the OpenStack architecture, you'll see how to adopt the DevOps style of automation while deploying and operating in an OpenStack environment. We'll show you how to create your own OpenStack private cloud. Then you'll learn about various hypervisors and container technology supported by OpenStack. You'll get an understanding about the segregation of compute nodes based on reliability and availability needs. We'll cover various storage types in OpenStack and advanced networking aspects such as SDN and NFV.

Next, you'll understand the OpenStack infrastructure from a cloud user point of view. Moving on, you'll develop troubleshooting skills, and get a comprehensive understanding of services such as high availability and failover in OpenStack. Finally, you will gain experience of running a centralized logging server and monitoring OpenStack services.

The book will show you how to carry out performance tuning based on OpenStack service logs. You will be able to master OpenStack benchmarking and performance tuning. By the end of the book, you'll be ready to take steps to deploy and manage an OpenStack cloud with the latest open source technologies.

Style and approach

This book will help you understand the flexibility of OpenStack by showcasing integration of several out-of-the-box solutions in order to build a large-scale cloud environment.. It will also cover detailed discussions on the various design and deployment strategies for implementing a fault-tolerant and highly available cloud infrastructure.

Table of Contents

  1. Credits
  2. Preface
    1. What this book covers
    2. What you need for this book
    3. Who this book is for
    4. Conventions
    5. Reader feedback
    6. Customer support
      1. Downloading the example code
      2. Errata
      3. Piracy
      4. Questions
  3. Designing OpenStack Cloud Architectural Consideration
    1. OpenStack - The new data center paradigm
    2. Introducing the OpenStack logical architecture
      1. Keystone - identity management
      2. Swift - object storage
      3. Cinder - block storage
      4. Manila - File share
      5. Glance - Image registry
    3. Nova-Compute service
      1. nova-api
      2. nova-compute
      3. nova-network
      4. nova-scheduler
      5. nova-conductor
    4. Neutron - Networking services
      1. The Neutron architecture
      2. Ceilometer, Aodh, and Gnocchi - Telemetry
      3. Heat - Orchestration
      4. Horizon - Dashboard
      5. Message Queue
      6. The database
    5. Gathering the pieces and building a picture
      1. Provisioning a VM under the hood
    6. A sample architecture setup
      1. OpenStack deployment
        1. The conceptual model design
        2. The logical model design
          1. What about storage?
        3. Networking needs
        4. The logical networking design
          1. Physical network layout
          2. The tenant data network
          3. Management and the API network
          4. Virtual Network types
          5. The external network
          6. The tenant networks
      2. The physical model design
        1. Estimating the hardware capabilities
        2. CPU calculations
        3. Memory calculations
        4. Network calculations
        5. Storage calculations
        6. Best practices
    7. Summary
  4. Deploying OpenStack - The DevOps Way
    1. DevOps in a nutshell
      1. DevOps and cloud - everything is code
      2. DevOps and OpenStack
        1. Breaking down OpenStack into pieces
      3. Working with the infrastructure deployment code
      4. Integrating OpenStack into infrastructure code
        1. Continuous integration and delivery
    2. Choosing the automation tool
      1. Introducing Ansible
        1. Modules
        2. Variables
        3. Inventory
        4. Roles
        5. Playbooks
      2. Ansible for OpenStack
      3. The development and production environments
      4. The hardware and software requirements
      5. Networking requirements
      6. The development environment
        1. Setting up the development machine
      7. Preparing the infrastructure code environment
        1. Preparing the development setup
        2. Configuring your setup
        3. Building the development setup
      8. Tracking your changes
    3. Summary
  5. OpenStack Cluster – The Cloud Controller and Common Services
    1. Understanding the art of clustering
      1. Asymmetric clustering
      2. Symmetric clustering
    2. Divide and conquer
    3. The cloud controller
      1. The Keystone service
        1. The identity provider
        2. The resource provider
        3. The authorization provider
        4. The token provider
        5. The catalog provider
        6. The policy provider
        7. Federated Keystone
        8. Fernet tokens
      2. The nova-conductor service
      3. The nova-scheduler service
      4. The API services
      5. Image management
      6. The network service
      7. The Horizon dashboard
      8. The telemetry services
        1. Alarms
        2. Events
      9. Infrastructure services
        1. Planning for the message queue
        2. Consolidating the database
    4. Cloud controller clustering
      1. Starting deployment with OpenStack Ansible
        1. The deployment node
      2. Bringing up the controller nodes
        1. The target hosts
        2. Configuring the network
        3. Running the OpenStack playbooks
          1. Configuring OpenStack Ansible
          2. Network configuration
          3. Configuring Host Groups
          4. The playbooks
    5. Summary
  6. OpenStack Compute - Choice of Hypervisor and Node Segregation
    1. The compute service components
    2. Deciding on the hypervisor
      1. The Docker containers
    3. OpenStack Magnum project
    4. Segregating the compute cloud
      1. Availability zones
      2. Host Aggregates
      3. Nova cells
      4. Regions
        1. Workload segregation
        2. Changing the color of the hypervisor
    5. Overcommitment considerations
      1. The CPU allocation ratio
      2. The RAM allocation ratio
    6. Storing instances' alternatives
      1. External shared file storage
      2. Internal non-shared file storage
    7. Understanding instance booting
      1. Understanding the Nova scheduling process
      2. Booting from image
      3. Getting the instance metadata
      4. Add a compute node
    8. Planning for service recovery
      1. Backup with backup-manager
      2. Simple recovery steps
      3. Data protection as a service
      4. The OpenStack community
    9. Summary
  7. OpenStack Storage - Block, Object, and File Share
    1. Understanding the storage types
      1. Ephemeral storage
      2. Persistent storage
        1. Object storage is not NAS/SAN
      3. A spotlight on Swift
        1. The Swift architecture
          1. Indexing the data
          2. A rich API access
          3. Swift gateways
        2. Physical design considerations
        3. The Swift ring
        4. Storage policy and erasure coding
        5. Swift hardware
          1. Where to place what
        6. The Swift network
      4. Deploying Swift service
    2. Using block storage service: Cinder
      1. Using share storage service: Manila
        1. Using the share service
      2. Choosing the storage
      3. Looking beyond the default - Ceph
        1. Ceph in OpenStack
        2. Deploying Ceph with Ansible
        3. Storing images in Ceph
    3. Summary
  8. OpenStack Networking - Choice of Connectivity Types and Networking Services
    1. The architecture of Neutron
      1. Neutron plugins
        1. Service plugin
      2. Agents
      3. Neutron API extensions
    2. Implementing virtual networks
      1. VLAN-based networks
      2. Tunnel-based networks
      3. Virtual switches
      4. The ML2 plugin
      5. Network types
      6. Neutron subnets
      7. Creating virtual networks and subnets
      8. Understanding network port connectivity
        1. Understanding Linux bridge-based connectivity
        2. Understanding OpenVSwitch-based connectivity
    3. Connecting virtual networks with routers
      1. Configuring the routing service
      2. Connecting networks using a virtual router
      3. Connecting to the external world
      4. Providing connectivity from the external world
      5. Associating a floating IP to a virtual machine
    4. Implementing network security in OpenStack
      1. Security groups
        1. Creating security group policies
      2. Firewall as a service
        1. Configuring the firewall service
        2. Creating firewall policies and rules
    5. Inter-site connectivity with VPN service
    6. Summary
  9. Advanced Networking - A Look at SDN and NFV
    1. Understanding SDN-based networks
      1. OVS architecture
    2. Architecture of OVN
      1. Components of OVN
      2. Integrating OVN with OpenStack
      3. Implementing virtual networks with OVN
    3. Understanding network function virtualization
      1. The Management and Orchestration (MANO) specifications
      2. Topology and Orchestration Specification for Cloud Applications (TOSCA) templates
    4. Looking at the Tacker project
    5. Deploying LBaaS service with Octavia
      1. Configuring Octavia
      2. Creating a load balancer
    6. Summary
  10. Operating the OpenStack Infrastructure - The User Perspective
    1. Operating the OpenStack tenancy
      1. Managing projects and users
      2. Managing user capabilities
      3. Managing quotas
        1. Compute service quotas
        2. Block storage service quotas
        3. Network service quotas
        4. Orchestration service quotas
    2. Orchestration in OpenStack
      1. Demystifying the power of Heat
      2. Stacking in OpenStack
        1. Organizing the stacks
          1. Modularizing the stacks
      3. Embracing OpenStack orchestration - Terraform
        1. Terraform in action
      4. Terraform in OpenStack
    3. Summary
  11. OpenStack HA and Failover
    1. HA under the scope
      1. Do not mix them
      2. HA levels in OpenStack
      3. A strict service-level agreement
      4. Measuring HA
      5. The HA dictionary
        1. Hands-on HA
      6. Understanding HAProxy
        1. Services should not fail
        2. Load balancer should not fail
    2. OpenStack HA under the hood
      1. HA in the database
      2. HA in the queue
        1. Keep calm and implement HA
          1. Implementing HA on MySQL
          2. Implementing HA on RabbitMQ
        2. Implementing HA on OpenStack cloud controllers
          1. Implementing HA on network nodes
          2. VRRP in Neutron
          3. More HA in Neutron
    3. HA in Ansible:
    4. Summary
  12. Monitoring and Troubleshooting - Running a Healthy OpenStack Cluster
    1. Telemetry in OpenStack
      1. Rethinking Ceilometer
        1. Ceilometer glossary
        2. The Ceilometer architecture
      2. Gnocchi - time series database as a service
        1. The Gnocchi architecture
      3. Aodh - embracing alarms
        1. The Aodh architecture
    2. Installing Telemetry in OpenStack
      1. The Ceilometer installation
      2. Configuring alarming
    3. Arming OpenStack monitoring
      1. Running Nagios
        1. Placing Nagios
        2. Installing the Nagios server
        3. Configuring Nagios on OpenStack nodes
          1. Watching OpenStack
    4. Troubleshooting - monitoring perspective
      1. Services up and running
        1. Services should listen
        2. Rescuing instances
        3. All green but unreachable
    5. Summary
  13. Keeping Track of Logs - ELK and OpenStack
    1. Tackling logging
      1. Demystifying logs in OpenStack
        1. Logs location
        2. Adjusting logs in OpenStack
    2. Two eyes are better than one eye
    3. ELK under the hood
    4. Placing the ELK server
      1. Installing the ELK server
        1. Installing ElasticSearch
        2. Configuring ElasticSearch
        3. Defining ElasticSearch roles
          1. Extending ElasticSearch capabilities
          2. Installing Kibana
          3. Configuring Kibana
          4. Installing LogStash
          5. Configuring LogStash
          6. LogStash in action
          7. Preparing LogStash clients
          8. Filtering OpenStack logs
        4. Extending the OpenStack-ELK pipeline
          1. Visualizing OpenStack logs
          2. Troubleshooting from Kibana
    5. Summary
  14. OpenStack Benchmarking and Performance Tuning - Maintaining Cloud Performance
    1. Pushing the limits of the database
      1. Deciding the resources outfit
      2. Caching for OpenStack
        1. Memcached in OpenStack
        2. Integrating memcached
    2. Benchmarking OpenStack at scale
      1. Testing the OpenStack API - Rally in a nutshell
      2. Meeting OpenStack SLA
      3. Installing Rally
      4. Rally in action
        1. Scenario example - Performing Keystone
      5. Shaking the OpenStack network - Shaker in a nutshell
        1. Shaker architecture
        2. Installing Shaker
        3. Shaker in action
        4. Scenario example - OpenStack L2
    3. Summary

Product Information

  • Title: Mastering OpenStack - Second Edition
  • Author(s): Omar Khedher, Chandan Dutta Chowdhury
  • Release date: April 2017
  • Publisher(s): Packt Publishing
  • ISBN: 9781786463982